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,501 @@
|
|
|
1
|
+
ace.define("ace/mode/elixir_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 ElixirHighlightRules = function() {
|
|
8
|
+
|
|
9
|
+
this.$rules = { start:
|
|
10
|
+
[ { token:
|
|
11
|
+
[ 'meta.module.elixir',
|
|
12
|
+
'keyword.control.module.elixir',
|
|
13
|
+
'meta.module.elixir',
|
|
14
|
+
'entity.name.type.module.elixir' ],
|
|
15
|
+
regex: '^(\\s*)(defmodule)(\\s+)((?:[A-Z]\\w*\\s*\\.\\s*)*[A-Z]\\w*)' },
|
|
16
|
+
{ token: 'comment.documentation.heredoc',
|
|
17
|
+
regex: '@(?:module|type)?doc (?:~[a-z])?"""',
|
|
18
|
+
push:
|
|
19
|
+
[ { token: 'comment.documentation.heredoc',
|
|
20
|
+
regex: '\\s*"""',
|
|
21
|
+
next: 'pop' },
|
|
22
|
+
{ include: '#interpolated_elixir' },
|
|
23
|
+
{ include: '#escaped_char' },
|
|
24
|
+
{ defaultToken: 'comment.documentation.heredoc' } ],
|
|
25
|
+
comment: '@doc with heredocs is treated as documentation' },
|
|
26
|
+
{ token: 'comment.documentation.heredoc',
|
|
27
|
+
regex: '@(?:module|type)?doc ~[A-Z]"""',
|
|
28
|
+
push:
|
|
29
|
+
[ { token: 'comment.documentation.heredoc',
|
|
30
|
+
regex: '\\s*"""',
|
|
31
|
+
next: 'pop' },
|
|
32
|
+
{ defaultToken: 'comment.documentation.heredoc' } ],
|
|
33
|
+
comment: '@doc with heredocs is treated as documentation' },
|
|
34
|
+
{ token: 'comment.documentation.heredoc',
|
|
35
|
+
regex: '@(?:module|type)?doc (?:~[a-z])?\'\'\'',
|
|
36
|
+
push:
|
|
37
|
+
[ { token: 'comment.documentation.heredoc',
|
|
38
|
+
regex: '\\s*\'\'\'',
|
|
39
|
+
next: 'pop' },
|
|
40
|
+
{ include: '#interpolated_elixir' },
|
|
41
|
+
{ include: '#escaped_char' },
|
|
42
|
+
{ defaultToken: 'comment.documentation.heredoc' } ],
|
|
43
|
+
comment: '@doc with heredocs is treated as documentation' },
|
|
44
|
+
{ token: 'comment.documentation.heredoc',
|
|
45
|
+
regex: '@(?:module|type)?doc ~[A-Z]\'\'\'',
|
|
46
|
+
push:
|
|
47
|
+
[ { token: 'comment.documentation.heredoc',
|
|
48
|
+
regex: '\\s*\'\'\'',
|
|
49
|
+
next: 'pop' },
|
|
50
|
+
{ defaultToken: 'comment.documentation.heredoc' } ],
|
|
51
|
+
comment: '@doc with heredocs is treated as documentation' },
|
|
52
|
+
{ token: 'comment.documentation.false',
|
|
53
|
+
regex: '@(?:module|type)?doc false',
|
|
54
|
+
comment: '@doc false is treated as documentation' },
|
|
55
|
+
{ token: 'comment.documentation.string',
|
|
56
|
+
regex: '@(?:module|type)?doc "',
|
|
57
|
+
push:
|
|
58
|
+
[ { token: 'comment.documentation.string',
|
|
59
|
+
regex: '"',
|
|
60
|
+
next: 'pop' },
|
|
61
|
+
{ include: '#interpolated_elixir' },
|
|
62
|
+
{ include: '#escaped_char' },
|
|
63
|
+
{ defaultToken: 'comment.documentation.string' } ],
|
|
64
|
+
comment: '@doc with string is treated as documentation' },
|
|
65
|
+
{ token: 'keyword.control.elixir',
|
|
66
|
+
regex: '\\b(?:do|end|case|bc|lc|for|if|cond|unless|try|receive|fn|defmodule|defp?|defprotocol|defimpl|defrecord|defstruct|defmacrop?|defdelegate|defcallback|defmacrocallback|defexception|defoverridable|exit|after|rescue|catch|else|raise|throw|import|require|alias|use|quote|unquote|super)\\b(?![?!])',
|
|
67
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
68
|
+
originalRegex: '(?<!\\.)\\b(do|end|case|bc|lc|for|if|cond|unless|try|receive|fn|defmodule|defp?|defprotocol|defimpl|defrecord|defstruct|defmacrop?|defdelegate|defcallback|defmacrocallback|defexception|defoverridable|exit|after|rescue|catch|else|raise|throw|import|require|alias|use|quote|unquote|super)\\b(?![?!])' },
|
|
69
|
+
{ token: 'keyword.operator.elixir',
|
|
70
|
+
regex: '\\b(?:and|not|or|when|xor|in|inlist|inbits)\\b',
|
|
71
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
72
|
+
originalRegex: '(?<!\\.)\\b(and|not|or|when|xor|in|inlist|inbits)\\b',
|
|
73
|
+
comment: ' as above, just doesn\'t need a \'end\' and does a logic operation' },
|
|
74
|
+
{ token: 'constant.language.elixir',
|
|
75
|
+
regex: '\\b(?:nil|true|false)\\b(?![?!])' },
|
|
76
|
+
{ token: 'variable.language.elixir',
|
|
77
|
+
regex: '\\b__(?:CALLER|ENV|MODULE|DIR)__\\b(?![?!])' },
|
|
78
|
+
{ token:
|
|
79
|
+
[ 'punctuation.definition.variable.elixir',
|
|
80
|
+
'variable.other.readwrite.module.elixir' ],
|
|
81
|
+
regex: '(@)([a-zA-Z_]\\w*)' },
|
|
82
|
+
{ token:
|
|
83
|
+
[ 'punctuation.definition.variable.elixir',
|
|
84
|
+
'variable.other.anonymous.elixir' ],
|
|
85
|
+
regex: '(&)(\\d*)' },
|
|
86
|
+
{ token: 'variable.other.constant.elixir',
|
|
87
|
+
regex: '\\b[A-Z]\\w*\\b' },
|
|
88
|
+
{ token: 'constant.numeric.elixir',
|
|
89
|
+
regex: '\\b(?:0x[\\da-fA-F](?:_?[\\da-fA-F])*|\\d(?:_?\\d)*(?:\\.(?![^[:space:][:digit:]])(?:_?\\d)*)?(?:[eE][-+]?\\d(?:_?\\d)*)?|0b[01]+|0o[0-7]+)\\b',
|
|
90
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
91
|
+
originalRegex: '\\b(0x\\h(?>_?\\h)*|\\d(?>_?\\d)*(\\.(?![^[:space:][:digit:]])(?>_?\\d)*)?([eE][-+]?\\d(?>_?\\d)*)?|0b[01]+|0o[0-7]+)\\b' },
|
|
92
|
+
{ token: 'punctuation.definition.constant.elixir',
|
|
93
|
+
regex: ':\'',
|
|
94
|
+
push:
|
|
95
|
+
[ { token: 'punctuation.definition.constant.elixir',
|
|
96
|
+
regex: '\'',
|
|
97
|
+
next: 'pop' },
|
|
98
|
+
{ include: '#interpolated_elixir' },
|
|
99
|
+
{ include: '#escaped_char' },
|
|
100
|
+
{ defaultToken: 'constant.other.symbol.single-quoted.elixir' } ] },
|
|
101
|
+
{ token: 'punctuation.definition.constant.elixir',
|
|
102
|
+
regex: ':"',
|
|
103
|
+
push:
|
|
104
|
+
[ { token: 'punctuation.definition.constant.elixir',
|
|
105
|
+
regex: '"',
|
|
106
|
+
next: 'pop' },
|
|
107
|
+
{ include: '#interpolated_elixir' },
|
|
108
|
+
{ include: '#escaped_char' },
|
|
109
|
+
{ defaultToken: 'constant.other.symbol.double-quoted.elixir' } ] },
|
|
110
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
111
|
+
regex: '(?:\'\'\')',
|
|
112
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
113
|
+
originalRegex: '(?>\'\'\')',
|
|
114
|
+
push:
|
|
115
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
116
|
+
regex: '^\\s*\'\'\'',
|
|
117
|
+
next: 'pop' },
|
|
118
|
+
{ include: '#interpolated_elixir' },
|
|
119
|
+
{ include: '#escaped_char' },
|
|
120
|
+
{ defaultToken: 'support.function.variable.quoted.single.heredoc.elixir' } ],
|
|
121
|
+
comment: 'Single-quoted heredocs' },
|
|
122
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
123
|
+
regex: '\'',
|
|
124
|
+
push:
|
|
125
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
126
|
+
regex: '\'',
|
|
127
|
+
next: 'pop' },
|
|
128
|
+
{ include: '#interpolated_elixir' },
|
|
129
|
+
{ include: '#escaped_char' },
|
|
130
|
+
{ defaultToken: 'support.function.variable.quoted.single.elixir' } ],
|
|
131
|
+
comment: 'single quoted string (allows for interpolation)' },
|
|
132
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
133
|
+
regex: '(?:""")',
|
|
134
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
135
|
+
originalRegex: '(?>""")',
|
|
136
|
+
push:
|
|
137
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
138
|
+
regex: '^\\s*"""',
|
|
139
|
+
next: 'pop' },
|
|
140
|
+
{ include: '#interpolated_elixir' },
|
|
141
|
+
{ include: '#escaped_char' },
|
|
142
|
+
{ defaultToken: 'string.quoted.double.heredoc.elixir' } ],
|
|
143
|
+
comment: 'Double-quoted heredocs' },
|
|
144
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
145
|
+
regex: '"',
|
|
146
|
+
push:
|
|
147
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
148
|
+
regex: '"',
|
|
149
|
+
next: 'pop' },
|
|
150
|
+
{ include: '#interpolated_elixir' },
|
|
151
|
+
{ include: '#escaped_char' },
|
|
152
|
+
{ defaultToken: 'string.quoted.double.elixir' } ],
|
|
153
|
+
comment: 'double quoted string (allows for interpolation)' },
|
|
154
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
155
|
+
regex: '~[a-z](?:""")',
|
|
156
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
157
|
+
originalRegex: '~[a-z](?>""")',
|
|
158
|
+
push:
|
|
159
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
160
|
+
regex: '^\\s*"""',
|
|
161
|
+
next: 'pop' },
|
|
162
|
+
{ include: '#interpolated_elixir' },
|
|
163
|
+
{ include: '#escaped_char' },
|
|
164
|
+
{ defaultToken: 'string.quoted.double.heredoc.elixir' } ],
|
|
165
|
+
comment: 'Double-quoted heredocs sigils' },
|
|
166
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
167
|
+
regex: '~[a-z]\\{',
|
|
168
|
+
push:
|
|
169
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
170
|
+
regex: '\\}[a-z]*',
|
|
171
|
+
next: 'pop' },
|
|
172
|
+
{ include: '#interpolated_elixir' },
|
|
173
|
+
{ include: '#escaped_char' },
|
|
174
|
+
{ defaultToken: 'string.interpolated.elixir' } ],
|
|
175
|
+
comment: 'sigil (allow for interpolation)' },
|
|
176
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
177
|
+
regex: '~[a-z]\\[',
|
|
178
|
+
push:
|
|
179
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
180
|
+
regex: '\\][a-z]*',
|
|
181
|
+
next: 'pop' },
|
|
182
|
+
{ include: '#interpolated_elixir' },
|
|
183
|
+
{ include: '#escaped_char' },
|
|
184
|
+
{ defaultToken: 'string.interpolated.elixir' } ],
|
|
185
|
+
comment: 'sigil (allow for interpolation)' },
|
|
186
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
187
|
+
regex: '~[a-z]\\<',
|
|
188
|
+
push:
|
|
189
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
190
|
+
regex: '\\>[a-z]*',
|
|
191
|
+
next: 'pop' },
|
|
192
|
+
{ include: '#interpolated_elixir' },
|
|
193
|
+
{ include: '#escaped_char' },
|
|
194
|
+
{ defaultToken: 'string.interpolated.elixir' } ],
|
|
195
|
+
comment: 'sigil (allow for interpolation)' },
|
|
196
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
197
|
+
regex: '~[a-z]\\(',
|
|
198
|
+
push:
|
|
199
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
200
|
+
regex: '\\)[a-z]*',
|
|
201
|
+
next: 'pop' },
|
|
202
|
+
{ include: '#interpolated_elixir' },
|
|
203
|
+
{ include: '#escaped_char' },
|
|
204
|
+
{ defaultToken: 'string.interpolated.elixir' } ],
|
|
205
|
+
comment: 'sigil (allow for interpolation)' },
|
|
206
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
207
|
+
regex: '~[a-z][^\\w]',
|
|
208
|
+
push:
|
|
209
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
210
|
+
regex: '[^\\w][a-z]*',
|
|
211
|
+
next: 'pop' },
|
|
212
|
+
{ include: '#interpolated_elixir' },
|
|
213
|
+
{ include: '#escaped_char' },
|
|
214
|
+
{ include: '#escaped_char' },
|
|
215
|
+
{ defaultToken: 'string.interpolated.elixir' } ],
|
|
216
|
+
comment: 'sigil (allow for interpolation)' },
|
|
217
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
218
|
+
regex: '~[A-Z](?:""")',
|
|
219
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
220
|
+
originalRegex: '~[A-Z](?>""")',
|
|
221
|
+
push:
|
|
222
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
223
|
+
regex: '^\\s*"""',
|
|
224
|
+
next: 'pop' },
|
|
225
|
+
{ defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
|
|
226
|
+
comment: 'Double-quoted heredocs sigils' },
|
|
227
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
228
|
+
regex: '~[A-Z]\\{',
|
|
229
|
+
push:
|
|
230
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
231
|
+
regex: '\\}[a-z]*',
|
|
232
|
+
next: 'pop' },
|
|
233
|
+
{ defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
|
|
234
|
+
comment: 'sigil (without interpolation)' },
|
|
235
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
236
|
+
regex: '~[A-Z]\\[',
|
|
237
|
+
push:
|
|
238
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
239
|
+
regex: '\\][a-z]*',
|
|
240
|
+
next: 'pop' },
|
|
241
|
+
{ defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
|
|
242
|
+
comment: 'sigil (without interpolation)' },
|
|
243
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
244
|
+
regex: '~[A-Z]\\<',
|
|
245
|
+
push:
|
|
246
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
247
|
+
regex: '\\>[a-z]*',
|
|
248
|
+
next: 'pop' },
|
|
249
|
+
{ defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
|
|
250
|
+
comment: 'sigil (without interpolation)' },
|
|
251
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
252
|
+
regex: '~[A-Z]\\(',
|
|
253
|
+
push:
|
|
254
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
255
|
+
regex: '\\)[a-z]*',
|
|
256
|
+
next: 'pop' },
|
|
257
|
+
{ defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
|
|
258
|
+
comment: 'sigil (without interpolation)' },
|
|
259
|
+
{ token: 'punctuation.definition.string.begin.elixir',
|
|
260
|
+
regex: '~[A-Z][^\\w]',
|
|
261
|
+
push:
|
|
262
|
+
[ { token: 'punctuation.definition.string.end.elixir',
|
|
263
|
+
regex: '[^\\w][a-z]*',
|
|
264
|
+
next: 'pop' },
|
|
265
|
+
{ defaultToken: 'string.quoted.other.literal.upper.elixir' } ],
|
|
266
|
+
comment: 'sigil (without interpolation)' },
|
|
267
|
+
{ token: ['punctuation.definition.constant.elixir', 'constant.other.symbol.elixir'],
|
|
268
|
+
regex: '(:)([a-zA-Z_][\\w@]*(?:[?!]|=(?![>=]))?|\\<\\>|===?|!==?|<<>>|<<<|>>>|~~~|::|<\\-|\\|>|=>|~|~=|=|/|\\\\\\\\|\\*\\*?|\\.\\.?\\.?|>=?|<=?|&&?&?|\\+\\+?|\\-\\-?|\\|\\|?\\|?|\\!|@|\\%?\\{\\}|%|\\[\\]|\\^(?:\\^\\^)?)',
|
|
269
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
270
|
+
originalRegex: '(?<!:)(:)(?>[a-zA-Z_][\\w@]*(?>[?!]|=(?![>=]))?|\\<\\>|===?|!==?|<<>>|<<<|>>>|~~~|::|<\\-|\\|>|=>|~|~=|=|/|\\\\\\\\|\\*\\*?|\\.\\.?\\.?|>=?|<=?|&&?&?|\\+\\+?|\\-\\-?|\\|\\|?\\|?|\\!|@|\\%?\\{\\}|%|\\[\\]|\\^(\\^\\^)?)',
|
|
271
|
+
comment: 'symbols' },
|
|
272
|
+
{ token: 'punctuation.definition.constant.elixir',
|
|
273
|
+
regex: '(?:[a-zA-Z_][\\w@]*(?:[?!])?):(?!:)',
|
|
274
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
275
|
+
originalRegex: '(?>[a-zA-Z_][\\w@]*(?>[?!])?)(:)(?!:)',
|
|
276
|
+
comment: 'symbols' },
|
|
277
|
+
{ token:
|
|
278
|
+
[ 'punctuation.definition.comment.elixir',
|
|
279
|
+
'comment.line.number-sign.elixir' ],
|
|
280
|
+
regex: '(#)(.*)' },
|
|
281
|
+
{ token: 'constant.numeric.elixir',
|
|
282
|
+
regex: '\\?(?:\\\\(?:x[\\da-fA-F]{1,2}(?![\\da-fA-F])\\b|[^xMC])|[^\\s\\\\])',
|
|
283
|
+
TODO: 'FIXME: regexp doesn\'t have js equivalent',
|
|
284
|
+
originalRegex: '(?<!\\w)\\?(\\\\(x\\h{1,2}(?!\\h)\\b|[^xMC])|[^\\s\\\\])',
|
|
285
|
+
comment: '\n\t\t\tmatches questionmark-letters.\n\n\t\t\texamples (1st alternation = hex):\n\t\t\t?\\x1 ?\\x61\n\n\t\t\texamples (2rd alternation = escaped):\n\t\t\t?\\n ?\\b\n\n\t\t\texamples (3rd alternation = normal):\n\t\t\t?a ?A ?0 \n\t\t\t?* ?" ?( \n\t\t\t?. ?#\n\t\t\t\n\t\t\tthe negative lookbehind prevents against matching\n\t\t\tp(42.tainted?)\n\t\t\t' },
|
|
286
|
+
{ token: 'keyword.operator.assignment.augmented.elixir',
|
|
287
|
+
regex: '\\+=|\\-=|\\|\\|=|~=|&&=' },
|
|
288
|
+
{ token: 'keyword.operator.comparison.elixir',
|
|
289
|
+
regex: '===?|!==?|<=?|>=?' },
|
|
290
|
+
{ token: 'keyword.operator.bitwise.elixir',
|
|
291
|
+
regex: '\\|{3}|&{3}|\\^{3}|<{3}|>{3}|~{3}' },
|
|
292
|
+
{ token: 'keyword.operator.logical.elixir',
|
|
293
|
+
regex: '!+|\\bnot\\b|&&|\\band\\b|\\|\\||\\bor\\b|\\bxor\\b',
|
|
294
|
+
originalRegex: '(?<=[ \\t])!+|\\bnot\\b|&&|\\band\\b|\\|\\||\\bor\\b|\\bxor\\b' },
|
|
295
|
+
{ token: 'keyword.operator.arithmetic.elixir',
|
|
296
|
+
regex: '\\*|\\+|\\-|/' },
|
|
297
|
+
{ token: 'keyword.operator.other.elixir',
|
|
298
|
+
regex: '\\||\\+\\+|\\-\\-|\\*\\*|\\\\\\\\|\\<\\-|\\<\\>|\\<\\<|\\>\\>|\\:\\:|\\.\\.|\\|>|~|=>' },
|
|
299
|
+
{ token: 'keyword.operator.assignment.elixir', regex: '=' },
|
|
300
|
+
{ token: 'punctuation.separator.other.elixir', regex: ':' },
|
|
301
|
+
{ token: 'punctuation.separator.statement.elixir',
|
|
302
|
+
regex: '\\;' },
|
|
303
|
+
{ token: 'punctuation.separator.object.elixir', regex: ',' },
|
|
304
|
+
{ token: 'punctuation.separator.method.elixir', regex: '\\.' },
|
|
305
|
+
{ token: 'punctuation.section.scope.elixir', regex: '\\{|\\}' },
|
|
306
|
+
{ token: 'punctuation.section.array.elixir', regex: '\\[|\\]' },
|
|
307
|
+
{ token: 'punctuation.section.function.elixir',
|
|
308
|
+
regex: '\\(|\\)' } ],
|
|
309
|
+
'#escaped_char':
|
|
310
|
+
[ { token: 'constant.character.escape.elixir',
|
|
311
|
+
regex: '\\\\(?:x[\\da-fA-F]{1,2}|.)' } ],
|
|
312
|
+
'#interpolated_elixir':
|
|
313
|
+
[ { token:
|
|
314
|
+
[ 'source.elixir.embedded.source',
|
|
315
|
+
'source.elixir.embedded.source.empty' ],
|
|
316
|
+
regex: '(#\\{)(\\})' },
|
|
317
|
+
{ todo:
|
|
318
|
+
{ token: 'punctuation.section.embedded.elixir',
|
|
319
|
+
regex: '#\\{',
|
|
320
|
+
push:
|
|
321
|
+
[ { token: 'punctuation.section.embedded.elixir',
|
|
322
|
+
regex: '\\}',
|
|
323
|
+
next: 'pop' },
|
|
324
|
+
{ include: '#nest_curly_and_self' },
|
|
325
|
+
{ include: '$self' },
|
|
326
|
+
{ defaultToken: 'source.elixir.embedded.source' } ] } } ],
|
|
327
|
+
'#nest_curly_and_self':
|
|
328
|
+
[ { token: 'punctuation.section.scope.elixir',
|
|
329
|
+
regex: '\\{',
|
|
330
|
+
push:
|
|
331
|
+
[ { token: 'punctuation.section.scope.elixir',
|
|
332
|
+
regex: '\\}',
|
|
333
|
+
next: 'pop' },
|
|
334
|
+
{ include: '#nest_curly_and_self' } ] },
|
|
335
|
+
{ include: '$self' } ],
|
|
336
|
+
'#regex_sub':
|
|
337
|
+
[ { include: '#interpolated_elixir' },
|
|
338
|
+
{ include: '#escaped_char' },
|
|
339
|
+
{ token:
|
|
340
|
+
[ 'punctuation.definition.arbitrary-repitition.elixir',
|
|
341
|
+
'string.regexp.arbitrary-repitition.elixir',
|
|
342
|
+
'string.regexp.arbitrary-repitition.elixir',
|
|
343
|
+
'punctuation.definition.arbitrary-repitition.elixir' ],
|
|
344
|
+
regex: '(\\{)(\\d+)((?:,\\d+)?)(\\})' },
|
|
345
|
+
{ token: 'punctuation.definition.character-class.elixir',
|
|
346
|
+
regex: '\\[(?:\\^?\\])?',
|
|
347
|
+
push:
|
|
348
|
+
[ { token: 'punctuation.definition.character-class.elixir',
|
|
349
|
+
regex: '\\]',
|
|
350
|
+
next: 'pop' },
|
|
351
|
+
{ include: '#escaped_char' },
|
|
352
|
+
{ defaultToken: 'string.regexp.character-class.elixir' } ] },
|
|
353
|
+
{ token: 'punctuation.definition.group.elixir',
|
|
354
|
+
regex: '\\(',
|
|
355
|
+
push:
|
|
356
|
+
[ { token: 'punctuation.definition.group.elixir',
|
|
357
|
+
regex: '\\)',
|
|
358
|
+
next: 'pop' },
|
|
359
|
+
{ include: '#regex_sub' },
|
|
360
|
+
{ defaultToken: 'string.regexp.group.elixir' } ] },
|
|
361
|
+
{ token:
|
|
362
|
+
[ 'punctuation.definition.comment.elixir',
|
|
363
|
+
'comment.line.number-sign.elixir' ],
|
|
364
|
+
regex: '(?:^|\\s)(#)(\\s[[a-zA-Z0-9,. \\t?!-][^\\x00-\\x7F]]*$)',
|
|
365
|
+
originalRegex: '(?<=^|\\s)(#)\\s[[a-zA-Z0-9,. \\t?!-][^\\x{00}-\\x{7F}]]*$',
|
|
366
|
+
comment: 'We are restrictive in what we allow to go after the comment character to avoid false positives, since the availability of comments depend on regexp flags.' } ] };
|
|
367
|
+
|
|
368
|
+
this.normalizeRules();
|
|
369
|
+
};
|
|
370
|
+
|
|
371
|
+
ElixirHighlightRules.metaData = { comment: 'Textmate bundle for Elixir Programming Language.',
|
|
372
|
+
fileTypes: [ 'ex', 'exs' ],
|
|
373
|
+
firstLineMatch: '^#!/.*\\belixir',
|
|
374
|
+
foldingStartMarker: '(after|else|catch|rescue|\\-\\>|\\{|\\[|do)\\s*$',
|
|
375
|
+
foldingStopMarker: '^\\s*((\\}|\\]|after|else|catch|rescue)\\s*$|end\\b)',
|
|
376
|
+
keyEquivalent: '^~E',
|
|
377
|
+
name: 'Elixir',
|
|
378
|
+
scopeName: 'source.elixir' };
|
|
379
|
+
|
|
380
|
+
|
|
381
|
+
oop.inherits(ElixirHighlightRules, TextHighlightRules);
|
|
382
|
+
|
|
383
|
+
exports.ElixirHighlightRules = ElixirHighlightRules;
|
|
384
|
+
});
|
|
385
|
+
|
|
386
|
+
ace.define("ace/mode/folding/coffee",["require","exports","module","ace/lib/oop","ace/mode/folding/fold_mode","ace/range"], function(require, exports, module) {
|
|
387
|
+
"use strict";
|
|
388
|
+
|
|
389
|
+
var oop = require("../../lib/oop");
|
|
390
|
+
var BaseFoldMode = require("./fold_mode").FoldMode;
|
|
391
|
+
var Range = require("../../range").Range;
|
|
392
|
+
|
|
393
|
+
var FoldMode = exports.FoldMode = function() {};
|
|
394
|
+
oop.inherits(FoldMode, BaseFoldMode);
|
|
395
|
+
|
|
396
|
+
(function() {
|
|
397
|
+
|
|
398
|
+
this.getFoldWidgetRange = function(session, foldStyle, row) {
|
|
399
|
+
var range = this.indentationBlock(session, row);
|
|
400
|
+
if (range)
|
|
401
|
+
return range;
|
|
402
|
+
|
|
403
|
+
var re = /\S/;
|
|
404
|
+
var line = session.getLine(row);
|
|
405
|
+
var startLevel = line.search(re);
|
|
406
|
+
if (startLevel == -1 || line[startLevel] != "#")
|
|
407
|
+
return;
|
|
408
|
+
|
|
409
|
+
var startColumn = line.length;
|
|
410
|
+
var maxRow = session.getLength();
|
|
411
|
+
var startRow = row;
|
|
412
|
+
var endRow = row;
|
|
413
|
+
|
|
414
|
+
while (++row < maxRow) {
|
|
415
|
+
line = session.getLine(row);
|
|
416
|
+
var level = line.search(re);
|
|
417
|
+
|
|
418
|
+
if (level == -1)
|
|
419
|
+
continue;
|
|
420
|
+
|
|
421
|
+
if (line[level] != "#")
|
|
422
|
+
break;
|
|
423
|
+
|
|
424
|
+
endRow = row;
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
if (endRow > startRow) {
|
|
428
|
+
var endColumn = session.getLine(endRow).length;
|
|
429
|
+
return new Range(startRow, startColumn, endRow, endColumn);
|
|
430
|
+
}
|
|
431
|
+
};
|
|
432
|
+
this.getFoldWidget = function(session, foldStyle, row) {
|
|
433
|
+
var line = session.getLine(row);
|
|
434
|
+
var indent = line.search(/\S/);
|
|
435
|
+
var next = session.getLine(row + 1);
|
|
436
|
+
var prev = session.getLine(row - 1);
|
|
437
|
+
var prevIndent = prev.search(/\S/);
|
|
438
|
+
var nextIndent = next.search(/\S/);
|
|
439
|
+
|
|
440
|
+
if (indent == -1) {
|
|
441
|
+
session.foldWidgets[row - 1] = prevIndent!= -1 && prevIndent < nextIndent ? "start" : "";
|
|
442
|
+
return "";
|
|
443
|
+
}
|
|
444
|
+
if (prevIndent == -1) {
|
|
445
|
+
if (indent == nextIndent && line[indent] == "#" && next[indent] == "#") {
|
|
446
|
+
session.foldWidgets[row - 1] = "";
|
|
447
|
+
session.foldWidgets[row + 1] = "";
|
|
448
|
+
return "start";
|
|
449
|
+
}
|
|
450
|
+
} else if (prevIndent == indent && line[indent] == "#" && prev[indent] == "#") {
|
|
451
|
+
if (session.getLine(row - 2).search(/\S/) == -1) {
|
|
452
|
+
session.foldWidgets[row - 1] = "start";
|
|
453
|
+
session.foldWidgets[row + 1] = "";
|
|
454
|
+
return "";
|
|
455
|
+
}
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
if (prevIndent!= -1 && prevIndent < indent)
|
|
459
|
+
session.foldWidgets[row - 1] = "start";
|
|
460
|
+
else
|
|
461
|
+
session.foldWidgets[row - 1] = "";
|
|
462
|
+
|
|
463
|
+
if (indent < nextIndent)
|
|
464
|
+
return "start";
|
|
465
|
+
else
|
|
466
|
+
return "";
|
|
467
|
+
};
|
|
468
|
+
|
|
469
|
+
}).call(FoldMode.prototype);
|
|
470
|
+
|
|
471
|
+
});
|
|
472
|
+
|
|
473
|
+
ace.define("ace/mode/elixir",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/elixir_highlight_rules","ace/mode/folding/coffee"], function(require, exports, module) {
|
|
474
|
+
"use strict";
|
|
475
|
+
|
|
476
|
+
var oop = require("../lib/oop");
|
|
477
|
+
var TextMode = require("./text").Mode;
|
|
478
|
+
var ElixirHighlightRules = require("./elixir_highlight_rules").ElixirHighlightRules;
|
|
479
|
+
var FoldMode = require("./folding/coffee").FoldMode;
|
|
480
|
+
|
|
481
|
+
var Mode = function() {
|
|
482
|
+
this.HighlightRules = ElixirHighlightRules;
|
|
483
|
+
this.foldingRules = new FoldMode();
|
|
484
|
+
this.$behaviour = this.$defaultBehaviour;
|
|
485
|
+
};
|
|
486
|
+
oop.inherits(Mode, TextMode);
|
|
487
|
+
|
|
488
|
+
(function() {
|
|
489
|
+
this.lineCommentStart = "#";
|
|
490
|
+
this.$id = "ace/mode/elixir";
|
|
491
|
+
}).call(Mode.prototype);
|
|
492
|
+
|
|
493
|
+
exports.Mode = Mode;
|
|
494
|
+
}); (function() {
|
|
495
|
+
ace.require(["ace/mode/elixir"], function(m) {
|
|
496
|
+
if (typeof module == "object" && typeof exports == "object" && module) {
|
|
497
|
+
module.exports = m;
|
|
498
|
+
}
|
|
499
|
+
});
|
|
500
|
+
})();
|
|
501
|
+
|