Skip to content

Commit b670b3e

Browse files
committed
Merge branch 'main' into release
2 parents 069e0d1 + 078c3dc commit b670b3e

File tree

3 files changed

+26
-2
lines changed

3 files changed

+26
-2
lines changed

.github/workflows/verus.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- name: Install Rust Toolchain
2626
run: |
2727
rustup update --no-self-update stable
28-
rustup install 1.91.0-x86_64-unknown-linux-gnu
28+
rustup install 1.92.0-x86_64-unknown-linux-gnu
2929
3030
- name: Get the URL for the latest Verus release
3131
id: verus-release-info

README.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,30 @@ since `rust-analyzer` changed the type it expects for this setting.
129129
vstd = { path = "../verus/source/vstd"} # assuming verus and the project are in the same directory
130130
```
131131

132+
## Proc Macros
133+
134+
You may run into an error like the following:
135+
```
136+
Failed spawning proc-macro server for workspace /home/user/Documents/verus/verus_test/Cargo.toml: Failed to run proc-macro server from path /home/user/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/libexec/rust-analyzer-proc-macro-srv, error: Custom { kind: Other, error: "proc-macro server's api version (6) is newer than rust-analyzer's (4)" }
137+
```
138+
139+
The problem is that the protocol that `rust-analyzer` uses to talk to the
140+
proc-macro server changes as Rust versions change. However, `verus-analyzer`
141+
evolves more slowly and hence can't talk to the proc-macro server in the latest
142+
versions of Rust.
143+
144+
If your code doesn't use proc macros, then the simplest solution is to look in
145+
the settings for the extension and make sure they are disabled (e.g.,
146+
`"verus-analyzer.procMacro.enable": false,`).
147+
148+
If your code does use proc macros, then you'll need to install an older Rust toolchain; specifically 1.79, e.g., `rustup toolchain install 1.79.0-aarch64-apple-darwin`. Then you'll need to add these settings to your VS Code `settings.json` file:
149+
```
150+
"verus-analyzer.server.extraEnv": { "RUSTUP_TOOLCHAIN": "1.79.0-aarch64-apple-darwin" },
151+
"verus-analyzer.procMacro.server": "/Users/username/.rustup/toolchains/1.79.0-aarch64-apple-darwin/libexec/rust-analyzer-proc-macro-srv",
152+
```
153+
(with appropriate edits to your toolchain and paths).
154+
155+
132156
---
133157
## Proof Actions
134158

editors/code/src/bootstrap.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ const execFileAsync = promisify(execFile);
241241
export async function validRustToolchain(): Promise<Boolean> {
242242
// TODO: Add a config flag for the expected toolchain version
243243
const TOOLCHAIN_FULL = 1;
244-
const TOOLCHAIN_MAJOR = 91;
244+
const TOOLCHAIN_MAJOR = 92;
245245
const TOOLCHAIN_MINOR = 0;
246246

247247
const { path: rustup_executable } = await findRustup();

0 commit comments

Comments
 (0)