Skip to content

Commit 9abca66

Browse files
committed
feat(wiki): Add how to enable rust-analyzer at wiki page
Signed-off-by: Chen Miao <[email protected]>
1 parent 585e5d9 commit 9abca66

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/wiki/wiki_index.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,17 @@ Filesystem Size Used Avail Use% Mounted on
322322

323323
至此,启动一个 Rust for Linux 编译的内核镜像就成功完成了。
324324

325+
### TIPs:启用 rust anaylzer
326+
327+
Rust for Linux 为用户提供了 `make rust-analyzer` 的命令以启用 `rust-analyzer` 更为方便的编写和查看 rust 代码。
328+
329+
通常,我会使用如下步骤启用 `clangd``analyzer` 以支持内核 C 语言源码和 Rust 代码:
330+
331+
``` bash
332+
bear -- make LLVM=1 -j`nproc`
333+
make LLVM=1 rust-analyzer
334+
```
335+
325336
---
326337

327338
参考链接

0 commit comments

Comments
 (0)