bazelbuild / bazelbuild/rules_rust
Rust Analyzer Missing ENV vars
Open
needs-triage
- Dominant language
- Starlark
- Stars
- 843
- Forks
- 651
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 15
Description
When using proc-macros that rely on rustc env vars they blow up and break the intellisense in my project. Looks like the root cause is this line:
https://github.com/bazelbuild/rules_rust/blob/e80582e7516a47c3fb80592f8f24bf38cdf04ee3/rust/private/rust_analyzer.bzl#L89
It's using the attributes defined in the rule rather than `crate_info.rustc_env` which has all the env vars used at compile time. I can PR a fix, but just want to be sure this wasn't on purpose. I applied a patch file locally and everything works like a charm.
Contributor guide
Assessment
This issue has not been assessed yet.