New Features

  • Initial support of cfg attributes. Now the plugin can evaluate some expressions inside cfg attributes. Code that plugin considers disabled has gray foreground now and it isn’t taken part while name resolution and code analysis. For example, if you have several definitions of the same item for different operating systems, the plugin doesn’t treat them as duplicates now. The set of supported options is quite small at this moment. The most notable supported options are unix, windows and target_os (full set can be found in the corresponding issue). Note, features defined via Cargo.toml are still unsupported

    cfg attributes

  • Improve Edit | Extend Selection and View | Type Info actions for code inside macro calls. If a piece of code in macro call is expanded into exactly the same code, the corresponding actions work for it in the same way as they work with code outside of macro call. Note, it works only when the experimental macro expansion engine is enabled. You can turn it on via Preferences | Languages & Frameworks | Rust | Expand declarative macros option

  • Provide Rust specific dictionary for the spellchecker. It should fix false positive warning annotations on some commonly used Rust words like deref. Spellchecker dictionaries can be configured in Preferences | Editor | Spelling setting panel
  • Improve rendering of external libraries. Now all stdlib crates are grouped into a single library. Also, a version is displayed for each library in the external library tree

    external libraries

Fixes

  • Process library with custom source location properly. Previously, if library Cargo.toml had custom path of lib target, the sources were not indexed sometimes that led to unexpected unresolved names
  • Improve editor responsiveness while macro expansion process
  • Fix Rust language injection into doc comments with 2019.3 EAPs

Full set of changes can be found here