摘要:
虽然auto_ptr已经过时了, 但是对这种古董做考古工作仍旧有很多裨益。 所有权移交(总是move),是auto_ptr的核心语义之一。当调用foo(ptr)后,会打印输出“ptr is null” 。 为了防止发生foo中的行为,可以定成: 那么auto_ptr中的拷贝构造函数是什么样子的? a 阅读全文
posted @ 2018-03-25 23:14
thomas76
阅读(164)
评论(0)
推荐(0)
摘要:
要区分 literal 和 literal-type这两个不同的概念。 literal:文字量,10,3.14, true ,u8"123", L"好"这些东西。 literal-type: 参考http://en.cppreference.com/w/cpp/concept/LiteralType 阅读全文
posted @ 2018-03-25 19:09
thomas76
阅读(4540)
评论(0)
推荐(0)

浙公网安备 33010602011771号