Skip to content

Syntastic integration: rustc not enabled as a checker #118

Description

@jmatraszek

Using rustc stable (1.12.0), Vim 8.0, rust.vim 2030019 and Syntastic 3.7.0-243.
SyntasticInfo output:

Syntastic version: 3.7.0-243 (Vim 800, Linux, GUI)
Info for filetype: rust
Global mode: active
Filetype rust is active
The current file will be checked automatically
Available checker: rustc
Currently enabled checkers: -  

Nothing happens on save or calling SyntasticCheck.

After running let g:syntastic_rust_checkers = ['rustc'] works as expected. Right now I am using autocmd FileType rust let g:syntastic_rust_checkers = ['rustc'] in .vimrc as a workaround.

P.S. I know there is a bunch of other Syntastic related issues, but all of them seems to be different (problems with error format, rustc is enabled as a checker but still does not work etc. etc.).

Activity

  1. josephfrazier commented on Nov 2, 2016

    @josephfrazier

    I experienced the same issue with rustc 1.12.1, Vim 8.0.55, rust.vim 59e5e2f, and Syntastic 3.8.0-3.
    SyntasticInfo output:

    Syntastic version: 3.8.0-3 (Vim 800, Darwin)
    Info for filetype: rust
    Global mode: active
    Filetype rust is active
    The current file will be checked automatically
    Available checker: rustc
    Currently enabled checkers: -
    

    The workaround posted above worked for me (thanks @jmatraszek!)

  2. shibotto commented on Nov 4, 2016

    @shibotto

    @jmatraszek is autocmd FileType rust really necessary? Shouldn't Syntastic itself manage filetypes?

  3. gawen commented on Dec 13, 2016

    @gawen

    Thanks for the workaround.

    I experience the same issue with rust.vim eed97e7, rustc 1.15.0 (nightly daf8c1dfc) and rustc 1.13.0, Vim 8.0, Syntastic 3.8.0-2.

    Syntastic version: 3.8.0-2 (Vim 800, Linux, GUI)
    Info for filetype: rust
    Global mode: active
    Filetype rust is active
    The current file will be checked automatically
    Available checker: rustc
    Currently enabled checkers: -
    
  4. grawlinson commented on Jan 16, 2017

    @grawlinson

    Just chiming in to say that I had to do the same as others in this issue to solve this issue.

    let g:syntastic_rust_checkers = ['rustc'] inside my vimrc.

  5. ajcrites commented on Apr 2, 2017

    @ajcrites

    While this generally works, Syntastic will report errors for extern crate .... Is there any way to suppress this?

  6. shibotto commented on Apr 3, 2017

    @shibotto

    @ajcrites if you have cargo>=0.16 you can use it instead of rustc. Unfortunately cargo support is not yet merged in rust.vim but you can manually merge (aka copy-paste) it from one of this two pull request:

    #147
    #132

    then check if it is detected with :SyntasticInfo and if everything is fine you can add let g:syntastic_rust_checkers = ['cargo'] to your .vimrc. I'm using it and it seems to work fine.

  7. beamspease commented on Apr 14, 2017

    @beamspease

    Would be great to see one of these pull requests get accepted. I found this from looking to see if cargo check was supported yet since I've been having to disable Syntastic now that my project has gotten large enough that it takes notable time to compile. Cargo check however is just a couple of seconds or so.

  8. tafia commented on Oct 25, 2017

    @tafia

    Same here for rust 1.22. Workaround is working fine. Would be good to put it on the readme at least.
    Thanks anyway!

  9. seanmonstar commented on Nov 14, 2017

    @seanmonstar
    Contributor

    Anyone driving by, #132 was merged. Just setting let g:syntastic_rust_checkers = ['cargo'] in your vimrc will get you cargo check running on saves.

    This could probably be closed.

  10. da-x commented on Jun 30, 2018

    @da-x
    Member

    let g:syntastic_rust_checkers = ['cargo'] is now the default if nothing is specified. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions