You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have this piece of code having issue only with Vectors and not on regular struct. I have to note that this is working for both cases in one system, but no on the other. Have tried ":internal_debug" and shows no difference between working and non working version. What could be the cause of not completing tab completion? I am able to print the actual value though even in non working case. Does this need rust-analyzer to be installed?
Welcome to evcxr. For help, type :help
>> #[derive(Debug,Default)]
struct Sa {
a: u32,
b: u32
}
let mut v : Vec<Sa> = Vec::<Sa>::new();
v.push(Sa::default());
>> let s : Sa = Sa::default();
>> s. << this expands
a b
>> v[0]. << fails to expand
>> v[0]
Sa { a: 0, b: 0 }
>> v[0].a
0
The text was updated successfully, but these errors were encountered:
Evcxr uses rust-analyzer as a library - i.e. when you build evcxr, rust-analyzer is built-in to the evcxr binary. So you don't need a separate copy of rust-analyzer installed.
The main thing that evcxr needs in order for things like completions to work is for the rust-src component to be installed. You can check with rustup component list | grep src, which should show:
rust-src (installed)
If it doesn't, then you can install rust-src with rustup component add rust-src.
I don't know if that's the problem - it's just the only idea that comes to mind.
I have this piece of code having issue only with Vectors and not on regular struct. I have to note that this is working for both cases in one system, but no on the other. Have tried ":internal_debug" and shows no difference between working and non working version. What could be the cause of not completing tab completion? I am able to print the actual value though even in non working case. Does this need rust-analyzer to be installed?
The text was updated successfully, but these errors were encountered: