为什么这段代码调用复制构造函数?
为什么连字号用于复制构造函数?
为什么不复制构造函数被调用?
为什么复制构造函数不叫吗?
这是隐式调用复制构造函数?
复制构造函数或赋值操作符?
如何写一个复制构造函数?
为什么没有我的复制构造函数的工作吗?
如何从复制赋值运算符调用复制构造函数?
How to call to the copy constructor from the copy-assignment operator?
复制构造函数不工作?
我为什么不具有挥发性的默认的复制构造函数?
Why am I not provided with a default copy constructor from a volatile?
复制构造函数是因为你呼叫的价值不是由参考。
The copy constructor is called because you call by value not by reference.
你没有定义复制构造函数,默认的是由编译器创建的。
You didn't define a copy constructor so a default one was created by the compiler.
编译器是省略调用(实际上,两与复制构造函数调用)。
The compiler is eliding the call (actually, two calls) to the copy constructor.
传递复制构造函数参数的函数中的内联程序集代码不受支持。
Inline assembly code in functions that pass copy-constructed function parameters is not supported.
对象不需要复制构造函数或赋值操作符来保存到介入式容器中。
Objects don't need copy-constructors or assignment operators to be stored in intrusive containers.
当我返回值赋值操作符,首先是调用复制构造函数为基础的机制?
When I return by value from an assignment operator, firstly what is the mechanism and basis of calling the copy constructor?
C + +:这是被称为适当的构造函数构造函数或复制构造函数?
C + + : which is the appropriate constructor to be called: the constructor or the copy constructor?
不然你怎么使用返回指令创建并返回一个对象而不使用复制构造函数?
How else could you use that return instruction to create and return an object and yet not use the copy constructor?
不可访问基类中的复制构造函数,因此无法为派生类生成复制构造函数。
A copy constructor was not accessible in a base class and was therefore not generated for a derived class.
具有指针成员且使用默认合成复制构造函数的类具有普通指针的所有缺陷。
Classes that have pointer members and use default synthesized copy control have all the pitfalls of ordinary Pointers.
当这种用法被支持时,编译器被允许(但不被制强)跳过复制构造函数而直接创建该对象。
When it can do so, the compiler is permitted (but not obligated) to skip the copy constructor and create the object directly.
另外,对于出于设计原因拥有private构造函数而没有复制构造函数的类,所以这种交换风格不适用。
Also, for classes that have design reasons to have private or no copy constructor, this style of swapping won't work. Here's what boost: : swap gets you.
为了管理具有指针成员的类,必须定义三个复制控制成员:复制构造函数、赋值操作符和析构函数。
To manage a class with pointer members, we must define all three copy-control members: the copy constructor, assignment operator, and the destructor.
您不需要使用复制构造函数,并且永远也不需要大汗淋漓地去实现clone方法的那些令人惨不忍睹的细节。
You do not need a copy constructor, and you need never sweat the gory details of implementing a clone method.
将输出语句添加到构造函数、析构函数和复制构造函数,以查看在运行程序时命名返回值优化的效果。
Add output statements to the constructor, destructor and copy constructor to see the effect of the Named Return Value optimization when you run the program.
它存在的所有实例,并试图修改它的类的复制构造函数是毫无意义的(除非你是用它来保持某种计数器的实例)。
It exists for all instances, and to attempt to modify it in the class copy constructor makes little sense (unless you are using it to keep some kind of counter of instances).
若要解决C2299,请不要使复制构造函数或赋值运算符成为模板函数,而使其成为采用类类型的非模板函数。
To resolve C2299, do not make the copy constructor or assignment operator a template function, but rather a non-template function that takes a class type.
若要解决C2299,请不要使复制构造函数或赋值运算符成为模板函数,而使其成为采用类类型的非模板函数。
To resolve C2299, do not make the copy constructor or assignment operator a template function, but rather a non-template function that takes a class type.
应用推荐