SOUL
SOUL copied to clipboard
Syntax highlighting for SOUL & HEART in VSCode & Atom
Changes
- Improve SOUL highlighting in VSCode:
- Add numeric literals (
i32
,_i64
, ...) and a couple missing types (stream
,value
) - Improved
constant.numeric.*
and checked withsoul errors
(and added octal). - Add highlighting that detects
module
, functions,enum|struct
andusing
patterns. - Add a couple operators and moved a few storage types to more specific categories, i.e.
storage.class
andstorage.modifier
. -
processor.*
is considered a constant.
- Add numeric literals (
- Add highlighting for HEART, same as SOUL some diffs:
- Less complex literal notation, e.g. only
L
for integers. - Highlighting for
function
. - Highlight core functions, e.g. read, write.
- Highlight state variables and blocks
- Less complex literal notation, e.g. only
- Add some snippets for SOUL in VSCode.
- Add packages for Atom for SOUL & HEART.
- A few typos.
Soulpatch
Also, might be worth mentioning in tools/editors/vs_code_extension/README.md
that you can associate a .soulpatch
file to JSON to get highlighting by adding this to the file association setting in VSCode:
"files.associations": {
"*.soulpatch": "json"
},
Note for porting to Atom
Both editors use regex pattern matching with TextMate grammar so porting is trivial. Basically just json2cson
. Some patterns regarding bracket and parentheses detection were removed because they were interfering with other rules.