In RLS, how do you tell if a tab completion is from racer or rust-analysis

fn t() {
    let mut x = vec![1,2,3];
    let y = x.l // I was about to enter len()

However, this is no tab completion unless I annotate let mut x: Vec<_>. (I am using VS Code with vscode-rust extension)

I suspect it might because my racer is not correctly configured. But I cannot tell as RLS doesn't tell me if a tab completion is performed from racer or rust-analysis (compiler). Is there a way to check it out?

1 Like

Racer not is capable of completing that code as it cannot detect the return type of macros. For racer's completion to work, you need to specify the type as you did. I'm not sure if pure RLS is capable of providing this completion.