ace-oqc 1.4.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +7 -0
- package/src-noconflict/ace.js +21402 -0
- package/src-noconflict/ext-beautify.js +331 -0
- package/src-noconflict/ext-elastic_tabstops_lite.js +277 -0
- package/src-noconflict/ext-emmet.js +1331 -0
- package/src-noconflict/ext-error_marker.js +9 -0
- package/src-noconflict/ext-keybinding_menu.js +193 -0
- package/src-noconflict/ext-language_tools.js +2166 -0
- package/src-noconflict/ext-linking.js +64 -0
- package/src-noconflict/ext-modelist.js +248 -0
- package/src-noconflict/ext-options.js +799 -0
- package/src-noconflict/ext-prompt.js +2806 -0
- package/src-noconflict/ext-rtl.js +122 -0
- package/src-noconflict/ext-searchbox.js +514 -0
- package/src-noconflict/ext-settings_menu.js +820 -0
- package/src-noconflict/ext-spellcheck.js +73 -0
- package/src-noconflict/ext-split.js +207 -0
- package/src-noconflict/ext-static_highlight.js +229 -0
- package/src-noconflict/ext-statusbar.js +56 -0
- package/src-noconflict/ext-textarea.js +430 -0
- package/src-noconflict/ext-themelist.js +67 -0
- package/src-noconflict/ext-whitespace.js +213 -0
- package/src-noconflict/keybinding-emacs.js +1169 -0
- package/src-noconflict/keybinding-sublime.js +422 -0
- package/src-noconflict/keybinding-vim.js +6198 -0
- package/src-noconflict/mode-abap.js +221 -0
- package/src-noconflict/mode-abc.js +271 -0
- package/src-noconflict/mode-actionscript.js +275 -0
- package/src-noconflict/mode-ada.js +137 -0
- package/src-noconflict/mode-apache_conf.js +363 -0
- package/src-noconflict/mode-apex.js +457 -0
- package/src-noconflict/mode-applescript.js +278 -0
- package/src-noconflict/mode-aql.js +102 -0
- package/src-noconflict/mode-asciidoc.js +349 -0
- package/src-noconflict/mode-asl.js +422 -0
- package/src-noconflict/mode-assembly_x86.js +193 -0
- package/src-noconflict/mode-autohotkey.js +244 -0
- package/src-noconflict/mode-batchfile.js +230 -0
- package/src-noconflict/mode-c9search.js +293 -0
- package/src-noconflict/mode-c_cpp.js +503 -0
- package/src-noconflict/mode-cirru.js +210 -0
- package/src-noconflict/mode-clojure.js +315 -0
- package/src-noconflict/mode-cobol.js +101 -0
- package/src-noconflict/mode-coffee.js +400 -0
- package/src-noconflict/mode-coldfusion.js +2596 -0
- package/src-noconflict/mode-crystal.js +642 -0
- package/src-noconflict/mode-csharp.js +502 -0
- package/src-noconflict/mode-csound_document.js +4105 -0
- package/src-noconflict/mode-csound_orchestra.js +3035 -0
- package/src-noconflict/mode-csound_score.js +462 -0
- package/src-noconflict/mode-csp.js +59 -0
- package/src-noconflict/mode-css.js +720 -0
- package/src-noconflict/mode-curly.js +2564 -0
- package/src-noconflict/mode-d.js +520 -0
- package/src-noconflict/mode-dart.js +715 -0
- package/src-noconflict/mode-diff.js +147 -0
- package/src-noconflict/mode-django.js +2595 -0
- package/src-noconflict/mode-dockerfile.js +500 -0
- package/src-noconflict/mode-dot.js +417 -0
- package/src-noconflict/mode-drools.js +498 -0
- package/src-noconflict/mode-edifact.js +166 -0
- package/src-noconflict/mode-eiffel.js +135 -0
- package/src-noconflict/mode-ejs.js +3533 -0
- package/src-noconflict/mode-elixir.js +501 -0
- package/src-noconflict/mode-elm.js +306 -0
- package/src-noconflict/mode-erlang.js +1010 -0
- package/src-noconflict/mode-forth.js +297 -0
- package/src-noconflict/mode-fortran.js +430 -0
- package/src-noconflict/mode-fsharp.js +316 -0
- package/src-noconflict/mode-fsl.js +259 -0
- package/src-noconflict/mode-ftl.js +1193 -0
- package/src-noconflict/mode-gcode.js +93 -0
- package/src-noconflict/mode-gherkin.js +168 -0
- package/src-noconflict/mode-gitignore.js +59 -0
- package/src-noconflict/mode-glsl.js +580 -0
- package/src-noconflict/mode-gobstones.js +1090 -0
- package/src-noconflict/mode-golang.js +413 -0
- package/src-noconflict/mode-graphqlschema.js +214 -0
- package/src-noconflict/mode-groovy.js +989 -0
- package/src-noconflict/mode-haml.js +1873 -0
- package/src-noconflict/mode-handlebars.js +2622 -0
- package/src-noconflict/mode-haskell.js +380 -0
- package/src-noconflict/mode-haskell_cabal.js +141 -0
- package/src-noconflict/mode-haxe.js +386 -0
- package/src-noconflict/mode-hjson.js +353 -0
- package/src-noconflict/mode-html.js +2509 -0
- package/src-noconflict/mode-html_elixir.js +3088 -0
- package/src-noconflict/mode-html_ruby.js +3550 -0
- package/src-noconflict/mode-ini.js +162 -0
- package/src-noconflict/mode-io.js +248 -0
- package/src-noconflict/mode-jack.js +346 -0
- package/src-noconflict/mode-jade.js +2025 -0
- package/src-noconflict/mode-java.js +1038 -0
- package/src-noconflict/mode-javascript.js +798 -0
- package/src-noconflict/mode-json.js +329 -0
- package/src-noconflict/mode-jsoniq.js +2632 -0
- package/src-noconflict/mode-jsp.js +1433 -0
- package/src-noconflict/mode-jssm.js +325 -0
- package/src-noconflict/mode-jsx.js +411 -0
- package/src-noconflict/mode-julia.js +303 -0
- package/src-noconflict/mode-kotlin.js +797 -0
- package/src-noconflict/mode-latex.js +296 -0
- package/src-noconflict/mode-less.js +839 -0
- package/src-noconflict/mode-liquid.js +2742 -0
- package/src-noconflict/mode-lisp.js +112 -0
- package/src-noconflict/mode-livescript.js +279 -0
- package/src-noconflict/mode-logiql.js +317 -0
- package/src-noconflict/mode-logtalk.js +352 -0
- package/src-noconflict/mode-lsl.js +343 -0
- package/src-noconflict/mode-lua.js +452 -0
- package/src-noconflict/mode-luapage.js +3028 -0
- package/src-noconflict/mode-lucene.js +154 -0
- package/src-noconflict/mode-makefile.js +412 -0
- package/src-noconflict/mode-markdown.js +3194 -0
- package/src-noconflict/mode-mask.js +1803 -0
- package/src-noconflict/mode-matlab.js +263 -0
- package/src-noconflict/mode-maze.js +292 -0
- package/src-noconflict/mode-mel.js +263 -0
- package/src-noconflict/mode-mixal.js +122 -0
- package/src-noconflict/mode-mushcode.js +681 -0
- package/src-noconflict/mode-mysql.js +167 -0
- package/src-noconflict/mode-nginx.js +298 -0
- package/src-noconflict/mode-nim.js +363 -0
- package/src-noconflict/mode-nix.js +647 -0
- package/src-noconflict/mode-nsis.js +312 -0
- package/src-noconflict/mode-objectivec.js +740 -0
- package/src-noconflict/mode-ocaml.js +421 -0
- package/src-noconflict/mode-pascal.js +223 -0
- package/src-noconflict/mode-perl.js +381 -0
- package/src-noconflict/mode-pgsql.js +1743 -0
- package/src-noconflict/mode-php.js +13110 -0
- package/src-noconflict/mode-php_laravel_blade.js +13311 -0
- package/src-noconflict/mode-pig.js +310 -0
- package/src-noconflict/mode-plain_text.js +32 -0
- package/src-noconflict/mode-powershell.js +418 -0
- package/src-noconflict/mode-praat.js +478 -0
- package/src-noconflict/mode-prolog.js +371 -0
- package/src-noconflict/mode-properties.js +80 -0
- package/src-noconflict/mode-protobuf.js +593 -0
- package/src-noconflict/mode-puppet.js +368 -0
- package/src-noconflict/mode-python.js +508 -0
- package/src-noconflict/mode-r.js +312 -0
- package/src-noconflict/mode-razor.js +2875 -0
- package/src-noconflict/mode-rdoc.js +243 -0
- package/src-noconflict/mode-red.js +450 -0
- package/src-noconflict/mode-redshift.js +360 -0
- package/src-noconflict/mode-rhtml.js +2808 -0
- package/src-noconflict/mode-rst.js +257 -0
- package/src-noconflict/mode-ruby.js +1003 -0
- package/src-noconflict/mode-rust.js +282 -0
- package/src-noconflict/mode-sass.js +529 -0
- package/src-noconflict/mode-scad.js +414 -0
- package/src-noconflict/mode-scala.js +984 -0
- package/src-noconflict/mode-scheme.js +232 -0
- package/src-noconflict/mode-scss.js +873 -0
- package/src-noconflict/mode-sh.js +449 -0
- package/src-noconflict/mode-sjs.js +1015 -0
- package/src-noconflict/mode-slim.js +5240 -0
- package/src-noconflict/mode-smarty.js +2635 -0
- package/src-noconflict/mode-snippets.js +207 -0
- package/src-noconflict/mode-soy_template.js +2848 -0
- package/src-noconflict/mode-space.js +167 -0
- package/src-noconflict/mode-sparql.js +320 -0
- package/src-noconflict/mode-sql.js +271 -0
- package/src-noconflict/mode-sqlserver.js +445 -0
- package/src-noconflict/mode-stylus.js +472 -0
- package/src-noconflict/mode-svg.js +1582 -0
- package/src-noconflict/mode-swift.js +395 -0
- package/src-noconflict/mode-tcl.js +387 -0
- package/src-noconflict/mode-terraform.js +400 -0
- package/src-noconflict/mode-tex.js +160 -0
- package/src-noconflict/mode-text.js +9 -0
- package/src-noconflict/mode-textile.js +150 -0
- package/src-noconflict/mode-toml.js +153 -0
- package/src-noconflict/mode-tsx.js +888 -0
- package/src-noconflict/mode-turtle.js +296 -0
- package/src-noconflict/mode-twig.js +2693 -0
- package/src-noconflict/mode-typescript.js +869 -0
- package/src-noconflict/mode-vala.js +677 -0
- package/src-noconflict/mode-vbscript.js +635 -0
- package/src-noconflict/mode-velocity.js +2792 -0
- package/src-noconflict/mode-verilog.js +118 -0
- package/src-noconflict/mode-vhdl.js +116 -0
- package/src-noconflict/mode-visualforce.js +2640 -0
- package/src-noconflict/mode-wollok.js +914 -0
- package/src-noconflict/mode-xml.js +676 -0
- package/src-noconflict/mode-xquery.js +2644 -0
- package/src-noconflict/mode-yaml.js +330 -0
- package/src-noconflict/mode-zeek.js +539 -0
- package/src-noconflict/qurator-mode.js +120 -0
- package/src-noconflict/qurator-worker.js +91 -0
- package/src-noconflict/snippets/abap.js +9 -0
- package/src-noconflict/snippets/abc.js +45 -0
- package/src-noconflict/snippets/actionscript.js +171 -0
- package/src-noconflict/snippets/ada.js +9 -0
- package/src-noconflict/snippets/apache_conf.js +9 -0
- package/src-noconflict/snippets/apex.js +9 -0
- package/src-noconflict/snippets/applescript.js +9 -0
- package/src-noconflict/snippets/aql.js +9 -0
- package/src-noconflict/snippets/asciidoc.js +9 -0
- package/src-noconflict/snippets/asl.js +9 -0
- package/src-noconflict/snippets/assembly_x86.js +9 -0
- package/src-noconflict/snippets/autohotkey.js +9 -0
- package/src-noconflict/snippets/batchfile.js +9 -0
- package/src-noconflict/snippets/c9search.js +9 -0
- package/src-noconflict/snippets/c_cpp.js +145 -0
- package/src-noconflict/snippets/cirru.js +9 -0
- package/src-noconflict/snippets/clojure.js +104 -0
- package/src-noconflict/snippets/cobol.js +9 -0
- package/src-noconflict/snippets/coffee.js +109 -0
- package/src-noconflict/snippets/coldfusion.js +9 -0
- package/src-noconflict/snippets/crystal.js +9 -0
- package/src-noconflict/snippets/csharp.js +9 -0
- package/src-noconflict/snippets/csound_document.js +24 -0
- package/src-noconflict/snippets/csound_orchestra.js +61 -0
- package/src-noconflict/snippets/csound_score.js +9 -0
- package/src-noconflict/snippets/csp.js +9 -0
- package/src-noconflict/snippets/css.js +981 -0
- package/src-noconflict/snippets/curly.js +9 -0
- package/src-noconflict/snippets/d.js +9 -0
- package/src-noconflict/snippets/dart.js +97 -0
- package/src-noconflict/snippets/diff.js +25 -0
- package/src-noconflict/snippets/django.js +122 -0
- package/src-noconflict/snippets/dockerfile.js +9 -0
- package/src-noconflict/snippets/dot.js +9 -0
- package/src-noconflict/snippets/drools.js +33 -0
- package/src-noconflict/snippets/edifact.js +254 -0
- package/src-noconflict/snippets/eiffel.js +9 -0
- package/src-noconflict/snippets/ejs.js +9 -0
- package/src-noconflict/snippets/elixir.js +9 -0
- package/src-noconflict/snippets/elm.js +9 -0
- package/src-noconflict/snippets/erlang.js +174 -0
- package/src-noconflict/snippets/forth.js +9 -0
- package/src-noconflict/snippets/fortran.js +9 -0
- package/src-noconflict/snippets/fsharp.js +9 -0
- package/src-noconflict/snippets/fsl.js +14 -0
- package/src-noconflict/snippets/ftl.js +9 -0
- package/src-noconflict/snippets/gcode.js +9 -0
- package/src-noconflict/snippets/gherkin.js +9 -0
- package/src-noconflict/snippets/gitignore.js +9 -0
- package/src-noconflict/snippets/glsl.js +9 -0
- package/src-noconflict/snippets/gobstones.js +1718 -0
- package/src-noconflict/snippets/golang.js +9 -0
- package/src-noconflict/snippets/graphqlschema.js +46 -0
- package/src-noconflict/snippets/groovy.js +9 -0
- package/src-noconflict/snippets/haml.js +34 -0
- package/src-noconflict/snippets/handlebars.js +9 -0
- package/src-noconflict/snippets/haskell.js +96 -0
- package/src-noconflict/snippets/haskell_cabal.js +9 -0
- package/src-noconflict/snippets/haxe.js +9 -0
- package/src-noconflict/snippets/hjson.js +9 -0
- package/src-noconflict/snippets/html.js +867 -0
- package/src-noconflict/snippets/html_elixir.js +9 -0
- package/src-noconflict/snippets/html_ruby.js +9 -0
- package/src-noconflict/snippets/ini.js +9 -0
- package/src-noconflict/snippets/io.js +76 -0
- package/src-noconflict/snippets/jack.js +9 -0
- package/src-noconflict/snippets/jade.js +9 -0
- package/src-noconflict/snippets/java.js +254 -0
- package/src-noconflict/snippets/javascript.js +209 -0
- package/src-noconflict/snippets/json.js +9 -0
- package/src-noconflict/snippets/jsoniq.js +75 -0
- package/src-noconflict/snippets/jsp.js +113 -0
- package/src-noconflict/snippets/jssm.js +9 -0
- package/src-noconflict/snippets/jsx.js +9 -0
- package/src-noconflict/snippets/julia.js +9 -0
- package/src-noconflict/snippets/kotlin.js +9 -0
- package/src-noconflict/snippets/latex.js +9 -0
- package/src-noconflict/snippets/less.js +9 -0
- package/src-noconflict/snippets/liquid.js +895 -0
- package/src-noconflict/snippets/lisp.js +9 -0
- package/src-noconflict/snippets/livescript.js +9 -0
- package/src-noconflict/snippets/logiql.js +9 -0
- package/src-noconflict/snippets/logtalk.js +9 -0
- package/src-noconflict/snippets/lsl.js +1246 -0
- package/src-noconflict/snippets/lua.js +35 -0
- package/src-noconflict/snippets/luapage.js +9 -0
- package/src-noconflict/snippets/lucene.js +9 -0
- package/src-noconflict/snippets/makefile.js +18 -0
- package/src-noconflict/snippets/markdown.js +102 -0
- package/src-noconflict/snippets/mask.js +9 -0
- package/src-noconflict/snippets/matlab.js +9 -0
- package/src-noconflict/snippets/maze.js +23 -0
- package/src-noconflict/snippets/mel.js +9 -0
- package/src-noconflict/snippets/mixal.js +9 -0
- package/src-noconflict/snippets/mushcode.js +9 -0
- package/src-noconflict/snippets/mysql.js +9 -0
- package/src-noconflict/snippets/nginx.js +9 -0
- package/src-noconflict/snippets/nim.js +9 -0
- package/src-noconflict/snippets/nix.js +9 -0
- package/src-noconflict/snippets/nsis.js +9 -0
- package/src-noconflict/snippets/objectivec.js +9 -0
- package/src-noconflict/snippets/ocaml.js +9 -0
- package/src-noconflict/snippets/pascal.js +9 -0
- package/src-noconflict/snippets/perl.js +361 -0
- package/src-noconflict/snippets/pgsql.js +9 -0
- package/src-noconflict/snippets/php.js +397 -0
- package/src-noconflict/snippets/php_laravel_blade.js +9 -0
- package/src-noconflict/snippets/pig.js +9 -0
- package/src-noconflict/snippets/plain_text.js +9 -0
- package/src-noconflict/snippets/powershell.js +9 -0
- package/src-noconflict/snippets/praat.js +9 -0
- package/src-noconflict/snippets/prolog.js +9 -0
- package/src-noconflict/snippets/properties.js +9 -0
- package/src-noconflict/snippets/protobuf.js +9 -0
- package/src-noconflict/snippets/puppet.js +9 -0
- package/src-noconflict/snippets/python.js +172 -0
- package/src-noconflict/snippets/r.js +135 -0
- package/src-noconflict/snippets/razor.js +17 -0
- package/src-noconflict/snippets/rdoc.js +9 -0
- package/src-noconflict/snippets/red.js +9 -0
- package/src-noconflict/snippets/redshift.js +9 -0
- package/src-noconflict/snippets/rhtml.js +9 -0
- package/src-noconflict/snippets/rst.js +36 -0
- package/src-noconflict/snippets/ruby.js +942 -0
- package/src-noconflict/snippets/rust.js +9 -0
- package/src-noconflict/snippets/sass.js +9 -0
- package/src-noconflict/snippets/scad.js +9 -0
- package/src-noconflict/snippets/scala.js +9 -0
- package/src-noconflict/snippets/scheme.js +9 -0
- package/src-noconflict/snippets/scss.js +9 -0
- package/src-noconflict/snippets/sh.js +97 -0
- package/src-noconflict/snippets/sjs.js +9 -0
- package/src-noconflict/snippets/slim.js +9 -0
- package/src-noconflict/snippets/smarty.js +9 -0
- package/src-noconflict/snippets/snippets.js +23 -0
- package/src-noconflict/snippets/soy_template.js +9 -0
- package/src-noconflict/snippets/space.js +9 -0
- package/src-noconflict/snippets/sparql.js +9 -0
- package/src-noconflict/snippets/sql.js +40 -0
- package/src-noconflict/snippets/sqlserver.js +83 -0
- package/src-noconflict/snippets/stylus.js +9 -0
- package/src-noconflict/snippets/svg.js +9 -0
- package/src-noconflict/snippets/swift.js +9 -0
- package/src-noconflict/snippets/tcl.js +106 -0
- package/src-noconflict/snippets/terraform.js +9 -0
- package/src-noconflict/snippets/tex.js +204 -0
- package/src-noconflict/snippets/text.js +9 -0
- package/src-noconflict/snippets/textile.js +44 -0
- package/src-noconflict/snippets/toml.js +9 -0
- package/src-noconflict/snippets/tsx.js +9 -0
- package/src-noconflict/snippets/turtle.js +9 -0
- package/src-noconflict/snippets/twig.js +9 -0
- package/src-noconflict/snippets/typescript.js +9 -0
- package/src-noconflict/snippets/vala.js +200 -0
- package/src-noconflict/snippets/vbscript.js +9 -0
- package/src-noconflict/snippets/velocity.js +43 -0
- package/src-noconflict/snippets/verilog.js +9 -0
- package/src-noconflict/snippets/vhdl.js +9 -0
- package/src-noconflict/snippets/visualforce.js +9 -0
- package/src-noconflict/snippets/wollok.js +98 -0
- package/src-noconflict/snippets/xml.js +9 -0
- package/src-noconflict/snippets/xquery.js +75 -0
- package/src-noconflict/snippets/yaml.js +9 -0
- package/src-noconflict/snippets/zeek.js +9 -0
- package/src-noconflict/theme-ambiance.js +185 -0
- package/src-noconflict/theme-chaos.js +163 -0
- package/src-noconflict/theme-chrome.js +135 -0
- package/src-noconflict/theme-clouds.js +102 -0
- package/src-noconflict/theme-clouds_midnight.js +103 -0
- package/src-noconflict/theme-cobalt.js +120 -0
- package/src-noconflict/theme-crimson_editor.js +125 -0
- package/src-noconflict/theme-dawn.js +115 -0
- package/src-noconflict/theme-dracula.js +135 -0
- package/src-noconflict/theme-dreamweaver.js +148 -0
- package/src-noconflict/theme-eclipse.js +105 -0
- package/src-noconflict/theme-github.js +110 -0
- package/src-noconflict/theme-gob.js +119 -0
- package/src-noconflict/theme-gruvbox.js +89 -0
- package/src-noconflict/theme-idle_fingers.js +103 -0
- package/src-noconflict/theme-iplastic.js +128 -0
- package/src-noconflict/theme-katzenmilch.js +128 -0
- package/src-noconflict/theme-kr_theme.js +111 -0
- package/src-noconflict/theme-kuroir.js +68 -0
- package/src-noconflict/theme-merbivore.js +102 -0
- package/src-noconflict/theme-merbivore_soft.js +103 -0
- package/src-noconflict/theme-mono_industrial.js +114 -0
- package/src-noconflict/theme-monokai.js +112 -0
- package/src-noconflict/theme-pastel_on_dark.js +115 -0
- package/src-noconflict/theme-solarized_dark.js +95 -0
- package/src-noconflict/theme-solarized_light.js +98 -0
- package/src-noconflict/theme-sqlserver.js +145 -0
- package/src-noconflict/theme-terminal.js +121 -0
- package/src-noconflict/theme-textmate.js +137 -0
- package/src-noconflict/theme-tomorrow.js +115 -0
- package/src-noconflict/theme-tomorrow_night.js +115 -0
- package/src-noconflict/theme-tomorrow_night_blue.js +113 -0
- package/src-noconflict/theme-tomorrow_night_bright.js +128 -0
- package/src-noconflict/theme-tomorrow_night_eighties.js +115 -0
- package/src-noconflict/theme-twilight.js +116 -0
- package/src-noconflict/theme-vibrant_ink.js +101 -0
- package/src-noconflict/theme-xcode.js +95 -0
- package/src-noconflict/worker-coffee.js +1470 -0
- package/src-noconflict/worker-css.js +9000 -0
- package/src-noconflict/worker-html.js +10922 -0
- package/src-noconflict/worker-javascript.js +15001 -0
- package/src-noconflict/worker-json.js +1715 -0
- package/src-noconflict/worker-lua.js +3608 -0
- package/src-noconflict/worker-php.js +3687 -0
- package/src-noconflict/worker-xml.js +3208 -0
- package/src-noconflict/worker-xquery.js +57668 -0
|
@@ -0,0 +1,1010 @@
|
|
|
1
|
+
ace.define("ace/mode/erlang_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
|
|
2
|
+
"use strict";
|
|
3
|
+
|
|
4
|
+
var oop = require("../lib/oop");
|
|
5
|
+
var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
|
|
6
|
+
|
|
7
|
+
var ErlangHighlightRules = function() {
|
|
8
|
+
|
|
9
|
+
this.$rules = { start:
|
|
10
|
+
[ { include: '#module-directive' },
|
|
11
|
+
{ include: '#import-export-directive' },
|
|
12
|
+
{ include: '#behaviour-directive' },
|
|
13
|
+
{ include: '#record-directive' },
|
|
14
|
+
{ include: '#define-directive' },
|
|
15
|
+
{ include: '#macro-directive' },
|
|
16
|
+
{ include: '#directive' },
|
|
17
|
+
{ include: '#function' },
|
|
18
|
+
{ include: '#everything-else' } ],
|
|
19
|
+
'#atom':
|
|
20
|
+
[ { token: 'punctuation.definition.symbol.begin.erlang',
|
|
21
|
+
regex: '\'',
|
|
22
|
+
push:
|
|
23
|
+
[ { token: 'punctuation.definition.symbol.end.erlang',
|
|
24
|
+
regex: '\'',
|
|
25
|
+
next: 'pop' },
|
|
26
|
+
{ token:
|
|
27
|
+
[ 'punctuation.definition.escape.erlang',
|
|
28
|
+
'constant.other.symbol.escape.erlang',
|
|
29
|
+
'punctuation.definition.escape.erlang',
|
|
30
|
+
'constant.other.symbol.escape.erlang',
|
|
31
|
+
'constant.other.symbol.escape.erlang' ],
|
|
32
|
+
regex: '(\\\\)(?:([bdefnrstv\\\\\'"])|(\\^)([@-_])|([0-7]{1,3}))' },
|
|
33
|
+
{ token: 'invalid.illegal.atom.erlang', regex: '\\\\\\^?.?' },
|
|
34
|
+
{ defaultToken: 'constant.other.symbol.quoted.single.erlang' } ] },
|
|
35
|
+
{ token: 'constant.other.symbol.unquoted.erlang',
|
|
36
|
+
regex: '[a-z][a-zA-Z\\d@_]*' } ],
|
|
37
|
+
'#behaviour-directive':
|
|
38
|
+
[ { token:
|
|
39
|
+
[ 'meta.directive.behaviour.erlang',
|
|
40
|
+
'punctuation.section.directive.begin.erlang',
|
|
41
|
+
'meta.directive.behaviour.erlang',
|
|
42
|
+
'keyword.control.directive.behaviour.erlang',
|
|
43
|
+
'meta.directive.behaviour.erlang',
|
|
44
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
45
|
+
'meta.directive.behaviour.erlang',
|
|
46
|
+
'entity.name.type.class.behaviour.definition.erlang',
|
|
47
|
+
'meta.directive.behaviour.erlang',
|
|
48
|
+
'punctuation.definition.parameters.end.erlang',
|
|
49
|
+
'meta.directive.behaviour.erlang',
|
|
50
|
+
'punctuation.section.directive.end.erlang' ],
|
|
51
|
+
regex: '^(\\s*)(-)(\\s*)(behaviour)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\))(\\s*)(\\.)' } ],
|
|
52
|
+
'#binary':
|
|
53
|
+
[ { token: 'punctuation.definition.binary.begin.erlang',
|
|
54
|
+
regex: '<<',
|
|
55
|
+
push:
|
|
56
|
+
[ { token: 'punctuation.definition.binary.end.erlang',
|
|
57
|
+
regex: '>>',
|
|
58
|
+
next: 'pop' },
|
|
59
|
+
{ token:
|
|
60
|
+
[ 'punctuation.separator.binary.erlang',
|
|
61
|
+
'punctuation.separator.value-size.erlang' ],
|
|
62
|
+
regex: '(,)|(:)' },
|
|
63
|
+
{ include: '#internal-type-specifiers' },
|
|
64
|
+
{ include: '#everything-else' },
|
|
65
|
+
{ defaultToken: 'meta.structure.binary.erlang' } ] } ],
|
|
66
|
+
'#character':
|
|
67
|
+
[ { token:
|
|
68
|
+
[ 'punctuation.definition.character.erlang',
|
|
69
|
+
'punctuation.definition.escape.erlang',
|
|
70
|
+
'constant.character.escape.erlang',
|
|
71
|
+
'punctuation.definition.escape.erlang',
|
|
72
|
+
'constant.character.escape.erlang',
|
|
73
|
+
'constant.character.escape.erlang' ],
|
|
74
|
+
regex: '(\\$)(\\\\)(?:([bdefnrstv\\\\\'"])|(\\^)([@-_])|([0-7]{1,3}))' },
|
|
75
|
+
{ token: 'invalid.illegal.character.erlang',
|
|
76
|
+
regex: '\\$\\\\\\^?.?' },
|
|
77
|
+
{ token:
|
|
78
|
+
[ 'punctuation.definition.character.erlang',
|
|
79
|
+
'constant.character.erlang' ],
|
|
80
|
+
regex: '(\\$)(\\S)' },
|
|
81
|
+
{ token: 'invalid.illegal.character.erlang', regex: '\\$.?' } ],
|
|
82
|
+
'#comment':
|
|
83
|
+
[ { token: 'punctuation.definition.comment.erlang',
|
|
84
|
+
regex: '%.*$',
|
|
85
|
+
push_:
|
|
86
|
+
[ { token: 'comment.line.percentage.erlang',
|
|
87
|
+
regex: '$',
|
|
88
|
+
next: 'pop' },
|
|
89
|
+
{ defaultToken: 'comment.line.percentage.erlang' } ] } ],
|
|
90
|
+
'#define-directive':
|
|
91
|
+
[ { token:
|
|
92
|
+
[ 'meta.directive.define.erlang',
|
|
93
|
+
'punctuation.section.directive.begin.erlang',
|
|
94
|
+
'meta.directive.define.erlang',
|
|
95
|
+
'keyword.control.directive.define.erlang',
|
|
96
|
+
'meta.directive.define.erlang',
|
|
97
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
98
|
+
'meta.directive.define.erlang',
|
|
99
|
+
'entity.name.function.macro.definition.erlang',
|
|
100
|
+
'meta.directive.define.erlang',
|
|
101
|
+
'punctuation.separator.parameters.erlang' ],
|
|
102
|
+
regex: '^(\\s*)(-)(\\s*)(define)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(,)',
|
|
103
|
+
push:
|
|
104
|
+
[ { token:
|
|
105
|
+
[ 'punctuation.definition.parameters.end.erlang',
|
|
106
|
+
'meta.directive.define.erlang',
|
|
107
|
+
'punctuation.section.directive.end.erlang' ],
|
|
108
|
+
regex: '(\\))(\\s*)(\\.)',
|
|
109
|
+
next: 'pop' },
|
|
110
|
+
{ include: '#everything-else' },
|
|
111
|
+
{ defaultToken: 'meta.directive.define.erlang' } ] },
|
|
112
|
+
{ token: 'meta.directive.define.erlang',
|
|
113
|
+
regex: '(?=^\\s*-\\s*define\\s*\\(\\s*[a-zA-Z\\d@_]+\\s*\\()',
|
|
114
|
+
push:
|
|
115
|
+
[ { token:
|
|
116
|
+
[ 'punctuation.definition.parameters.end.erlang',
|
|
117
|
+
'meta.directive.define.erlang',
|
|
118
|
+
'punctuation.section.directive.end.erlang' ],
|
|
119
|
+
regex: '(\\))(\\s*)(\\.)',
|
|
120
|
+
next: 'pop' },
|
|
121
|
+
{ token:
|
|
122
|
+
[ 'text',
|
|
123
|
+
'punctuation.section.directive.begin.erlang',
|
|
124
|
+
'text',
|
|
125
|
+
'keyword.control.directive.define.erlang',
|
|
126
|
+
'text',
|
|
127
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
128
|
+
'text',
|
|
129
|
+
'entity.name.function.macro.definition.erlang',
|
|
130
|
+
'text',
|
|
131
|
+
'punctuation.definition.parameters.begin.erlang' ],
|
|
132
|
+
regex: '^(\\s*)(-)(\\s*)(define)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\()',
|
|
133
|
+
push:
|
|
134
|
+
[ { token:
|
|
135
|
+
[ 'punctuation.definition.parameters.end.erlang',
|
|
136
|
+
'text',
|
|
137
|
+
'punctuation.separator.parameters.erlang' ],
|
|
138
|
+
regex: '(\\))(\\s*)(,)',
|
|
139
|
+
next: 'pop' },
|
|
140
|
+
{ token: 'punctuation.separator.parameters.erlang', regex: ',' },
|
|
141
|
+
{ include: '#everything-else' } ] },
|
|
142
|
+
{ token: 'punctuation.separator.define.erlang',
|
|
143
|
+
regex: '\\|\\||\\||:|;|,|\\.|->' },
|
|
144
|
+
{ include: '#everything-else' },
|
|
145
|
+
{ defaultToken: 'meta.directive.define.erlang' } ] } ],
|
|
146
|
+
'#directive':
|
|
147
|
+
[ { token:
|
|
148
|
+
[ 'meta.directive.erlang',
|
|
149
|
+
'punctuation.section.directive.begin.erlang',
|
|
150
|
+
'meta.directive.erlang',
|
|
151
|
+
'keyword.control.directive.erlang',
|
|
152
|
+
'meta.directive.erlang',
|
|
153
|
+
'punctuation.definition.parameters.begin.erlang' ],
|
|
154
|
+
regex: '^(\\s*)(-)(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\(?)',
|
|
155
|
+
push:
|
|
156
|
+
[ { token:
|
|
157
|
+
[ 'punctuation.definition.parameters.end.erlang',
|
|
158
|
+
'meta.directive.erlang',
|
|
159
|
+
'punctuation.section.directive.end.erlang' ],
|
|
160
|
+
regex: '(\\)?)(\\s*)(\\.)',
|
|
161
|
+
next: 'pop' },
|
|
162
|
+
{ include: '#everything-else' },
|
|
163
|
+
{ defaultToken: 'meta.directive.erlang' } ] },
|
|
164
|
+
{ token:
|
|
165
|
+
[ 'meta.directive.erlang',
|
|
166
|
+
'punctuation.section.directive.begin.erlang',
|
|
167
|
+
'meta.directive.erlang',
|
|
168
|
+
'keyword.control.directive.erlang',
|
|
169
|
+
'meta.directive.erlang',
|
|
170
|
+
'punctuation.section.directive.end.erlang' ],
|
|
171
|
+
regex: '^(\\s*)(-)(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\.)' } ],
|
|
172
|
+
'#everything-else':
|
|
173
|
+
[ { include: '#comment' },
|
|
174
|
+
{ include: '#record-usage' },
|
|
175
|
+
{ include: '#macro-usage' },
|
|
176
|
+
{ include: '#expression' },
|
|
177
|
+
{ include: '#keyword' },
|
|
178
|
+
{ include: '#textual-operator' },
|
|
179
|
+
{ include: '#function-call' },
|
|
180
|
+
{ include: '#tuple' },
|
|
181
|
+
{ include: '#list' },
|
|
182
|
+
{ include: '#binary' },
|
|
183
|
+
{ include: '#parenthesized-expression' },
|
|
184
|
+
{ include: '#character' },
|
|
185
|
+
{ include: '#number' },
|
|
186
|
+
{ include: '#atom' },
|
|
187
|
+
{ include: '#string' },
|
|
188
|
+
{ include: '#symbolic-operator' },
|
|
189
|
+
{ include: '#variable' } ],
|
|
190
|
+
'#expression':
|
|
191
|
+
[ { token: 'keyword.control.if.erlang',
|
|
192
|
+
regex: '\\bif\\b',
|
|
193
|
+
push:
|
|
194
|
+
[ { token: 'keyword.control.end.erlang',
|
|
195
|
+
regex: '\\bend\\b',
|
|
196
|
+
next: 'pop' },
|
|
197
|
+
{ include: '#internal-expression-punctuation' },
|
|
198
|
+
{ include: '#everything-else' },
|
|
199
|
+
{ defaultToken: 'meta.expression.if.erlang' } ] },
|
|
200
|
+
{ token: 'keyword.control.case.erlang',
|
|
201
|
+
regex: '\\bcase\\b',
|
|
202
|
+
push:
|
|
203
|
+
[ { token: 'keyword.control.end.erlang',
|
|
204
|
+
regex: '\\bend\\b',
|
|
205
|
+
next: 'pop' },
|
|
206
|
+
{ include: '#internal-expression-punctuation' },
|
|
207
|
+
{ include: '#everything-else' },
|
|
208
|
+
{ defaultToken: 'meta.expression.case.erlang' } ] },
|
|
209
|
+
{ token: 'keyword.control.receive.erlang',
|
|
210
|
+
regex: '\\breceive\\b',
|
|
211
|
+
push:
|
|
212
|
+
[ { token: 'keyword.control.end.erlang',
|
|
213
|
+
regex: '\\bend\\b',
|
|
214
|
+
next: 'pop' },
|
|
215
|
+
{ include: '#internal-expression-punctuation' },
|
|
216
|
+
{ include: '#everything-else' },
|
|
217
|
+
{ defaultToken: 'meta.expression.receive.erlang' } ] },
|
|
218
|
+
{ token:
|
|
219
|
+
[ 'keyword.control.fun.erlang',
|
|
220
|
+
'text',
|
|
221
|
+
'entity.name.type.class.module.erlang',
|
|
222
|
+
'text',
|
|
223
|
+
'punctuation.separator.module-function.erlang',
|
|
224
|
+
'text',
|
|
225
|
+
'entity.name.function.erlang',
|
|
226
|
+
'text',
|
|
227
|
+
'punctuation.separator.function-arity.erlang' ],
|
|
228
|
+
regex: '\\b(fun)(\\s*)(?:([a-z][a-zA-Z\\d@_]*)(\\s*)(:)(\\s*))?([a-z][a-zA-Z\\d@_]*)(\\s*)(/)' },
|
|
229
|
+
{ token: 'keyword.control.fun.erlang',
|
|
230
|
+
regex: '\\bfun\\b',
|
|
231
|
+
push:
|
|
232
|
+
[ { token: 'keyword.control.end.erlang',
|
|
233
|
+
regex: '\\bend\\b',
|
|
234
|
+
next: 'pop' },
|
|
235
|
+
{ token: 'text',
|
|
236
|
+
regex: '(?=\\()',
|
|
237
|
+
push:
|
|
238
|
+
[ { token: 'punctuation.separator.clauses.erlang',
|
|
239
|
+
regex: ';|(?=\\bend\\b)',
|
|
240
|
+
next: 'pop' },
|
|
241
|
+
{ include: '#internal-function-parts' } ] },
|
|
242
|
+
{ include: '#everything-else' },
|
|
243
|
+
{ defaultToken: 'meta.expression.fun.erlang' } ] },
|
|
244
|
+
{ token: 'keyword.control.try.erlang',
|
|
245
|
+
regex: '\\btry\\b',
|
|
246
|
+
push:
|
|
247
|
+
[ { token: 'keyword.control.end.erlang',
|
|
248
|
+
regex: '\\bend\\b',
|
|
249
|
+
next: 'pop' },
|
|
250
|
+
{ include: '#internal-expression-punctuation' },
|
|
251
|
+
{ include: '#everything-else' },
|
|
252
|
+
{ defaultToken: 'meta.expression.try.erlang' } ] },
|
|
253
|
+
{ token: 'keyword.control.begin.erlang',
|
|
254
|
+
regex: '\\bbegin\\b',
|
|
255
|
+
push:
|
|
256
|
+
[ { token: 'keyword.control.end.erlang',
|
|
257
|
+
regex: '\\bend\\b',
|
|
258
|
+
next: 'pop' },
|
|
259
|
+
{ include: '#internal-expression-punctuation' },
|
|
260
|
+
{ include: '#everything-else' },
|
|
261
|
+
{ defaultToken: 'meta.expression.begin.erlang' } ] },
|
|
262
|
+
{ token: 'keyword.control.query.erlang',
|
|
263
|
+
regex: '\\bquery\\b',
|
|
264
|
+
push:
|
|
265
|
+
[ { token: 'keyword.control.end.erlang',
|
|
266
|
+
regex: '\\bend\\b',
|
|
267
|
+
next: 'pop' },
|
|
268
|
+
{ include: '#everything-else' },
|
|
269
|
+
{ defaultToken: 'meta.expression.query.erlang' } ] } ],
|
|
270
|
+
'#function':
|
|
271
|
+
[ { token:
|
|
272
|
+
[ 'meta.function.erlang',
|
|
273
|
+
'entity.name.function.definition.erlang',
|
|
274
|
+
'meta.function.erlang' ],
|
|
275
|
+
regex: '^(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(?=\\()',
|
|
276
|
+
push:
|
|
277
|
+
[ { token: 'punctuation.terminator.function.erlang',
|
|
278
|
+
regex: '\\.',
|
|
279
|
+
next: 'pop' },
|
|
280
|
+
{ token: [ 'text', 'entity.name.function.erlang', 'text' ],
|
|
281
|
+
regex: '^(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(?=\\()' },
|
|
282
|
+
{ token: 'text',
|
|
283
|
+
regex: '(?=\\()',
|
|
284
|
+
push:
|
|
285
|
+
[ { token: 'punctuation.separator.clauses.erlang',
|
|
286
|
+
regex: ';|(?=\\.)',
|
|
287
|
+
next: 'pop' },
|
|
288
|
+
{ include: '#parenthesized-expression' },
|
|
289
|
+
{ include: '#internal-function-parts' } ] },
|
|
290
|
+
{ include: '#everything-else' },
|
|
291
|
+
{ defaultToken: 'meta.function.erlang' } ] } ],
|
|
292
|
+
'#function-call':
|
|
293
|
+
[ { token: 'meta.function-call.erlang',
|
|
294
|
+
regex: '(?=(?:[a-z][a-zA-Z\\d@_]*|\'[^\']*\')\\s*(?:\\(|:\\s*(?:[a-z][a-zA-Z\\d@_]*|\'[^\']*\')\\s*\\())',
|
|
295
|
+
push:
|
|
296
|
+
[ { token: 'punctuation.definition.parameters.end.erlang',
|
|
297
|
+
regex: '\\)',
|
|
298
|
+
next: 'pop' },
|
|
299
|
+
{ token:
|
|
300
|
+
[ 'entity.name.type.class.module.erlang',
|
|
301
|
+
'text',
|
|
302
|
+
'punctuation.separator.module-function.erlang',
|
|
303
|
+
'text',
|
|
304
|
+
'entity.name.function.guard.erlang',
|
|
305
|
+
'text',
|
|
306
|
+
'punctuation.definition.parameters.begin.erlang' ],
|
|
307
|
+
regex: '(?:(erlang)(\\s*)(:)(\\s*))?(is_atom|is_binary|is_constant|is_float|is_function|is_integer|is_list|is_number|is_pid|is_port|is_reference|is_tuple|is_record|abs|element|hd|length|node|round|self|size|tl|trunc)(\\s*)(\\()',
|
|
308
|
+
push:
|
|
309
|
+
[ { token: 'text', regex: '(?=\\))', next: 'pop' },
|
|
310
|
+
{ token: 'punctuation.separator.parameters.erlang', regex: ',' },
|
|
311
|
+
{ include: '#everything-else' } ] },
|
|
312
|
+
{ token:
|
|
313
|
+
[ 'entity.name.type.class.module.erlang',
|
|
314
|
+
'text',
|
|
315
|
+
'punctuation.separator.module-function.erlang',
|
|
316
|
+
'text',
|
|
317
|
+
'entity.name.function.erlang',
|
|
318
|
+
'text',
|
|
319
|
+
'punctuation.definition.parameters.begin.erlang' ],
|
|
320
|
+
regex: '(?:([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(:)(\\s*))?([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(\\()',
|
|
321
|
+
push:
|
|
322
|
+
[ { token: 'text', regex: '(?=\\))', next: 'pop' },
|
|
323
|
+
{ token: 'punctuation.separator.parameters.erlang', regex: ',' },
|
|
324
|
+
{ include: '#everything-else' } ] },
|
|
325
|
+
{ defaultToken: 'meta.function-call.erlang' } ] } ],
|
|
326
|
+
'#import-export-directive':
|
|
327
|
+
[ { token:
|
|
328
|
+
[ 'meta.directive.import.erlang',
|
|
329
|
+
'punctuation.section.directive.begin.erlang',
|
|
330
|
+
'meta.directive.import.erlang',
|
|
331
|
+
'keyword.control.directive.import.erlang',
|
|
332
|
+
'meta.directive.import.erlang',
|
|
333
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
334
|
+
'meta.directive.import.erlang',
|
|
335
|
+
'entity.name.type.class.module.erlang',
|
|
336
|
+
'meta.directive.import.erlang',
|
|
337
|
+
'punctuation.separator.parameters.erlang' ],
|
|
338
|
+
regex: '^(\\s*)(-)(\\s*)(import)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(,)',
|
|
339
|
+
push:
|
|
340
|
+
[ { token:
|
|
341
|
+
[ 'punctuation.definition.parameters.end.erlang',
|
|
342
|
+
'meta.directive.import.erlang',
|
|
343
|
+
'punctuation.section.directive.end.erlang' ],
|
|
344
|
+
regex: '(\\))(\\s*)(\\.)',
|
|
345
|
+
next: 'pop' },
|
|
346
|
+
{ include: '#internal-function-list' },
|
|
347
|
+
{ defaultToken: 'meta.directive.import.erlang' } ] },
|
|
348
|
+
{ token:
|
|
349
|
+
[ 'meta.directive.export.erlang',
|
|
350
|
+
'punctuation.section.directive.begin.erlang',
|
|
351
|
+
'meta.directive.export.erlang',
|
|
352
|
+
'keyword.control.directive.export.erlang',
|
|
353
|
+
'meta.directive.export.erlang',
|
|
354
|
+
'punctuation.definition.parameters.begin.erlang' ],
|
|
355
|
+
regex: '^(\\s*)(-)(\\s*)(export)(\\s*)(\\()',
|
|
356
|
+
push:
|
|
357
|
+
[ { token:
|
|
358
|
+
[ 'punctuation.definition.parameters.end.erlang',
|
|
359
|
+
'meta.directive.export.erlang',
|
|
360
|
+
'punctuation.section.directive.end.erlang' ],
|
|
361
|
+
regex: '(\\))(\\s*)(\\.)',
|
|
362
|
+
next: 'pop' },
|
|
363
|
+
{ include: '#internal-function-list' },
|
|
364
|
+
{ defaultToken: 'meta.directive.export.erlang' } ] } ],
|
|
365
|
+
'#internal-expression-punctuation':
|
|
366
|
+
[ { token:
|
|
367
|
+
[ 'punctuation.separator.clause-head-body.erlang',
|
|
368
|
+
'punctuation.separator.clauses.erlang',
|
|
369
|
+
'punctuation.separator.expressions.erlang' ],
|
|
370
|
+
regex: '(->)|(;)|(,)' } ],
|
|
371
|
+
'#internal-function-list':
|
|
372
|
+
[ { token: 'punctuation.definition.list.begin.erlang',
|
|
373
|
+
regex: '\\[',
|
|
374
|
+
push:
|
|
375
|
+
[ { token: 'punctuation.definition.list.end.erlang',
|
|
376
|
+
regex: '\\]',
|
|
377
|
+
next: 'pop' },
|
|
378
|
+
{ token:
|
|
379
|
+
[ 'entity.name.function.erlang',
|
|
380
|
+
'text',
|
|
381
|
+
'punctuation.separator.function-arity.erlang' ],
|
|
382
|
+
regex: '([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(/)',
|
|
383
|
+
push:
|
|
384
|
+
[ { token: 'punctuation.separator.list.erlang',
|
|
385
|
+
regex: ',|(?=\\])',
|
|
386
|
+
next: 'pop' },
|
|
387
|
+
{ include: '#everything-else' } ] },
|
|
388
|
+
{ include: '#everything-else' },
|
|
389
|
+
{ defaultToken: 'meta.structure.list.function.erlang' } ] } ],
|
|
390
|
+
'#internal-function-parts':
|
|
391
|
+
[ { token: 'text',
|
|
392
|
+
regex: '(?=\\()',
|
|
393
|
+
push:
|
|
394
|
+
[ { token: 'punctuation.separator.clause-head-body.erlang',
|
|
395
|
+
regex: '->',
|
|
396
|
+
next: 'pop' },
|
|
397
|
+
{ token: 'punctuation.definition.parameters.begin.erlang',
|
|
398
|
+
regex: '\\(',
|
|
399
|
+
push:
|
|
400
|
+
[ { token: 'punctuation.definition.parameters.end.erlang',
|
|
401
|
+
regex: '\\)',
|
|
402
|
+
next: 'pop' },
|
|
403
|
+
{ token: 'punctuation.separator.parameters.erlang', regex: ',' },
|
|
404
|
+
{ include: '#everything-else' } ] },
|
|
405
|
+
{ token: 'punctuation.separator.guards.erlang', regex: ',|;' },
|
|
406
|
+
{ include: '#everything-else' } ] },
|
|
407
|
+
{ token: 'punctuation.separator.expressions.erlang',
|
|
408
|
+
regex: ',' },
|
|
409
|
+
{ include: '#everything-else' } ],
|
|
410
|
+
'#internal-record-body':
|
|
411
|
+
[ { token: 'punctuation.definition.class.record.begin.erlang',
|
|
412
|
+
regex: '\\{',
|
|
413
|
+
push:
|
|
414
|
+
[ { token: 'meta.structure.record.erlang',
|
|
415
|
+
regex: '(?=\\})',
|
|
416
|
+
next: 'pop' },
|
|
417
|
+
{ token:
|
|
418
|
+
[ 'variable.other.field.erlang',
|
|
419
|
+
'variable.language.omitted.field.erlang',
|
|
420
|
+
'text',
|
|
421
|
+
'keyword.operator.assignment.erlang' ],
|
|
422
|
+
regex: '(?:([a-z][a-zA-Z\\d@_]*|\'[^\']*\')|(_))(\\s*)(=|::)',
|
|
423
|
+
push:
|
|
424
|
+
[ { token: 'punctuation.separator.class.record.erlang',
|
|
425
|
+
regex: ',|(?=\\})',
|
|
426
|
+
next: 'pop' },
|
|
427
|
+
{ include: '#everything-else' } ] },
|
|
428
|
+
{ token:
|
|
429
|
+
[ 'variable.other.field.erlang',
|
|
430
|
+
'text',
|
|
431
|
+
'punctuation.separator.class.record.erlang' ],
|
|
432
|
+
regex: '([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)((?:,)?)' },
|
|
433
|
+
{ include: '#everything-else' },
|
|
434
|
+
{ defaultToken: 'meta.structure.record.erlang' } ] } ],
|
|
435
|
+
'#internal-type-specifiers':
|
|
436
|
+
[ { token: 'punctuation.separator.value-type.erlang',
|
|
437
|
+
regex: '/',
|
|
438
|
+
push:
|
|
439
|
+
[ { token: 'text', regex: '(?=,|:|>>)', next: 'pop' },
|
|
440
|
+
{ token:
|
|
441
|
+
[ 'storage.type.erlang',
|
|
442
|
+
'storage.modifier.signedness.erlang',
|
|
443
|
+
'storage.modifier.endianness.erlang',
|
|
444
|
+
'storage.modifier.unit.erlang',
|
|
445
|
+
'punctuation.separator.type-specifiers.erlang' ],
|
|
446
|
+
regex: '(integer|float|binary|bytes|bitstring|bits)|(signed|unsigned)|(big|little|native)|(unit)|(-)' } ] } ],
|
|
447
|
+
'#keyword':
|
|
448
|
+
[ { token: 'keyword.control.erlang',
|
|
449
|
+
regex: '\\b(?:after|begin|case|catch|cond|end|fun|if|let|of|query|try|receive|when)\\b' } ],
|
|
450
|
+
'#list':
|
|
451
|
+
[ { token: 'punctuation.definition.list.begin.erlang',
|
|
452
|
+
regex: '\\[',
|
|
453
|
+
push:
|
|
454
|
+
[ { token: 'punctuation.definition.list.end.erlang',
|
|
455
|
+
regex: '\\]',
|
|
456
|
+
next: 'pop' },
|
|
457
|
+
{ token: 'punctuation.separator.list.erlang',
|
|
458
|
+
regex: '\\||\\|\\||,' },
|
|
459
|
+
{ include: '#everything-else' },
|
|
460
|
+
{ defaultToken: 'meta.structure.list.erlang' } ] } ],
|
|
461
|
+
'#macro-directive':
|
|
462
|
+
[ { token:
|
|
463
|
+
[ 'meta.directive.ifdef.erlang',
|
|
464
|
+
'punctuation.section.directive.begin.erlang',
|
|
465
|
+
'meta.directive.ifdef.erlang',
|
|
466
|
+
'keyword.control.directive.ifdef.erlang',
|
|
467
|
+
'meta.directive.ifdef.erlang',
|
|
468
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
469
|
+
'meta.directive.ifdef.erlang',
|
|
470
|
+
'entity.name.function.macro.erlang',
|
|
471
|
+
'meta.directive.ifdef.erlang',
|
|
472
|
+
'punctuation.definition.parameters.end.erlang',
|
|
473
|
+
'meta.directive.ifdef.erlang',
|
|
474
|
+
'punctuation.section.directive.end.erlang' ],
|
|
475
|
+
regex: '^(\\s*)(-)(\\s*)(ifdef)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\))(\\s*)(\\.)' },
|
|
476
|
+
{ token:
|
|
477
|
+
[ 'meta.directive.ifndef.erlang',
|
|
478
|
+
'punctuation.section.directive.begin.erlang',
|
|
479
|
+
'meta.directive.ifndef.erlang',
|
|
480
|
+
'keyword.control.directive.ifndef.erlang',
|
|
481
|
+
'meta.directive.ifndef.erlang',
|
|
482
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
483
|
+
'meta.directive.ifndef.erlang',
|
|
484
|
+
'entity.name.function.macro.erlang',
|
|
485
|
+
'meta.directive.ifndef.erlang',
|
|
486
|
+
'punctuation.definition.parameters.end.erlang',
|
|
487
|
+
'meta.directive.ifndef.erlang',
|
|
488
|
+
'punctuation.section.directive.end.erlang' ],
|
|
489
|
+
regex: '^(\\s*)(-)(\\s*)(ifndef)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\))(\\s*)(\\.)' },
|
|
490
|
+
{ token:
|
|
491
|
+
[ 'meta.directive.undef.erlang',
|
|
492
|
+
'punctuation.section.directive.begin.erlang',
|
|
493
|
+
'meta.directive.undef.erlang',
|
|
494
|
+
'keyword.control.directive.undef.erlang',
|
|
495
|
+
'meta.directive.undef.erlang',
|
|
496
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
497
|
+
'meta.directive.undef.erlang',
|
|
498
|
+
'entity.name.function.macro.erlang',
|
|
499
|
+
'meta.directive.undef.erlang',
|
|
500
|
+
'punctuation.definition.parameters.end.erlang',
|
|
501
|
+
'meta.directive.undef.erlang',
|
|
502
|
+
'punctuation.section.directive.end.erlang' ],
|
|
503
|
+
regex: '^(\\s*)(-)(\\s*)(undef)(\\s*)(\\()(\\s*)([a-zA-Z\\d@_]+)(\\s*)(\\))(\\s*)(\\.)' } ],
|
|
504
|
+
'#macro-usage':
|
|
505
|
+
[ { token:
|
|
506
|
+
[ 'keyword.operator.macro.erlang',
|
|
507
|
+
'meta.macro-usage.erlang',
|
|
508
|
+
'entity.name.function.macro.erlang' ],
|
|
509
|
+
regex: '(\\?\\??)(\\s*)([a-zA-Z\\d@_]+)' } ],
|
|
510
|
+
'#module-directive':
|
|
511
|
+
[ { token:
|
|
512
|
+
[ 'meta.directive.module.erlang',
|
|
513
|
+
'punctuation.section.directive.begin.erlang',
|
|
514
|
+
'meta.directive.module.erlang',
|
|
515
|
+
'keyword.control.directive.module.erlang',
|
|
516
|
+
'meta.directive.module.erlang',
|
|
517
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
518
|
+
'meta.directive.module.erlang',
|
|
519
|
+
'entity.name.type.class.module.definition.erlang',
|
|
520
|
+
'meta.directive.module.erlang',
|
|
521
|
+
'punctuation.definition.parameters.end.erlang',
|
|
522
|
+
'meta.directive.module.erlang',
|
|
523
|
+
'punctuation.section.directive.end.erlang' ],
|
|
524
|
+
regex: '^(\\s*)(-)(\\s*)(module)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*)(\\s*)(\\))(\\s*)(\\.)' } ],
|
|
525
|
+
'#number':
|
|
526
|
+
[ { token: 'text',
|
|
527
|
+
regex: '(?=\\d)',
|
|
528
|
+
push:
|
|
529
|
+
[ { token: 'text', regex: '(?!\\d)', next: 'pop' },
|
|
530
|
+
{ token:
|
|
531
|
+
[ 'constant.numeric.float.erlang',
|
|
532
|
+
'punctuation.separator.integer-float.erlang',
|
|
533
|
+
'constant.numeric.float.erlang',
|
|
534
|
+
'punctuation.separator.float-exponent.erlang' ],
|
|
535
|
+
regex: '(\\d+)(\\.)(\\d+)((?:[eE][\\+\\-]?\\d+)?)' },
|
|
536
|
+
{ token:
|
|
537
|
+
[ 'constant.numeric.integer.binary.erlang',
|
|
538
|
+
'punctuation.separator.base-integer.erlang',
|
|
539
|
+
'constant.numeric.integer.binary.erlang' ],
|
|
540
|
+
regex: '(2)(#)([0-1]+)' },
|
|
541
|
+
{ token:
|
|
542
|
+
[ 'constant.numeric.integer.base-3.erlang',
|
|
543
|
+
'punctuation.separator.base-integer.erlang',
|
|
544
|
+
'constant.numeric.integer.base-3.erlang' ],
|
|
545
|
+
regex: '(3)(#)([0-2]+)' },
|
|
546
|
+
{ token:
|
|
547
|
+
[ 'constant.numeric.integer.base-4.erlang',
|
|
548
|
+
'punctuation.separator.base-integer.erlang',
|
|
549
|
+
'constant.numeric.integer.base-4.erlang' ],
|
|
550
|
+
regex: '(4)(#)([0-3]+)' },
|
|
551
|
+
{ token:
|
|
552
|
+
[ 'constant.numeric.integer.base-5.erlang',
|
|
553
|
+
'punctuation.separator.base-integer.erlang',
|
|
554
|
+
'constant.numeric.integer.base-5.erlang' ],
|
|
555
|
+
regex: '(5)(#)([0-4]+)' },
|
|
556
|
+
{ token:
|
|
557
|
+
[ 'constant.numeric.integer.base-6.erlang',
|
|
558
|
+
'punctuation.separator.base-integer.erlang',
|
|
559
|
+
'constant.numeric.integer.base-6.erlang' ],
|
|
560
|
+
regex: '(6)(#)([0-5]+)' },
|
|
561
|
+
{ token:
|
|
562
|
+
[ 'constant.numeric.integer.base-7.erlang',
|
|
563
|
+
'punctuation.separator.base-integer.erlang',
|
|
564
|
+
'constant.numeric.integer.base-7.erlang' ],
|
|
565
|
+
regex: '(7)(#)([0-6]+)' },
|
|
566
|
+
{ token:
|
|
567
|
+
[ 'constant.numeric.integer.octal.erlang',
|
|
568
|
+
'punctuation.separator.base-integer.erlang',
|
|
569
|
+
'constant.numeric.integer.octal.erlang' ],
|
|
570
|
+
regex: '(8)(#)([0-7]+)' },
|
|
571
|
+
{ token:
|
|
572
|
+
[ 'constant.numeric.integer.base-9.erlang',
|
|
573
|
+
'punctuation.separator.base-integer.erlang',
|
|
574
|
+
'constant.numeric.integer.base-9.erlang' ],
|
|
575
|
+
regex: '(9)(#)([0-8]+)' },
|
|
576
|
+
{ token:
|
|
577
|
+
[ 'constant.numeric.integer.decimal.erlang',
|
|
578
|
+
'punctuation.separator.base-integer.erlang',
|
|
579
|
+
'constant.numeric.integer.decimal.erlang' ],
|
|
580
|
+
regex: '(10)(#)(\\d+)' },
|
|
581
|
+
{ token:
|
|
582
|
+
[ 'constant.numeric.integer.base-11.erlang',
|
|
583
|
+
'punctuation.separator.base-integer.erlang',
|
|
584
|
+
'constant.numeric.integer.base-11.erlang' ],
|
|
585
|
+
regex: '(11)(#)([\\daA]+)' },
|
|
586
|
+
{ token:
|
|
587
|
+
[ 'constant.numeric.integer.base-12.erlang',
|
|
588
|
+
'punctuation.separator.base-integer.erlang',
|
|
589
|
+
'constant.numeric.integer.base-12.erlang' ],
|
|
590
|
+
regex: '(12)(#)([\\da-bA-B]+)' },
|
|
591
|
+
{ token:
|
|
592
|
+
[ 'constant.numeric.integer.base-13.erlang',
|
|
593
|
+
'punctuation.separator.base-integer.erlang',
|
|
594
|
+
'constant.numeric.integer.base-13.erlang' ],
|
|
595
|
+
regex: '(13)(#)([\\da-cA-C]+)' },
|
|
596
|
+
{ token:
|
|
597
|
+
[ 'constant.numeric.integer.base-14.erlang',
|
|
598
|
+
'punctuation.separator.base-integer.erlang',
|
|
599
|
+
'constant.numeric.integer.base-14.erlang' ],
|
|
600
|
+
regex: '(14)(#)([\\da-dA-D]+)' },
|
|
601
|
+
{ token:
|
|
602
|
+
[ 'constant.numeric.integer.base-15.erlang',
|
|
603
|
+
'punctuation.separator.base-integer.erlang',
|
|
604
|
+
'constant.numeric.integer.base-15.erlang' ],
|
|
605
|
+
regex: '(15)(#)([\\da-eA-E]+)' },
|
|
606
|
+
{ token:
|
|
607
|
+
[ 'constant.numeric.integer.hexadecimal.erlang',
|
|
608
|
+
'punctuation.separator.base-integer.erlang',
|
|
609
|
+
'constant.numeric.integer.hexadecimal.erlang' ],
|
|
610
|
+
regex: '(16)(#)([\\da-fA-F]+)' },
|
|
611
|
+
{ token:
|
|
612
|
+
[ 'constant.numeric.integer.base-17.erlang',
|
|
613
|
+
'punctuation.separator.base-integer.erlang',
|
|
614
|
+
'constant.numeric.integer.base-17.erlang' ],
|
|
615
|
+
regex: '(17)(#)([\\da-gA-G]+)' },
|
|
616
|
+
{ token:
|
|
617
|
+
[ 'constant.numeric.integer.base-18.erlang',
|
|
618
|
+
'punctuation.separator.base-integer.erlang',
|
|
619
|
+
'constant.numeric.integer.base-18.erlang' ],
|
|
620
|
+
regex: '(18)(#)([\\da-hA-H]+)' },
|
|
621
|
+
{ token:
|
|
622
|
+
[ 'constant.numeric.integer.base-19.erlang',
|
|
623
|
+
'punctuation.separator.base-integer.erlang',
|
|
624
|
+
'constant.numeric.integer.base-19.erlang' ],
|
|
625
|
+
regex: '(19)(#)([\\da-iA-I]+)' },
|
|
626
|
+
{ token:
|
|
627
|
+
[ 'constant.numeric.integer.base-20.erlang',
|
|
628
|
+
'punctuation.separator.base-integer.erlang',
|
|
629
|
+
'constant.numeric.integer.base-20.erlang' ],
|
|
630
|
+
regex: '(20)(#)([\\da-jA-J]+)' },
|
|
631
|
+
{ token:
|
|
632
|
+
[ 'constant.numeric.integer.base-21.erlang',
|
|
633
|
+
'punctuation.separator.base-integer.erlang',
|
|
634
|
+
'constant.numeric.integer.base-21.erlang' ],
|
|
635
|
+
regex: '(21)(#)([\\da-kA-K]+)' },
|
|
636
|
+
{ token:
|
|
637
|
+
[ 'constant.numeric.integer.base-22.erlang',
|
|
638
|
+
'punctuation.separator.base-integer.erlang',
|
|
639
|
+
'constant.numeric.integer.base-22.erlang' ],
|
|
640
|
+
regex: '(22)(#)([\\da-lA-L]+)' },
|
|
641
|
+
{ token:
|
|
642
|
+
[ 'constant.numeric.integer.base-23.erlang',
|
|
643
|
+
'punctuation.separator.base-integer.erlang',
|
|
644
|
+
'constant.numeric.integer.base-23.erlang' ],
|
|
645
|
+
regex: '(23)(#)([\\da-mA-M]+)' },
|
|
646
|
+
{ token:
|
|
647
|
+
[ 'constant.numeric.integer.base-24.erlang',
|
|
648
|
+
'punctuation.separator.base-integer.erlang',
|
|
649
|
+
'constant.numeric.integer.base-24.erlang' ],
|
|
650
|
+
regex: '(24)(#)([\\da-nA-N]+)' },
|
|
651
|
+
{ token:
|
|
652
|
+
[ 'constant.numeric.integer.base-25.erlang',
|
|
653
|
+
'punctuation.separator.base-integer.erlang',
|
|
654
|
+
'constant.numeric.integer.base-25.erlang' ],
|
|
655
|
+
regex: '(25)(#)([\\da-oA-O]+)' },
|
|
656
|
+
{ token:
|
|
657
|
+
[ 'constant.numeric.integer.base-26.erlang',
|
|
658
|
+
'punctuation.separator.base-integer.erlang',
|
|
659
|
+
'constant.numeric.integer.base-26.erlang' ],
|
|
660
|
+
regex: '(26)(#)([\\da-pA-P]+)' },
|
|
661
|
+
{ token:
|
|
662
|
+
[ 'constant.numeric.integer.base-27.erlang',
|
|
663
|
+
'punctuation.separator.base-integer.erlang',
|
|
664
|
+
'constant.numeric.integer.base-27.erlang' ],
|
|
665
|
+
regex: '(27)(#)([\\da-qA-Q]+)' },
|
|
666
|
+
{ token:
|
|
667
|
+
[ 'constant.numeric.integer.base-28.erlang',
|
|
668
|
+
'punctuation.separator.base-integer.erlang',
|
|
669
|
+
'constant.numeric.integer.base-28.erlang' ],
|
|
670
|
+
regex: '(28)(#)([\\da-rA-R]+)' },
|
|
671
|
+
{ token:
|
|
672
|
+
[ 'constant.numeric.integer.base-29.erlang',
|
|
673
|
+
'punctuation.separator.base-integer.erlang',
|
|
674
|
+
'constant.numeric.integer.base-29.erlang' ],
|
|
675
|
+
regex: '(29)(#)([\\da-sA-S]+)' },
|
|
676
|
+
{ token:
|
|
677
|
+
[ 'constant.numeric.integer.base-30.erlang',
|
|
678
|
+
'punctuation.separator.base-integer.erlang',
|
|
679
|
+
'constant.numeric.integer.base-30.erlang' ],
|
|
680
|
+
regex: '(30)(#)([\\da-tA-T]+)' },
|
|
681
|
+
{ token:
|
|
682
|
+
[ 'constant.numeric.integer.base-31.erlang',
|
|
683
|
+
'punctuation.separator.base-integer.erlang',
|
|
684
|
+
'constant.numeric.integer.base-31.erlang' ],
|
|
685
|
+
regex: '(31)(#)([\\da-uA-U]+)' },
|
|
686
|
+
{ token:
|
|
687
|
+
[ 'constant.numeric.integer.base-32.erlang',
|
|
688
|
+
'punctuation.separator.base-integer.erlang',
|
|
689
|
+
'constant.numeric.integer.base-32.erlang' ],
|
|
690
|
+
regex: '(32)(#)([\\da-vA-V]+)' },
|
|
691
|
+
{ token:
|
|
692
|
+
[ 'constant.numeric.integer.base-33.erlang',
|
|
693
|
+
'punctuation.separator.base-integer.erlang',
|
|
694
|
+
'constant.numeric.integer.base-33.erlang' ],
|
|
695
|
+
regex: '(33)(#)([\\da-wA-W]+)' },
|
|
696
|
+
{ token:
|
|
697
|
+
[ 'constant.numeric.integer.base-34.erlang',
|
|
698
|
+
'punctuation.separator.base-integer.erlang',
|
|
699
|
+
'constant.numeric.integer.base-34.erlang' ],
|
|
700
|
+
regex: '(34)(#)([\\da-xA-X]+)' },
|
|
701
|
+
{ token:
|
|
702
|
+
[ 'constant.numeric.integer.base-35.erlang',
|
|
703
|
+
'punctuation.separator.base-integer.erlang',
|
|
704
|
+
'constant.numeric.integer.base-35.erlang' ],
|
|
705
|
+
regex: '(35)(#)([\\da-yA-Y]+)' },
|
|
706
|
+
{ token:
|
|
707
|
+
[ 'constant.numeric.integer.base-36.erlang',
|
|
708
|
+
'punctuation.separator.base-integer.erlang',
|
|
709
|
+
'constant.numeric.integer.base-36.erlang' ],
|
|
710
|
+
regex: '(36)(#)([\\da-zA-Z]+)' },
|
|
711
|
+
{ token: 'invalid.illegal.integer.erlang',
|
|
712
|
+
regex: '\\d+#[\\da-zA-Z]+' },
|
|
713
|
+
{ token: 'constant.numeric.integer.decimal.erlang',
|
|
714
|
+
regex: '\\d+' } ] } ],
|
|
715
|
+
'#parenthesized-expression':
|
|
716
|
+
[ { token: 'punctuation.section.expression.begin.erlang',
|
|
717
|
+
regex: '\\(',
|
|
718
|
+
push:
|
|
719
|
+
[ { token: 'punctuation.section.expression.end.erlang',
|
|
720
|
+
regex: '\\)',
|
|
721
|
+
next: 'pop' },
|
|
722
|
+
{ include: '#everything-else' },
|
|
723
|
+
{ defaultToken: 'meta.expression.parenthesized' } ] } ],
|
|
724
|
+
'#record-directive':
|
|
725
|
+
[ { token:
|
|
726
|
+
[ 'meta.directive.record.erlang',
|
|
727
|
+
'punctuation.section.directive.begin.erlang',
|
|
728
|
+
'meta.directive.record.erlang',
|
|
729
|
+
'keyword.control.directive.import.erlang',
|
|
730
|
+
'meta.directive.record.erlang',
|
|
731
|
+
'punctuation.definition.parameters.begin.erlang',
|
|
732
|
+
'meta.directive.record.erlang',
|
|
733
|
+
'entity.name.type.class.record.definition.erlang',
|
|
734
|
+
'meta.directive.record.erlang',
|
|
735
|
+
'punctuation.separator.parameters.erlang' ],
|
|
736
|
+
regex: '^(\\s*)(-)(\\s*)(record)(\\s*)(\\()(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(,)',
|
|
737
|
+
push:
|
|
738
|
+
[ { token:
|
|
739
|
+
[ 'punctuation.definition.class.record.end.erlang',
|
|
740
|
+
'meta.directive.record.erlang',
|
|
741
|
+
'punctuation.definition.parameters.end.erlang',
|
|
742
|
+
'meta.directive.record.erlang',
|
|
743
|
+
'punctuation.section.directive.end.erlang' ],
|
|
744
|
+
regex: '(\\})(\\s*)(\\))(\\s*)(\\.)',
|
|
745
|
+
next: 'pop' },
|
|
746
|
+
{ include: '#internal-record-body' },
|
|
747
|
+
{ defaultToken: 'meta.directive.record.erlang' } ] } ],
|
|
748
|
+
'#record-usage':
|
|
749
|
+
[ { token:
|
|
750
|
+
[ 'keyword.operator.record.erlang',
|
|
751
|
+
'meta.record-usage.erlang',
|
|
752
|
+
'entity.name.type.class.record.erlang',
|
|
753
|
+
'meta.record-usage.erlang',
|
|
754
|
+
'punctuation.separator.record-field.erlang',
|
|
755
|
+
'meta.record-usage.erlang',
|
|
756
|
+
'variable.other.field.erlang' ],
|
|
757
|
+
regex: '(#)(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')(\\s*)(\\.)(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')' },
|
|
758
|
+
{ token:
|
|
759
|
+
[ 'keyword.operator.record.erlang',
|
|
760
|
+
'meta.record-usage.erlang',
|
|
761
|
+
'entity.name.type.class.record.erlang' ],
|
|
762
|
+
regex: '(#)(\\s*)([a-z][a-zA-Z\\d@_]*|\'[^\']*\')',
|
|
763
|
+
push:
|
|
764
|
+
[ { token: 'punctuation.definition.class.record.end.erlang',
|
|
765
|
+
regex: '\\}',
|
|
766
|
+
next: 'pop' },
|
|
767
|
+
{ include: '#internal-record-body' },
|
|
768
|
+
{ defaultToken: 'meta.record-usage.erlang' } ] } ],
|
|
769
|
+
'#string':
|
|
770
|
+
[ { token: 'punctuation.definition.string.begin.erlang',
|
|
771
|
+
regex: '"',
|
|
772
|
+
push:
|
|
773
|
+
[ { token: 'punctuation.definition.string.end.erlang',
|
|
774
|
+
regex: '"',
|
|
775
|
+
next: 'pop' },
|
|
776
|
+
{ token:
|
|
777
|
+
[ 'punctuation.definition.escape.erlang',
|
|
778
|
+
'constant.character.escape.erlang',
|
|
779
|
+
'punctuation.definition.escape.erlang',
|
|
780
|
+
'constant.character.escape.erlang',
|
|
781
|
+
'constant.character.escape.erlang' ],
|
|
782
|
+
regex: '(\\\\)(?:([bdefnrstv\\\\\'"])|(\\^)([@-_])|([0-7]{1,3}))' },
|
|
783
|
+
{ token: 'invalid.illegal.string.erlang', regex: '\\\\\\^?.?' },
|
|
784
|
+
{ token:
|
|
785
|
+
[ 'punctuation.definition.placeholder.erlang',
|
|
786
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
787
|
+
'constant.other.placeholder.erlang',
|
|
788
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
789
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
790
|
+
'constant.other.placeholder.erlang',
|
|
791
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
792
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
793
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
794
|
+
'constant.other.placeholder.erlang',
|
|
795
|
+
'constant.other.placeholder.erlang' ],
|
|
796
|
+
regex: '(~)(?:((?:\\-)?)(\\d+)|(\\*))?(?:(\\.)(?:(\\d+)|(\\*)))?(?:(\\.)(?:(\\*)|(.)))?([~cfegswpWPBX#bx\\+ni])' },
|
|
797
|
+
{ token:
|
|
798
|
+
[ 'punctuation.definition.placeholder.erlang',
|
|
799
|
+
'punctuation.separator.placeholder-parts.erlang',
|
|
800
|
+
'constant.other.placeholder.erlang',
|
|
801
|
+
'constant.other.placeholder.erlang' ],
|
|
802
|
+
regex: '(~)((?:\\*)?)((?:\\d+)?)([~du\\-#fsacl])' },
|
|
803
|
+
{ token: 'invalid.illegal.string.erlang', regex: '~.?' },
|
|
804
|
+
{ defaultToken: 'string.quoted.double.erlang' } ] } ],
|
|
805
|
+
'#symbolic-operator':
|
|
806
|
+
[ { token: 'keyword.operator.symbolic.erlang',
|
|
807
|
+
regex: '\\+\\+|\\+|--|-|\\*|/=|/|=/=|=:=|==|=<|=|<-|<|>=|>|!|::' } ],
|
|
808
|
+
'#textual-operator':
|
|
809
|
+
[ { token: 'keyword.operator.textual.erlang',
|
|
810
|
+
regex: '\\b(?:andalso|band|and|bxor|xor|bor|orelse|or|bnot|not|bsl|bsr|div|rem)\\b' } ],
|
|
811
|
+
'#tuple':
|
|
812
|
+
[ { token: 'punctuation.definition.tuple.begin.erlang',
|
|
813
|
+
regex: '\\{',
|
|
814
|
+
push:
|
|
815
|
+
[ { token: 'punctuation.definition.tuple.end.erlang',
|
|
816
|
+
regex: '\\}',
|
|
817
|
+
next: 'pop' },
|
|
818
|
+
{ token: 'punctuation.separator.tuple.erlang', regex: ',' },
|
|
819
|
+
{ include: '#everything-else' },
|
|
820
|
+
{ defaultToken: 'meta.structure.tuple.erlang' } ] } ],
|
|
821
|
+
'#variable':
|
|
822
|
+
[ { token: [ 'variable.other.erlang', 'variable.language.omitted.erlang' ],
|
|
823
|
+
regex: '(_[a-zA-Z\\d@_]+|[A-Z][a-zA-Z\\d@_]*)|(_)' } ] };
|
|
824
|
+
|
|
825
|
+
this.normalizeRules();
|
|
826
|
+
};
|
|
827
|
+
|
|
828
|
+
ErlangHighlightRules.metaData = { comment: 'The recognition of function definitions and compiler directives (such as module, record and macro definitions) requires that each of the aforementioned constructs must be the first string inside a line (except for whitespace). Also, the function/module/record/macro names must be given unquoted. -- desp',
|
|
829
|
+
fileTypes: [ 'erl', 'hrl' ],
|
|
830
|
+
keyEquivalent: '^~E',
|
|
831
|
+
name: 'Erlang',
|
|
832
|
+
scopeName: 'source.erlang' };
|
|
833
|
+
|
|
834
|
+
|
|
835
|
+
oop.inherits(ErlangHighlightRules, TextHighlightRules);
|
|
836
|
+
|
|
837
|
+
exports.ErlangHighlightRules = ErlangHighlightRules;
|
|
838
|
+
});
|
|
839
|
+
|
|
840
|
+
ace.define("ace/mode/folding/cstyle",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"], function(require, exports, module) {
|
|
841
|
+
"use strict";
|
|
842
|
+
|
|
843
|
+
var oop = require("../../lib/oop");
|
|
844
|
+
var Range = require("../../range").Range;
|
|
845
|
+
var BaseFoldMode = require("./fold_mode").FoldMode;
|
|
846
|
+
|
|
847
|
+
var FoldMode = exports.FoldMode = function(commentRegex) {
|
|
848
|
+
if (commentRegex) {
|
|
849
|
+
this.foldingStartMarker = new RegExp(
|
|
850
|
+
this.foldingStartMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.start)
|
|
851
|
+
);
|
|
852
|
+
this.foldingStopMarker = new RegExp(
|
|
853
|
+
this.foldingStopMarker.source.replace(/\|[^|]*?$/, "|" + commentRegex.end)
|
|
854
|
+
);
|
|
855
|
+
}
|
|
856
|
+
};
|
|
857
|
+
oop.inherits(FoldMode, BaseFoldMode);
|
|
858
|
+
|
|
859
|
+
(function() {
|
|
860
|
+
|
|
861
|
+
this.foldingStartMarker = /([\{\[\(])[^\}\]\)]*$|^\s*(\/\*)/;
|
|
862
|
+
this.foldingStopMarker = /^[^\[\{\(]*([\}\]\)])|^[\s\*]*(\*\/)/;
|
|
863
|
+
this.singleLineBlockCommentRe= /^\s*(\/\*).*\*\/\s*$/;
|
|
864
|
+
this.tripleStarBlockCommentRe = /^\s*(\/\*\*\*).*\*\/\s*$/;
|
|
865
|
+
this.startRegionRe = /^\s*(\/\*|\/\/)#?region\b/;
|
|
866
|
+
this._getFoldWidgetBase = this.getFoldWidget;
|
|
867
|
+
this.getFoldWidget = function(session, foldStyle, row) {
|
|
868
|
+
var line = session.getLine(row);
|
|
869
|
+
|
|
870
|
+
if (this.singleLineBlockCommentRe.test(line)) {
|
|
871
|
+
if (!this.startRegionRe.test(line) && !this.tripleStarBlockCommentRe.test(line))
|
|
872
|
+
return "";
|
|
873
|
+
}
|
|
874
|
+
|
|
875
|
+
var fw = this._getFoldWidgetBase(session, foldStyle, row);
|
|
876
|
+
|
|
877
|
+
if (!fw && this.startRegionRe.test(line))
|
|
878
|
+
return "start"; // lineCommentRegionStart
|
|
879
|
+
|
|
880
|
+
return fw;
|
|
881
|
+
};
|
|
882
|
+
|
|
883
|
+
this.getFoldWidgetRange = function(session, foldStyle, row, forceMultiline) {
|
|
884
|
+
var line = session.getLine(row);
|
|
885
|
+
|
|
886
|
+
if (this.startRegionRe.test(line))
|
|
887
|
+
return this.getCommentRegionBlock(session, line, row);
|
|
888
|
+
|
|
889
|
+
var match = line.match(this.foldingStartMarker);
|
|
890
|
+
if (match) {
|
|
891
|
+
var i = match.index;
|
|
892
|
+
|
|
893
|
+
if (match[1])
|
|
894
|
+
return this.openingBracketBlock(session, match[1], row, i);
|
|
895
|
+
|
|
896
|
+
var range = session.getCommentFoldRange(row, i + match[0].length, 1);
|
|
897
|
+
|
|
898
|
+
if (range && !range.isMultiLine()) {
|
|
899
|
+
if (forceMultiline) {
|
|
900
|
+
range = this.getSectionRange(session, row);
|
|
901
|
+
} else if (foldStyle != "all")
|
|
902
|
+
range = null;
|
|
903
|
+
}
|
|
904
|
+
|
|
905
|
+
return range;
|
|
906
|
+
}
|
|
907
|
+
|
|
908
|
+
if (foldStyle === "markbegin")
|
|
909
|
+
return;
|
|
910
|
+
|
|
911
|
+
var match = line.match(this.foldingStopMarker);
|
|
912
|
+
if (match) {
|
|
913
|
+
var i = match.index + match[0].length;
|
|
914
|
+
|
|
915
|
+
if (match[1])
|
|
916
|
+
return this.closingBracketBlock(session, match[1], row, i);
|
|
917
|
+
|
|
918
|
+
return session.getCommentFoldRange(row, i, -1);
|
|
919
|
+
}
|
|
920
|
+
};
|
|
921
|
+
|
|
922
|
+
this.getSectionRange = function(session, row) {
|
|
923
|
+
var line = session.getLine(row);
|
|
924
|
+
var startIndent = line.search(/\S/);
|
|
925
|
+
var startRow = row;
|
|
926
|
+
var startColumn = line.length;
|
|
927
|
+
row = row + 1;
|
|
928
|
+
var endRow = row;
|
|
929
|
+
var maxRow = session.getLength();
|
|
930
|
+
while (++row < maxRow) {
|
|
931
|
+
line = session.getLine(row);
|
|
932
|
+
var indent = line.search(/\S/);
|
|
933
|
+
if (indent === -1)
|
|
934
|
+
continue;
|
|
935
|
+
if (startIndent > indent)
|
|
936
|
+
break;
|
|
937
|
+
var subRange = this.getFoldWidgetRange(session, "all", row);
|
|
938
|
+
|
|
939
|
+
if (subRange) {
|
|
940
|
+
if (subRange.start.row <= startRow) {
|
|
941
|
+
break;
|
|
942
|
+
} else if (subRange.isMultiLine()) {
|
|
943
|
+
row = subRange.end.row;
|
|
944
|
+
} else if (startIndent == indent) {
|
|
945
|
+
break;
|
|
946
|
+
}
|
|
947
|
+
}
|
|
948
|
+
endRow = row;
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
return new Range(startRow, startColumn, endRow, session.getLine(endRow).length);
|
|
952
|
+
};
|
|
953
|
+
this.getCommentRegionBlock = function(session, line, row) {
|
|
954
|
+
var startColumn = line.search(/\s*$/);
|
|
955
|
+
var maxRow = session.getLength();
|
|
956
|
+
var startRow = row;
|
|
957
|
+
|
|
958
|
+
var re = /^\s*(?:\/\*|\/\/|--)#?(end)?region\b/;
|
|
959
|
+
var depth = 1;
|
|
960
|
+
while (++row < maxRow) {
|
|
961
|
+
line = session.getLine(row);
|
|
962
|
+
var m = re.exec(line);
|
|
963
|
+
if (!m) continue;
|
|
964
|
+
if (m[1]) depth--;
|
|
965
|
+
else depth++;
|
|
966
|
+
|
|
967
|
+
if (!depth) break;
|
|
968
|
+
}
|
|
969
|
+
|
|
970
|
+
var endRow = row;
|
|
971
|
+
if (endRow > startRow) {
|
|
972
|
+
return new Range(startRow, startColumn, endRow, line.length);
|
|
973
|
+
}
|
|
974
|
+
};
|
|
975
|
+
|
|
976
|
+
}).call(FoldMode.prototype);
|
|
977
|
+
|
|
978
|
+
});
|
|
979
|
+
|
|
980
|
+
ace.define("ace/mode/erlang",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/erlang_highlight_rules","ace/mode/folding/cstyle"], function(require, exports, module) {
|
|
981
|
+
"use strict";
|
|
982
|
+
|
|
983
|
+
var oop = require("../lib/oop");
|
|
984
|
+
var TextMode = require("./text").Mode;
|
|
985
|
+
var ErlangHighlightRules = require("./erlang_highlight_rules").ErlangHighlightRules;
|
|
986
|
+
var FoldMode = require("./folding/cstyle").FoldMode;
|
|
987
|
+
|
|
988
|
+
var Mode = function() {
|
|
989
|
+
this.HighlightRules = ErlangHighlightRules;
|
|
990
|
+
this.foldingRules = new FoldMode();
|
|
991
|
+
this.$behaviour = this.$defaultBehaviour;
|
|
992
|
+
};
|
|
993
|
+
oop.inherits(Mode, TextMode);
|
|
994
|
+
|
|
995
|
+
(function() {
|
|
996
|
+
this.lineCommentStart = "%";
|
|
997
|
+
this.blockComment = null;
|
|
998
|
+
this.$id = "ace/mode/erlang";
|
|
999
|
+
this.snippetFileId = "ace/snippets/erlang";
|
|
1000
|
+
}).call(Mode.prototype);
|
|
1001
|
+
|
|
1002
|
+
exports.Mode = Mode;
|
|
1003
|
+
}); (function() {
|
|
1004
|
+
ace.require(["ace/mode/erlang"], function(m) {
|
|
1005
|
+
if (typeof module == "object" && typeof exports == "object" && module) {
|
|
1006
|
+
module.exports = m;
|
|
1007
|
+
}
|
|
1008
|
+
});
|
|
1009
|
+
})();
|
|
1010
|
+
|