Skip to content

Q4: VSCode can't jump to defined function or struct? #4

Open
@yangwenmai

Description

@yangwenmai

解决办法

  1. 首先你得安装最新的 nightly 版本;

查看可用的最新的 nightly 版本:https://rust-lang.github.io/rustup-components-history/index.html

  1. VSCode 安装 RLS 服务;
  2. 命令行安装:
$ rustup component add rust-src --toolchain nightly-2019-04-21-x86_64-apple-darwin
$ rustup component add rust-analysis --toolchain nightly-2019-04-21-x86_64-apple-darwin
$ rustup component add rls --toolchain nightly-2019-04-21-x86_64-apple-darwin
$ rustup component add rustfmt --toolchain nightly-2019-04-21-x86_64-apple-darwin

我安装好之后,但是我的项目 guessing_game 中的 rand 相关库还是无法点击跳转呢?

原因是因为我的 toml 里面的 rand 版本设置为 0.3.23,只需要将 toml 里面的 rand 依赖版本改成0.4.0 就可以点击跳转了。

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions