Atom Packages Directory

a package directory for a text editor of the 21st Century

Linter Csound

Install with:
    apm install linter-csound

Csound Linting in Atom

This Atom package adds syntax checking for Csound orchestras.


Open an issue, or fork this project and make a pull request.

linter-csound’s Orchestra Parser

To check the syntax of orchestras, linter-csound uses a preprocessor and parser generated using the GerHobbelt fork of Jison. The grammar used by the parser is based on this JavaScript grammar (which you can read about here) and this C grammar. To generate the preprocessor and parser on macOS, open a Terminal, cd to linter-csound, and run:

sh npm install pushd lib/csound-parser ../../node_modules/jison-lex/cli.js preprocessor.jisonlex --outfile preprocessor.js ../../node_modules/jison-gho/lib/cli.js orchestra.jison orchestra.jisonlex --outfile orchestra-parser.js popd

The linter-csound preprocessor and parser try to match Csound’s behavior, but linter-csound’s implementations are quite different. Here is how linter-csound’s Jison files correspond to Csound’s Flex/Bison files:

This Jison file Corresponds to this Flex/Bison file
preprocessor.jisonlex csound_pre.lex
orchestra.jisonlex csound_orc.lex
orchestra.jison csound_orc.y

Known Differences from Csound’s Preprocessor

Csound’s preprocessor:

Known Differences from Csound’s Parser

Keywords: csound, music, sound Suggest keywords
Fork me on GitHub