New Features

  • #7194 Provide initial support for attribute procedural macros. Now the plugin can expand such procedural macro calls and take into account all expanded items in type inference and name resolution. Note, it’s only an initial implementation, so it may work in an unexpected way in some cases. The feature is disabled by default for now. To turn it on, you should enable org.rust.cargo.evaluate.build.scripts and org.rust.macros.proc experimental features. Don’t forget to reload a project structure after enabling the corresponding features via Refresh Cargo Projects action on Cargo tool window. See tracking issue for more details and the current status of procedural macros support

  • #6840 Add a refactoring and an intention to extract selected struct fields into a separate struct (by @Kobzol)

  • #6328 Add quick fix to fully qualify an unresolved path with an import candidate (by @Kobzol)

  • #7899 Allow extracting expressions containing references to constants in Introduce constant refactoring (Refactor | Extract | Constant or Ctrl+Alt+C) (by @Kobzol)

  • #7945 Use Self:: instead of fully qualified name for method call when extracting static method

  • #7897 Annotate non-structural-match types in const generic parameters (E0741)

  • #7778 Use cargo-generate 0.9 and add detailed information in Add Custom Template dialog

  • #7888 Support completion inside not expanded macro calls (in incomplete code) for macros 2.0

Fixes

  • #7931 Fixes code insight inside projects which have very large macro expansions

  • #7969 Show proper error message in Test tool window if no tests were found

  • #7965 Show error message if unable to run debugger because no / multiple artifacts were produced

  • #7954 Fix font colors mapping in a console under dark themes for Windows

  • #7842 Fix some cases when named import should shadow glob-import

  • #7853 Don’t reorder existing imports in Move refactoring (Refactor | Move or F6)

  • #7776 Specify wasm32-unknown-unknown target when creating new WebAssembly Lib project. This fixes expansion of macros with wasm related cfg attributes (e.g. in reqwest crate)

  • #7950 Fix false positive extra fields error in tuple struct pattern when using rest pattern (by @mibac138)

  • #7939 Fix loading compiler’s renderers when they are chosen in Preferences | Build, Execution, Deployment | Debugger | Data Views | Rust settings. Note that bundled renderers (enabled by default) are still preferable in most cases. So consider switching to them if you use compiler’s renderers for some reason

Internal Improvements

  • #7399 Test LLDB pretty-printers on Windows

Full set of changes can be found here