Xcode ARC forbids explicit message send of ' release '

Source: Internet
Author: User

Xcode version 5.1.1

IOS SDK 7.1

IMAC OS X 10.9.2

There will be 2 error messages:

1, ' Release ' is unavailable:not available in automatic reference counting mode

2. ARC forbids explicit message send of ' release '

Program Disable call method release, because the project opened arc (automatic reference counting), that is, the automatic reference count (is a memory management technology, the object has a counter inside, the external reference increases (call retain), the counter plus 1, When the external reference disappears (call release), the counter is minus 1, the counter is 0 o'clock, and the object is actually disposed.

So if you want to actively call release, you need to turn off arc (5.1.1 Create Project automatically opens arc).

Objective-c Automatic Reference counting set to No.



Related Article

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.