Welcome GoLand 2018.1 EAP: Better Inspections, Completion, Performance, and More

Following the opening of the EAPs for IntelliJ IDEA and WebStorm, the GoLand team is in a hurry to let you know that GoLand 2018.1 EAP is here with lots of goodies. Read below to learn what’s new or go ahead, download the EAP and give it a spin yourself. If you use Toolbox App, it already awaiting you there.

Go 1.10

Following the changes introduced with Go 1.10, the IDE now supports many of these changes.

First, for method expressions, the IDE now supports any type as a receiver:

golang_2018_1_method_expressions

Second, the support for Go templates now respects the new keywords such as break and continue:

golang_2018_1_template

The formatter has also been updated and now offers correct formatting to three-index slices and single-method interfaces.

golang_2018_1_three_index_slice

Since go vet is now by default running as part of go test, the IDE added missing go vet inspections available on the fly.

For example, the inspection, that reports conditions that are always true (or false), now also spots unnecessary checks for functions on nil:

golang_2018_1_always_true

Also, the IDE reports direct assignments to atomic values:

golang_2108_1_atomic

Code completion

For return statements inside functions, code completion now suggest default values:

golang_2018_1_return

Intentions

There’s a number of new intentions added to the update, e.g. Flip for binary expressions, and Negate and Negate recursively for boolean expressions:

golang_2018_1_flip_negate

In addition to Negate, for if statement, you now can use Invert:

golang_2018_1_invert

Performance

Speaking of performance, the update makes it possible to limit indexing of the local project and avoid indexing an entire GOPATH. This new option makes sense when you vendor all your dependencies with dep or glide tools and don’t use libraries from global GOPATH.

The option is available in both File | Settings | Go | GOPATH | Index entire GOPATH and the Project Wizard.

Others

The EAP also brings many non-Go related improvements:

  • The IDE now respects fractional scale factors when multiple HiDPI monitors are used
  • The Replace in Path popup now previews replacements even if a regular expression is used.
  • Now any folder in the Project tool window can be easily opened in the Terminal tool window. The action is called Open in Terminal.
  • VCS
    • The Git Branches popup now supports pasting text from the clipboard.
    • The Force Push action is enabled by default for all branches except the protected ones. The Allow force push checkbox has been removed from the Preferences | Version Control | Git.
  • Web
    • Better code completion for SVG properties and values
    • Navigation from HTML to both compiled CSS and its source
    • Pasting HTML to JSX now respects React-specific attributes (className, onClick, onChange, etc).

Major bug fixes

The update has tons of bug fixes including a few major ones, such as with focus issues. Here’s a list of some of the fixed cases:

  • The Search Everywhere popup didn’t receive focus.
  • The Project tool window didn’t receive focus from the Select In popup.
  • The VCS tool window didn’t receive focus from the Diff dialog.
  • The Find in Path dialog doesn’t disappear now if you click outside the dialog

For the complete list of changes in the EAP build, please refer to the release notes.

That’s it for now. To try out to all these (and some other improvements), go ahead and download the EAP build from the website or from the Toolbox App.

Note, the EAP is work in progress and thus may have bugs. If you find a bug, please make sure to report it to our issue tracker. This way you not only help us make the product better but will also keep informed on the progress, e.g. when this or that bug is going to be fixed.

Happy developing!

About Andrey Cheptsov

Part-time dreamer. JVM/JavaScript geek. IntelliJIDEA Marketing Manager at JetBrains.
This entry was posted in EAP, New Features and tagged , . Bookmark the permalink.

5 Responses to Welcome GoLand 2018.1 EAP: Better Inspections, Completion, Performance, and More

  1. Aleksandr Dorofeev says:

    Compatible builds: 181.2784—181.2784.*. Damn! And again no updates for Go plugin until next IntelliJ IDEA.

    • Florin says:

      You can use IntelliJ IDEA Ultimate 2018.1 EAP with the Go plugin if you want.

      • Aleksandr Dorofeev says:

        I’m using IntelliJ IDEA Ultimate and I do not see the point in using unstable versions with a limited period of validity.
        Stable revision of 2018.1 will not be released soon. A couple of questions:

        – Why EAP version of plugin is in stable branch?
        – Why can not I keep compatibility with the current stable version?

        • Florin Pățan says:

          > I’m using IntelliJ IDEA Ultimate and I do not see the point in using unstable versions with a limited period of validity. Stable revision of 2018.1 will not be released soon.

          Correct, the EAP period just started, it will likely be a few months before it is released as stable. The point would be to help the team find issues but also get access to a lot of improvements.

          > – Why EAP version of plugin is in stable branch?

          I’m afraid I don’t understand the question. The 2018.1 plugin is not released in a stable branch for now, it is in the EAP release mode.

          > – Why can not I keep compatibility with the current stable version?

          I’m afraid that I don’t understand this question either. If you do not use 2018.1, or the nightly branch, and only update from stable releases, then you are not affected by these changes. But if you do want to test them and use them, then you do need to use an EAP release which might not be very stable at times. It’s all up to you.

          I’d be happy to reply to any other questions you may have, and please feel free to rephrase the ones above if my replies do not address your concerns.

        • Alexander Zolotov says:

          > – Why EAP version of plugin is in stable branch?

          So the users of IntelliJ EAP won’t need to do anything to get Go plugin in their EAP builds. This is the only reason, and this is why Go plugin EAP builds are limited to be used in a single IDE build.

          > – Why can not I keep compatibility with the current stable version?

          It will slow us down. Keeping compatibility is usually hard and what’s more, this approach won’t allow us to use new API as fast as we want.

          Also, even backward-compatible changes from 2018.1 EAP are unstable and moving them to stable plugin sounds dangerous.

          I can backport some particular changes to 2017.3-compatible version of the plugin but I’m not ready to do this for every change, sorry.

Leave a Reply

Your email address will not be published. Required fields are marked *