Fel*_*des 5 vim compiler-errors rust
我使用Syntastic,而vim中的错误消息通常只有一行,我发现此信息不足。
是否有编译器标记,因此错误的第一行更有意义,或者使我可以在quickfix窗口中看到多行错误?我必须不断地cargo build
将错误转移到某个地方,这应该只是“把鼠标放在光标上”,通常错误适合空间(我有一个宽显示器)。
我正在使用macOS。
您需要在 vim 中正确设置 Syntastic 和 rust 包。请参阅我的 vimrc 中的示例(使用 Vundle):
" vimrc
Plugin 'vim-syntastic/syntastic'
Plugin 'rust-lang/rust.vim'
Plugin 'racer-rust/vim-racer'
Plugin 'timonv/vim-cargo'
" Syntastic
let g:syntastic_error_symbol = 'EE'
let g:syntastic_style_error_symbol = 'E>'
let g:syntastic_warning_symbol = 'WW'
let g:syntastic_style_warning_symbol = 'W>'
let g:syntastic_auto_loc_list = 1
let g:syntastic_rust_checkers = ['cargo']
Run Code Online (Sandbox Code Playgroud)