Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 13:50
    Undin assigned #6698
  • 13:50
    Undin labeled #6698
  • 13:50
    Undin labeled #6698
  • 13:50
    Undin edited #6698
  • 13:49
    Undin opened #6698
  • 13:15
    Undin labeled #6697
  • 13:14
    chertov closed #6697
  • 13:01
    chertov opened #6697
  • 11:03
    avrong synchronize #6690
  • 10:29
    github-actions[bot] milestoned #6696
  • 10:28
    bors[bot] closed #6696
  • 08:34
    Undin opened #6696
  • 07:57
    Kobzol review_requested #6695
  • 07:57
    Kobzol labeled #6695
  • 07:57
    Kobzol opened #6695
  • Jan 19 22:18
    Kobzol synchronize #5944
  • Jan 19 20:32
    Kobzol synchronize #5944
  • Jan 19 18:55
    ortem labeled #6616
  • Jan 19 18:49
    bastien-solutions closed #6616
  • Jan 19 14:58
    bors[bot] closed #5475
Jakub Beránek
@Kobzol

I checked it now and indeed if you Run the configuration, it's done through cargo, so the env. vars exist. But if you Debug it, the variables are missing. I assume that it is intended and it's required to go around Cargo to make debug work.

TBH I'm not sure if it should be set by the plugin. It also won't be set if you run your compiled app/game directly using the terminal for example (not using cargo run).

Florian Krauthan
@fkrauthan
Hmm I feel like it should. My expectation was a developer is that if I have a run configuration and run it normal or with Debug I expect it to behave exactly the same (with the difference one attaches a debugger and the other not). From a end user point of view it does not matter if both modes have to use different execution methods.
And that it is not set for the compiled game's exe directly is obviously correct as for distribution I would assemble a install that ensures that the files end up with the EXE. Don't think that this is a good argument for why the Cargo Run Debug execution should behave different to a normal Cargo Run execution for the same Cargo Configuration.
Florian Krauthan
@fkrauthan
I've created a bug report for now: intellij-rust/intellij-rust#6500
Jakub Beránek
@Kobzol
Thanks. BTW, as a workaround, you can set the env. var manually for the run configuration.
Florian Krauthan
@fkrauthan
Yeah thats what I am probably gonna have todo for now.
Shane Murphy
@ShaneEverittM
Is this a good place to point out a potential bug?
Shane Murphy
@ShaneEverittM
The short version is that certain errors are double reported. Specifically in my case E0658, which is thrown when using unstable features. Without any feature enable attributes, the error is reported twice. Adding the appropriate feature, in my case !#[feature(ptr_internals)] removes one of the error reports, but not both.
image.png
Before
image.png
After
In the after case, cargo reports no errors from the command line, or when running external linting using the cargo pane.
I'm using CLion 2020.3
and 1.50.0 nightly
and plugin version 0.3.137.3543-203
Vlad Beskrovny
@vlad20012
Hi!
About error duplication: the first error is from our embedded analysis, the second is from cargo check.
About false-positive error: it's likely a bug in our analysis, could you please report an issue to our tracker with a minimized example?
Shane Murphy
@ShaneEverittM
Okay, I'll submit a report. About the duplication, generally speaking is it the case that the embedded analysis and cargo check don't overlap? Meaning this is a rare case where they are redundant?
Vlad Beskrovny
@vlad20012
They often overlap. Our analysis is incomplete, so Cargo Check is useful. But we aim to implement all the analysis ourselves, so we often duplicate errors from Cargo Check
Shane Murphy
@ShaneEverittM
Brian Merchant
@bzm3r
hi all
when i use #[cfg(not(debug_assertions))], the plugin uses the "conditionally compiled code" synax highlightning options to colour the entire block uniformly
however, i don't want it to do so
what can i do?
叫兽
@arlicle
image.png
image.png
sodo
@djdisodo
how de we expand derive proc macro
does it compiles the macro before expanding?
sodo
@djdisodo
how can i access to indexed things in code
Jakub Beránek
@Kobzol
procedural macros are currently not expanded by the plugin (it's heavily WIP intellij-rust/intellij-rust#6564)
sodo
@djdisodo
ok
how can i get the import path of RsFunction?
Jakub Beránek
@Kobzol
I'm not sure what you mean by "import path". if you want to get the qualified path (i.e. the full name of the function), you can use function.qualifiedName
sodo
@djdisodo
@Kobzol something like std::env::args()
Jakub Beránek
@Kobzol
right, so that would be the qualified path
sodo
@djdisodo
@Kobzol if it comes from dependency crate what would it start with? crate:: or dep_crate::
Jakub Beránek
@Kobzol
it it comes from a dependency, it should have the full path, i.e. std::env::args or serde::serialize etc.
Alex Page
@anpage
Hey everyone. I'm trying out CLion to work on C++ and Rust in the same project. So far it seems to make that really easy, but it's doing some static analysis and showing me errors that don't actually exist. Both cargo check and cargo clippy show no problems.
image.png
This code is in the cxx crate's demo.
Is there any way to completely disable the embedded checks?
Jakub Beránek
@Kobzol
this is a bit unfortunate, since this syntax is not valid Rust, but cxx transforms it using a procedural macro. since the plugin currently does not expand procedural macros, it cannot know that, so it sees invalid syntax.
sodo
@djdisodo
i don't know how but indexing of docs.rs is PERFECT
can't we use its data or its indexing method
Jakub Beránek
@Kobzol
indexing of what?
QiuJiangkun
@qiujiangkun
Can't I debug on M1?
Jakub Beránek
@Kobzol
You can follow this existing issue: intellij-rust/intellij-rust#6616
QiuJiangkun
@qiujiangkun
Thanks
Gentoli
@gentoli:nsyd.tech
[m]
Is there a way to collect logs on what is the plugin doing? Code completions will never finish loading or takes forever while the plugin maxes out 2 CPU cores. I see high usage from org.rust.lang.core.stubs.index in activity monitor but have no idea on what is it getting stuck on.
Jakub Beránek
@Kobzol
You can find a guide on how to collect logs here: https://intellij-support.jetbrains.com/hc/en-us/articles/207241085-Locating-IDE-log-files. If you experience problems with the plugin, please create a new issue (using Help -> Create New Issue) and attach the logs.
colin-grapl
@colin-grapl
Hey, been using intellij-rust for quite a while now and it's great. I'd love to see the 'optimize imports' remove unused imports and see a few issues around it, but otherwise pretty happy. I was actually wondering if there's some way to contribute/ donate? I don't really have the time to donate code unfortunately, but wouldn't mind sponsoring.