Early Access Program News

CLion starts 2017.1 EAP: convert variable type to auto, zero latency typing and various fixes

Hi,

Today we are glad to announce that the first CLion 2017.1 EAP build (171.2613.3) is available for download.
Clion_2017_1EAP@2x_img
You can install it side by side with your current stable CLion version, no active subscription required.


Download CLion 2017.1 EAP

Short summary:

Upd. More C++14 support (generic lambdas, variable templates and generalized lambda captures) is also included into CLion 2017.1 EAP.

Upd2. Precompile headers and -include support is added to CLion 2017.1 EAP.

Upd3. CLion EAP introduces MSVC compiler support.

Upd4. Disassembly view in debugged when sources and Catch unit test framework support are now available in CLion 2017.1 EAP.

Closer to Almost Always Auto

Using auto type for variable declarations is a powerful feature of modern C++ that makes the code less verbose and thus more readable. It also obliges you to initialize the variable. Herb Sutter once wrote an interesting article in his blog on AAA (Almost Always Auto) style, where he tried to analyze when the use of auto is justified and when it’s not. As we do support many ideas shared there and we’d like to help CLion users to modernize their C++ code, we’ve introduced this new intention action which converts variable type to auto:
auto_intention

While this is still a work in progress, we will also consider the opposite action – replacing auto with an appropriate variable type (CPP-8555).

This EAP also includes support for the auto return type (CPP-4321), which means more accurate code analysis, correct type inferred and shown in the Quick Documentation pop-up and code completion:
auto_return

Quick Documentation

Quick Documentation pop-up (Ctrl+Q on Linux/Windows, F1 on macOS) combines lots of information about the code entity under the caret. For macros, it shows information about macro replacement, as well as macro substitution. For variables, it includes type information, even providing you with an inferred type for variables declared as auto. It shows signatures for functions, along with links to the referenced types, and much more, even including Doxygen-styled documentation preview and code comments.

In this build we’ve worked on polishing the Quick Documentation pop-up:

  • When comments are placed inside the code, Quick Documentation now includes both: type information and the comment
  • If the code entity under the caret doesn’t have any documentation comment, but the parent entity does, then Quick Documentation will show the parent documentation:
    base_documentation

Project model

Project model is becoming more user-friendly with a couple of useful fixes:

  • Renaming a project no longer breaks existing run configurations
  • Obsolete not-modified run configurations, and run configurations for deleted targets, are now removed automatically
  • For existing CMake projects, the project name in CLion is taken from CMake’s PROJECT_NAME on first opening

Besides, when opening a project in CLion for the first time, an executable run configuration is pre-selected now. Previously, it was a Build All configuration which may miss an executable to run and thus confuse users.

VCS Log Viewer

An updated VCS Log Viewer provides you with a few new options to tune search over commit messages there:

  • You can use regex
  • You can choose whether to make the search case sensitive

regex_log_viewer

Zero latency typing

While you type in the editor, the IDE is always doing lots of things in the background to provide you smart features on the fly, like completion, code analysis, formatting, etc. Wouldn’t it be great if typing performance weren’t visually affected by this fact? Ideally it should be comparable to that provided by a simple, code-agnostic text editor.

Some time ago Pavel Fatin, a developer at JetBrains, researched editor latency. Based on his findings, he implemented an experimental feature for IntelliJ IDEA (and the whole IntelliJ Platform) called zero latency typing. In a nutshell, his solution reduces the number of editor repaintings and performs them in a smarter way. The results are impressive:
editor-latency-linux-xml
So today, after almost 6 months of extensive testing, we are enabling zero latency typing as the default setting in all IntelliJ-based IDEs, including CLion.

Dvorak layout support and more

If you’re more used to Dvorak layout in macOS than QWERTY, you’ll be glad to know that keyboards shortcuts like ⌘/, ⇧⌘], ⇧⌘[, ⌘+ and others are now working properly with it (JRE-172).

Besides, this EAP addresses an issue with Korean, Chinese and Japanese keyboard layouts on macOS.

Code analysis fixes and other improvements

There are more bug fixes and enhancements introduced in this EAP build:

  • Incorrect Call to pow is ambiguous warning for GCC 6.2 was removed (CPP-8543)
  • Incorrect Too few template arguments warning was fixed (CPP-7150)
  • CLion now doesn’t suggest to reduce TRUE macro to ‘true’ for pure C code
  • CLion now doesn’t suggest to make static or friend functions pure virtual
  • Hidden functions from the base class are no longer suggested in the completion
  • Settings Repository plugin is finally bundled into CLion

Swift plugin: SourceKit inspections and intentions

We are glad to announce that SourceKit inspections and intentions are now available in the Swift plugin for CLion both on macOS and Linux:
linux_sourcekit@2x
Internally, the Swift plugin for CLion uses the SourceKit in-proc implementation.

Note that since the full support for reading Swift modules on Linux is not available yet, there could be issues with SourceKit integration in projects with complex dependencies. If you experience such problems, please report them in a sub ticket here.

Besides, we’ve added a New Project template for Swift, that allows you creating a new Swift project with ease (minimal working context is created automatically by CLion).

NB: We are very much looking forward to your feedback in order to help us create a tool that you will enjoy using on everyday basis. So if you do use CLion as a Swift IDE on Linux, let us know about your use case, your needs and your experience with CLion.

That’s about it. The full release notes are available here.
Stay tuned and don’t miss more exciting features and valuable fixes coming soon.


Download CLion 2017.1 EAP

The CLion Team
JetBrains
The Drive to Develop

image description

Discover more