Search code examples
vimsyntastic

Syntastic NASM Checker


So I've been doing some work in my Assembly class for college, and I use Vim as my primary code editor. I'm having a problem with Syntastic where I'm writing assembly for NASM, but Syntastic only wants to run the gcc error checker (which tells me all my code is wrong). I tried to run the NASM checker explicitly with SyntasticCheck nasm but that didn't seem to work. I also attempted to let g:syntastic_asm_checkers = ['nasm'] in my .vimrc but that didn't seem to do anything. How can I get Syntastic to run the NASM checker here?

As a note, I tested this by just writing something like mov eax, to get an error out of NASM.


Solution

  • As mentioned in the comments above, it turns out nasm only works for files with a nasm file extension. After renaming my file to <file>.nasm I discovered that vim doesn't automatically detect the nasm filetype after running set ft?, so I'll have to modify my .vimrc to support the extension.