Vivek Galatageblog.vivekg.net·Mar 20, 2023Sparrow - C++ Type CheckerLet's start with a problem. #include <iostream> #include <utility> struct Person { Person(int a) : age(a) {} int age = -1; }; int main() { Person p1(40); Person p2 = std::move(p1); std::cout << "Age of Person 1: " << p1.age << " years" <<...Discuss·91 readsC++
Omkaromkaracharekar.hashnode.dev·Nov 24, 2021Maximizing Performance with C++ Move Semantics: Exploring the Benefits of Resource Transfers, Reduced Overhead, and Improved Memory AllocationIntroduction 💡 C++11 introduced a powerful new feature called move semantics. This feature allows for more efficient use of memory and can greatly improve performance in certain scenarios. In this article, we will explore what move semantics are, ho...Discuss·6 likes·47 readsMove Semantics