Notgnoshi / dotfiles

Personal dotfiles and shell scripts
https://agill.xyz
0 stars 0 forks source link

Debugging and test improvements #107

Closed Notgnoshi closed 9 months ago

Notgnoshi commented 10 months ago

Depends on https://github.com/Notgnoshi/rust.vim/pull/1

Closes #105

Notgnoshi commented 10 months ago

Need to fix the vimspector sign background color

image

Notgnoshi commented 10 months ago

How to use rust-gdb or make lldb more rust-aware (pretty printing)?

Notgnoshi commented 10 months ago

Something in here is inconsistent.

Within a single Vim session, sometimes I have to do :Make build, and others just :Make

This is a conflict between rust.vim setting makeprg = cargo $* and dispatch.vim setting makeprg = cargo build

image

The root cause of the makeprg shenanigans is https://github.com/tpope/vim-dispatch/issues/310 which explains that makeprg is buffer-local, so it does unexpected things when you run :Make from the quickfix list vs from a buffer with the rust filetype.

augroup RestoreRustMakeprg
    autocmd!
    autocmd BufEnter * execute 'set makeprg=cargo'
augroup END

in after/ftplugin/rust.vim works as a workaround.

Edit: This is resolved. As tpope mentioned in the linked issue, the cause was an autocmd in my own vimrc.