Swift2.0 _ detailed description of syntax changes and swift2.0

Source: Internet
Author: User

Swift2.0 _ detailed description of syntax changes and swift2.0
Detailed description of syntax changes of Swift2.0

Document Manager: PMST
Current version: V1.0.0
Last Updated: 2015.06.10 (ps: swift2.0, the beauty of Open Source)
Note: [New] indicates the updated content. In addition, excellent articles, resources, frameworks, and so on can be recommended to me and sent to my mailbox.
Email Address link: mcxcode@163.com

[Change log in April 8]
  • Add content to the Error Handling section, Do Statement section, Throw Statement section, Defer Statement section, and Try Operator Section.

  • The "Check API Availability" section is added in the "Control Flow" section to introduce the API Availability check. The "Statements" section adds the "Availability" section.

  • Add syntaxGuardGo to Early Exit in Control Flow and Guard Statement in Statements.

  • The Protocols section adds the Protocol Extensions section to introduce Protocol Extensions.

  • The Access Levels for Unit Test Targets section in the Access Control section introduces Access Control for Unit Test.

  • The Optional Pattern section in Patterns adds an Optional type match.

  • Updated the Repeat-While section and changed the syntax.Do-whileIsRepeat-while.

  • Updated the Type Properties Section.Class, ures, and enumerations)Content

  • The updated content of the Break Statement section, which uses tags to specify the interrupt.

  • Declaration Attributes@ Available,Warn_unused_resultAttribute

  • Type Attributes chapter update@ ConventionAttribute content.

  • Property Observers chapter updateNote, Clearly differentiateWillSetAndDidSetAttribute observer

  • Add an Access Levels chapterNoteDescriptionPrivateScope.

  • New in Weak ReferencesNoteTo distinguishGarbage Collection MechanismAndARC MechanismWeak references.

  • Special Characters in String Literals chapter updates related content.

  • Update Strings and Characters, in the Swift standard libraryStringType does not followCollectionTypeProtocol.

For more information about the specific changes, see the jump content. I have limited time and have simply translated them to the official website.Revision History 6-08Update content. Please forgive me for translation errors !!

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.