AppCode 2017.1: Swift 3 support, Create from usage for types and initializers, Override/Implement improvements, better completion and more!
AppCode 2017.1 is here, so download and try it right now! The patch update is also available if you are using previous 2016.3.3 or 2017.1 RC2 version.
To summarize this update:
- Swift:
- Better language support, including many improvements in the resolution, completion, and navigation.
- Create from usage for types and initializers.
- Override/Implement improvements.
- Completion improvements.
- Support for //MARK, //FIXME, and //TODO comment tags in the Structure view.
- C++: new C++14 and C++17 features.
- Improved filtering in the Build Messages tool window.
- Xcode-like breakpoints.
- Emoji support in the editor and IDE views.
- And more.
Swift
Language support
This release delivers support for a huge part of Swift 3 features in AppCode:
- SE-0005 (Better translation of Objective-C APIs into Swift) brings correct resolution, completion and navigation for entities aliased with
__attribute__(swift_name("..."))
,NS_SWIFT_NAME
orCF_SWIFT_NAME
together with more accurate resolution for Objective-C code constructs in general:
NS_ENUM
andNS_OPTIONS
are now also correctly translated into Swift. As for the same features in refactorings/usages search functionality, we’re still working on them. - SE-0062 (Referencing Objective-C key-paths) brings correct parsing, resolution, navigation and find usages for
#keyPath(...)
expressions: - SE-0064 (Referencing the Objective-C selector of property getters and setters) adds support for new
#selector(...)
overrides in the parser, navigation, and resolution:
- SE-0060 (Enforcing order of defaulted parameters)
- SE-0057 (Importing Objective-C Lightweight Generics)
- SE-0037 (Clarify interaction between comments & operators)
- SE-0116 (Import Objective-C id as Swift
Any
type) - SE-0096 (Converting
dynamicType
from property to operator) brings correct parsing and completion for the newtype(of:)
function: - SE-0033 (Import Objective-C Constants as Swift Types) brings correct resolution, completion and navigation for Objective-C constants wrapped into Swift types using
__attribute__((swift_wrapper(struct)))
or__attribute__((swift_wrapper(enum)))
- SE-0091 (Improving operator requirements in protocols) brings correct parsing, сompletion, and generation for
prefix
,infix
andpostfix
operators: - Better translation of Objective-C nullability attributes in Swift (OC-11980), together with support for nullability audited regions in Objective-C (OC-13932)
- Metatypes support (OC-14366)
- Correct resolve and completion for
self.init()
andsuper.init()
calls
Create from usage
AppCode 2016.3 added intentions for generating functions, variables, and properties from their usages in Swift. Now the corresponding actions are also available for Swift types (such as classes, structs, enums and protocols) and their initializers:
Read this blog post for more details.
Override/Implement
Override/Implement (^O
/^I
) helps you quickly implement all required protocol methods and override multiple methods at once. In this release, we’ve significantly improved the usability of the Override/Implement popup and the correctness of generated code:
- All the members in Override/Implement popup are now shown hierarchically:
- Designated/convenience/required initializers are marked with the appropriate keyword
- Class methods in extensions are correctly overridden
- Dynamic methods in extensions are offered for overriding
- Static methods are not suggested anymore
- Optional methods from superclass are now offered only for overriding and not for implementation
Completion
Now AppCode takes into account argument names when completing Swift methods and functions:
Besides, dynamic
, lazy
, postfix
, prefix
and indirect
keywords are added to the completion list.
Structure view
There are plenty of navigation views in AppCode to help you find your way through your code faster. Structure view (⌘7
) and File Structure popup (⌥F12
) show the structure of the current file, allowing you to quickly jump to the particular symbol. In this version we’ve added support for showing //MARK
, //TODO
, and //FIXME
comment tags in this view:
In case you need to see only //TODO
and //FIXME
comment tags, use ⌘6
(TODO view):
Want to learn more about all the different navigation features in AppCode? Read our tutorial here.
C++
As usual, all the C++ language features that our CLion team supported are also available in AppCode:
- C++14:
- auto return type
- generic lambdas
- variable templates
- generalized lambda captures
- C++17: correct parsing and resolution for nested namespaces
- Make auto intentions
Read more about them in this blog post.
IDE
Build messages
Filter compiler messages in your application – select the necessary message types with the Filter messages button on the left-hand side of the Build Messages tool window:
Xcode-like breakpoints
Sometimes with the default IntelliJ behavior for breakpoints, you can accidentally remove parameterized breakpoints with complex conditions. To avoid this, turn on the Drag to the editor area option in Preferences | Build, Execution, Deployment | Debugger | Remove breakpoint. After that, click on a breakpoint to enable/disable it, or drag a breakpoint to the editor area to remove it:
Emoji support
Like all IntelliJ IDEs, AppCode now correctly renders Emoji characters in the editor and IDE views and lets you quickly insert them with ⌥⌘Space
:
Find in Path
The Find in Path dialog has been significantly re-worked by the IntelliJ Platform team. Now it shows all the options on a single pane, together with a preview of the results:
Other changes
- The Remote hosts access plugin is bundled in AppCode.
- The Branches popup has been redesigned and can now mark important branches as Favorites.
- VCS Log viewer now allows you to use regular expressions and match or ignore case when searching.
- Fixes for Dvorak as well as Korean, Chinese and Japanese keyboard layouts.
- Zero-latency typing enabled by default.
That wraps it up! Check out this short demo to see the new features in action:
Your AppCode team
JetBrains
The Drive to Develop