C++11 Smart pointer

Source: Internet
Author: User

Recently want to use C++11 smart pointer, first left the head, the code test again, back to fill the blog.

Reference Blog: https://www.cnblogs.com/wxquare/p/4759020.html

Important Documents: Http://en.cppreference.com/w/cpp/memory/shared_ptr

In QT Project project (I use Qt5.6), to use pointer pointers, I need to include header file # # <memory>, do not write wrong # # # <memory.h> This is two different files, If written in the latter case, a string in namespace Std does not name a type is present. In addition to C++11 support also depends on the compiler, if you can use the project nullptr, then the basic judgment of your compiler support C++11.

C++11 Smart pointer

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.