issues
search
ooolky
/
NoteBook
0
stars
0
forks
source link
c++ - 引用或移动数据
#85
Open
ooolky
opened
10 months ago
ooolky
commented
10 months ago
参考
Pointer vs. reference return types
Return by reference in C++ with Examples
总结
把引用作为形参和函数写值在危险性上和指针是一样的,还有可能失败(以为改了其实没有),最好还是只用 const 修饰的引用来读值。
ooolky
commented
10 months ago
参考
When is the use of std::ref necessary
Bind Function and Placeholders in C++
ooolky
commented
10 months ago
参考
auto_ptr vs unique_ptr vs shared_ptr vs weak_ptr
when to use smart pointer
ooolky
commented
10 months ago
参考
how-to-convert-already-created-object-to-unique-ptr
Move Constructors