TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Rust, RR, Neovim: A perfect debug combination

159 点作者 zteppenwolf大约 2 年前

12 条评论

DixieDev大约 2 年前
Anyone got other useful tools for debugging within (neo)vim? Just seamlessly putting down breakpoints, stepping through code execution, and getting a fully fledged debugging UI experience (a la Visual Studio or Remedy BG)? This is possibly the only thing I miss from developing on Windows, and it&#x27;s a shame!<p>EDIT: I specified &#x27;within vim&#x27; but actually I&#x27;d be down for standalone Linux app recommendations too.
评论 #35524605 未加载
评论 #35523479 未加载
评论 #35523582 未加载
评论 #35531662 未加载
评论 #35524102 未加载
评论 #35523301 未加载
评论 #35523599 未加载
评论 #35524052 未加载
评论 #35524417 未加载
评论 #35525105 未加载
评论 #35523970 未加载
评论 #35523393 未加载
评论 #35525737 未加载
JestUM大约 2 年前
Investing in a good debugging tool and knowing your way around using it well, makes all the difference.
评论 #35523315 未加载
评论 #35523277 未加载
评论 #35524038 未加载
nu11ptr大约 2 年前
I personally have never used a debugger in Rust. Logging and printing has typically been enough.<p>For those use cases where it is tough to see the output (tests, windows services, etc.) I wrote the `rdbg` set of crates. It is essentially identical to `dbg!` and `println!` macros, but delivers messages via a TCP socket to a simple command-line viewer (which can be on the same machine or remote). The design is such that it can be enabled and used the first time within a minute or two for &quot;quick and dirty debugging&quot;. It can just as quickly be removed or turned into a no-op with a Rust feature.<p>Dependency: <a href="https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;rdbg" rel="nofollow">https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;rdbg</a><p>Viewer: <a href="https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;rdbg-view" rel="nofollow">https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;rdbg-view</a><p>EDIT: Apparently I need to update the README as I added the &#x27;msgf&#x27; and &#x27;valsf&#x27; macros that include auto-flush which is handy for short running programs where explicit flush doesn&#x27;t work due to failing program&#x2F;etc.
评论 #35526671 未加载
fcoury大约 2 年前
I have written an extension for VSCode that replicates the repeat last test feature and lets you run the test under the cursor.<p><a href="https:&#x2F;&#x2F;marketplace.visualstudio.com&#x2F;items?itemName=fcoury.runst" rel="nofollow">https:&#x2F;&#x2F;marketplace.visualstudio.com&#x2F;items?itemName=fcoury.r...</a>
thegeomaster大约 2 年前
Only if you&#x27;re debugging tests.<p>Unfortunately using rr to debug a bigger application with lots of RAM access is not feasible.
评论 #35523198 未加载
评论 #35523941 未加载
colesantiago大约 2 年前
Can someone explain what I am looking at here with this? Genuine question.
评论 #35523072 未加载
baq大约 2 年前
rr is basically black magic
评论 #35523143 未加载
RcouF1uZ4gsC大约 2 年前
Does this setup have nice visualizations of data structures? Can it show a Vec as a list of values or a HashMap as a list of (key,value)?
评论 #35525137 未加载
评论 #35528864 未加载
Aiedail大约 2 年前
Is there a similar tool for python? I don&#x27;t like the DAP solution but prefer a gdb like python debugger :(
n8henrie大约 2 年前
I hadn&#x27;t realized there were alternatives to rust-lldb for debugging rust. I have some reading to do.
sp0ck大约 2 年前
Funny thing is that thanks to rust compiler I never had a need to debug my code :-)
评论 #35523534 未加载
评论 #35523303 未加载
评论 #35523601 未加载
favadi大约 2 年前
rr is pure magic! I wish that it is available on macOS.
评论 #35524298 未加载