pygments.rb 2.3.1 → 2.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +1 -1
- data/.rubocop.yml +7 -0
- data/CHANGELOG.adoc +4 -0
- data/README.adoc +1 -1
- data/bench.rb +1 -1
- data/lib/pygments/popen.rb +3 -7
- data/lib/pygments/version.rb +1 -1
- data/pygments.rb.gemspec +2 -2
- data/test/test_pygments.rb +0 -19
- data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/AUTHORS +21 -1
- data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/LICENSE +1 -1
- data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/METADATA +19 -11
- data/vendor/pygments-main/Pygments-2.15.1.dist-info/RECORD +614 -0
- data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/WHEEL +1 -1
- data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/entry_points.txt +0 -1
- data/vendor/pygments-main/bin/pygmentize +1 -1
- data/vendor/pygments-main/pygments/__init__.py +20 -22
- data/vendor/pygments-main/pygments/__main__.py +1 -1
- data/vendor/pygments-main/pygments/cmdline.py +74 -8
- data/vendor/pygments-main/pygments/console.py +1 -1
- data/vendor/pygments-main/pygments/filter.py +1 -1
- data/vendor/pygments-main/pygments/filters/__init__.py +6 -3
- data/vendor/pygments-main/pygments/formatter.py +41 -11
- data/vendor/pygments-main/pygments/formatters/__init__.py +21 -16
- data/vendor/pygments-main/pygments/formatters/_mapping.py +5 -65
- data/vendor/pygments-main/pygments/formatters/bbcode.py +1 -1
- data/vendor/pygments-main/pygments/formatters/groff.py +170 -0
- data/vendor/pygments-main/pygments/formatters/html.py +54 -32
- data/vendor/pygments-main/pygments/formatters/img.py +9 -5
- data/vendor/pygments-main/pygments/formatters/irc.py +6 -33
- data/vendor/pygments-main/pygments/formatters/latex.py +24 -14
- data/vendor/pygments-main/pygments/formatters/other.py +1 -1
- data/vendor/pygments-main/pygments/formatters/pangomarkup.py +1 -1
- data/vendor/pygments-main/pygments/formatters/rtf.py +1 -1
- data/vendor/pygments-main/pygments/formatters/svg.py +1 -1
- data/vendor/pygments-main/pygments/formatters/terminal.py +1 -3
- data/vendor/pygments-main/pygments/formatters/terminal256.py +2 -4
- data/vendor/pygments-main/pygments/lexer.py +101 -32
- data/vendor/pygments-main/pygments/lexers/__init__.py +50 -29
- data/vendor/pygments-main/pygments/lexers/_ada_builtins.py +103 -0
- data/vendor/pygments-main/pygments/lexers/_asy_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_cl_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_cocoa_builtins.py +2 -2
- data/vendor/pygments-main/pygments/lexers/_csound_builtins.py +21 -6
- data/vendor/pygments-main/pygments/lexers/_css_builtins.py +558 -0
- data/vendor/pygments-main/pygments/lexers/_julia_builtins.py +10 -0
- data/vendor/pygments-main/pygments/lexers/_lasso_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_lilypond_builtins.py +4932 -0
- data/vendor/pygments-main/pygments/lexers/_lua_builtins.py +11 -18
- data/vendor/pygments-main/pygments/lexers/_mapping.py +71 -82
- data/vendor/pygments-main/pygments/lexers/_mql_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_mysql_builtins.py +58 -4
- data/vendor/pygments-main/pygments/lexers/_openedge_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_php_builtins.py +408 -1835
- data/vendor/pygments-main/pygments/lexers/_postgres_builtins.py +70 -8
- data/vendor/pygments-main/pygments/lexers/_qlik_builtins.py +666 -0
- data/vendor/pygments-main/pygments/lexers/_scheme_builtins.py +1609 -0
- data/vendor/pygments-main/pygments/lexers/_scilab_builtins.py +3 -3
- data/vendor/pygments-main/pygments/lexers/_sourcemod_builtins.py +9 -18
- data/vendor/pygments-main/pygments/lexers/_stan_builtins.py +185 -94
- data/vendor/pygments-main/pygments/lexers/_stata_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_tsql_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_usd_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_vbscript_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/_vim_builtins.py +1 -1
- data/vendor/pygments-main/pygments/lexers/actionscript.py +15 -14
- data/vendor/pygments-main/pygments/lexers/ada.py +144 -0
- data/vendor/pygments-main/pygments/lexers/agile.py +1 -1
- data/vendor/pygments-main/pygments/lexers/algebra.py +72 -9
- data/vendor/pygments-main/pygments/lexers/ambient.py +8 -7
- data/vendor/pygments-main/pygments/lexers/amdgpu.py +4 -3
- data/vendor/pygments-main/pygments/lexers/ampl.py +10 -8
- data/vendor/pygments-main/pygments/lexers/apdlexer.py +164 -20
- data/vendor/pygments-main/pygments/lexers/apl.py +6 -5
- data/vendor/pygments-main/pygments/lexers/archetype.py +23 -21
- data/vendor/pygments-main/pygments/lexers/arrow.py +10 -9
- data/vendor/pygments-main/pygments/lexers/arturo.py +250 -0
- data/vendor/pygments-main/pygments/lexers/asc.py +9 -5
- data/vendor/pygments-main/pygments/lexers/asm.py +68 -63
- data/vendor/pygments-main/pygments/lexers/automation.py +7 -5
- data/vendor/pygments-main/pygments/lexers/bare.py +20 -21
- data/vendor/pygments-main/pygments/lexers/basic.py +45 -41
- data/vendor/pygments-main/pygments/lexers/bdd.py +58 -0
- data/vendor/pygments-main/pygments/lexers/berry.py +99 -0
- data/vendor/pygments-main/pygments/lexers/bibtex.py +6 -6
- data/vendor/pygments-main/pygments/lexers/boa.py +4 -8
- data/vendor/pygments-main/pygments/lexers/business.py +18 -18
- data/vendor/pygments-main/pygments/lexers/c_cpp.py +80 -40
- data/vendor/pygments-main/pygments/lexers/c_like.py +21 -19
- data/vendor/pygments-main/pygments/lexers/capnproto.py +6 -8
- data/vendor/pygments-main/pygments/lexers/carbon.py +96 -0
- data/vendor/pygments-main/pygments/lexers/cddl.py +16 -33
- data/vendor/pygments-main/pygments/lexers/chapel.py +14 -9
- data/vendor/pygments-main/pygments/lexers/clean.py +3 -2
- data/vendor/pygments-main/pygments/lexers/comal.py +80 -0
- data/vendor/pygments-main/pygments/lexers/compiled.py +3 -2
- data/vendor/pygments-main/pygments/lexers/configs.py +235 -120
- data/vendor/pygments-main/pygments/lexers/console.py +5 -4
- data/vendor/pygments-main/pygments/lexers/cplint.py +44 -0
- data/vendor/pygments-main/pygments/lexers/crystal.py +22 -23
- data/vendor/pygments-main/pygments/lexers/csound.py +19 -17
- data/vendor/pygments-main/pygments/lexers/css.py +67 -159
- data/vendor/pygments-main/pygments/lexers/d.py +15 -12
- data/vendor/pygments-main/pygments/lexers/dalvik.py +14 -11
- data/vendor/pygments-main/pygments/lexers/data.py +119 -49
- data/vendor/pygments-main/pygments/lexers/dax.py +136 -0
- data/vendor/pygments-main/pygments/lexers/devicetree.py +9 -8
- data/vendor/pygments-main/pygments/lexers/diff.py +23 -19
- data/vendor/pygments-main/pygments/lexers/dotnet.py +216 -81
- data/vendor/pygments-main/pygments/lexers/dsls.py +86 -64
- data/vendor/pygments-main/pygments/lexers/dylan.py +16 -15
- data/vendor/pygments-main/pygments/lexers/ecl.py +46 -38
- data/vendor/pygments-main/pygments/lexers/eiffel.py +15 -10
- data/vendor/pygments-main/pygments/lexers/elm.py +12 -8
- data/vendor/pygments-main/pygments/lexers/elpi.py +165 -0
- data/vendor/pygments-main/pygments/lexers/email.py +21 -39
- data/vendor/pygments-main/pygments/lexers/erlang.py +21 -22
- data/vendor/pygments-main/pygments/lexers/esoteric.py +28 -30
- data/vendor/pygments-main/pygments/lexers/ezhil.py +10 -9
- data/vendor/pygments-main/pygments/lexers/factor.py +104 -83
- data/vendor/pygments-main/pygments/lexers/fantom.py +31 -29
- data/vendor/pygments-main/pygments/lexers/felix.py +18 -14
- data/vendor/pygments-main/pygments/lexers/fift.py +67 -0
- data/vendor/pygments-main/pygments/lexers/floscript.py +7 -7
- data/vendor/pygments-main/pygments/lexers/forth.py +8 -6
- data/vendor/pygments-main/pygments/lexers/fortran.py +16 -11
- data/vendor/pygments-main/pygments/lexers/foxpro.py +2 -2
- data/vendor/pygments-main/pygments/lexers/freefem.py +7 -10
- data/vendor/pygments-main/pygments/lexers/func.py +108 -0
- data/vendor/pygments-main/pygments/lexers/functional.py +1 -1
- data/vendor/pygments-main/pygments/lexers/futhark.py +12 -17
- data/vendor/pygments-main/pygments/lexers/gcodelexer.py +1 -2
- data/vendor/pygments-main/pygments/lexers/gdscript.py +76 -233
- data/vendor/pygments-main/pygments/lexers/go.py +12 -14
- data/vendor/pygments-main/pygments/lexers/grammar_notation.py +22 -26
- data/vendor/pygments-main/pygments/lexers/graph.py +36 -15
- data/vendor/pygments-main/pygments/lexers/graphics.py +37 -38
- data/vendor/pygments-main/pygments/lexers/graphviz.py +2 -1
- data/vendor/pygments-main/pygments/lexers/gsql.py +39 -27
- data/vendor/pygments-main/pygments/lexers/haskell.py +73 -71
- data/vendor/pygments-main/pygments/lexers/haxe.py +13 -11
- data/vendor/pygments-main/pygments/lexers/hdl.py +31 -34
- data/vendor/pygments-main/pygments/lexers/hexdump.py +21 -21
- data/vendor/pygments-main/pygments/lexers/html.py +11 -19
- data/vendor/pygments-main/pygments/lexers/idl.py +10 -5
- data/vendor/pygments-main/pygments/lexers/igor.py +3 -2
- data/vendor/pygments-main/pygments/lexers/inferno.py +9 -8
- data/vendor/pygments-main/pygments/lexers/installers.py +39 -33
- data/vendor/pygments-main/pygments/lexers/int_fiction.py +35 -20
- data/vendor/pygments-main/pygments/lexers/iolang.py +9 -9
- data/vendor/pygments-main/pygments/lexers/j.py +20 -13
- data/vendor/pygments-main/pygments/lexers/javascript.py +183 -149
- data/vendor/pygments-main/pygments/lexers/jmespath.py +68 -0
- data/vendor/pygments-main/pygments/lexers/jslt.py +4 -3
- data/vendor/pygments-main/pygments/lexers/jsonnet.py +168 -0
- data/vendor/pygments-main/pygments/lexers/julia.py +44 -32
- data/vendor/pygments-main/pygments/lexers/jvm.py +161 -140
- data/vendor/pygments-main/pygments/lexers/kuin.py +93 -59
- data/vendor/pygments-main/pygments/lexers/lilypond.py +226 -0
- data/vendor/pygments-main/pygments/lexers/lisp.py +244 -107
- data/vendor/pygments-main/pygments/lexers/macaulay2.py +1739 -0
- data/vendor/pygments-main/pygments/lexers/make.py +21 -16
- data/vendor/pygments-main/pygments/lexers/markup.py +752 -11
- data/vendor/pygments-main/pygments/lexers/math.py +1 -1
- data/vendor/pygments-main/pygments/lexers/matlab.py +18 -3
- data/vendor/pygments-main/pygments/lexers/maxima.py +85 -0
- data/vendor/pygments-main/pygments/lexers/meson.py +10 -25
- data/vendor/pygments-main/pygments/lexers/mime.py +2 -2
- data/vendor/pygments-main/pygments/lexers/minecraft.py +394 -0
- data/vendor/pygments-main/pygments/lexers/mips.py +128 -0
- data/vendor/pygments-main/pygments/lexers/ml.py +9 -6
- data/vendor/pygments-main/pygments/lexers/modeling.py +12 -8
- data/vendor/pygments-main/pygments/lexers/modula2.py +3 -2
- data/vendor/pygments-main/pygments/lexers/monte.py +3 -2
- data/vendor/pygments-main/pygments/lexers/mosel.py +1 -1
- data/vendor/pygments-main/pygments/lexers/ncl.py +1 -1
- data/vendor/pygments-main/pygments/lexers/nimrod.py +62 -20
- data/vendor/pygments-main/pygments/lexers/nit.py +3 -2
- data/vendor/pygments-main/pygments/lexers/nix.py +5 -5
- data/vendor/pygments-main/pygments/lexers/oberon.py +2 -2
- data/vendor/pygments-main/pygments/lexers/objective.py +6 -4
- data/vendor/pygments-main/pygments/lexers/ooc.py +3 -2
- data/vendor/pygments-main/pygments/lexers/other.py +1 -1
- data/vendor/pygments-main/pygments/lexers/parasail.py +3 -2
- data/vendor/pygments-main/pygments/lexers/parsers.py +23 -21
- data/vendor/pygments-main/pygments/lexers/pascal.py +196 -198
- data/vendor/pygments-main/pygments/lexers/pawn.py +1 -1
- data/vendor/pygments-main/pygments/lexers/perl.py +17 -15
- data/vendor/pygments-main/pygments/lexers/phix.py +364 -0
- data/vendor/pygments-main/pygments/lexers/php.py +35 -20
- data/vendor/pygments-main/pygments/lexers/pointless.py +3 -2
- data/vendor/pygments-main/pygments/lexers/pony.py +1 -1
- data/vendor/pygments-main/pygments/lexers/praat.py +41 -38
- data/vendor/pygments-main/pygments/lexers/procfile.py +2 -3
- data/vendor/pygments-main/pygments/lexers/prolog.py +7 -8
- data/vendor/pygments-main/pygments/lexers/promql.py +5 -12
- data/vendor/pygments-main/pygments/lexers/python.py +145 -119
- data/vendor/pygments-main/pygments/lexers/q.py +188 -0
- data/vendor/pygments-main/pygments/lexers/qlik.py +117 -0
- data/vendor/pygments-main/pygments/lexers/qvt.py +1 -1
- data/vendor/pygments-main/pygments/lexers/r.py +4 -4
- data/vendor/pygments-main/pygments/lexers/rdf.py +3 -3
- data/vendor/pygments-main/pygments/lexers/rebol.py +1 -12
- data/vendor/pygments-main/pygments/lexers/resource.py +1 -1
- data/vendor/pygments-main/pygments/lexers/ride.py +3 -2
- data/vendor/pygments-main/pygments/lexers/rita.py +43 -0
- data/vendor/pygments-main/pygments/lexers/rnc.py +3 -2
- data/vendor/pygments-main/pygments/lexers/roboconf.py +3 -3
- data/vendor/pygments-main/pygments/lexers/robotframework.py +6 -5
- data/vendor/pygments-main/pygments/lexers/ruby.py +24 -24
- data/vendor/pygments-main/pygments/lexers/rust.py +3 -2
- data/vendor/pygments-main/pygments/lexers/sas.py +2 -2
- data/vendor/pygments-main/pygments/lexers/savi.py +170 -0
- data/vendor/pygments-main/pygments/lexers/scdoc.py +4 -7
- data/vendor/pygments-main/pygments/lexers/scripting.py +24 -21
- data/vendor/pygments-main/pygments/lexers/sgf.py +6 -6
- data/vendor/pygments-main/pygments/lexers/shell.py +29 -21
- data/vendor/pygments-main/pygments/lexers/sieve.py +14 -4
- data/vendor/pygments-main/pygments/lexers/slash.py +1 -1
- data/vendor/pygments-main/pygments/lexers/smalltalk.py +5 -3
- data/vendor/pygments-main/pygments/lexers/smithy.py +5 -6
- data/vendor/pygments-main/pygments/lexers/smv.py +1 -1
- data/vendor/pygments-main/pygments/lexers/snobol.py +1 -1
- data/vendor/pygments-main/pygments/lexers/solidity.py +3 -7
- data/vendor/pygments-main/pygments/lexers/sophia.py +103 -0
- data/vendor/pygments-main/pygments/lexers/special.py +2 -5
- data/vendor/pygments-main/pygments/lexers/spice.py +71 -0
- data/vendor/pygments-main/pygments/lexers/sql.py +212 -17
- data/vendor/pygments-main/pygments/lexers/srcinfo.py +62 -0
- data/vendor/pygments-main/pygments/lexers/stata.py +4 -3
- data/vendor/pygments-main/pygments/lexers/supercollider.py +4 -3
- data/vendor/pygments-main/pygments/lexers/tal.py +74 -0
- data/vendor/pygments-main/pygments/lexers/tcl.py +21 -16
- data/vendor/pygments-main/pygments/lexers/teal.py +9 -8
- data/vendor/pygments-main/pygments/lexers/templates.py +62 -29
- data/vendor/pygments-main/pygments/lexers/teraterm.py +12 -20
- data/vendor/pygments-main/pygments/lexers/testing.py +6 -2
- data/vendor/pygments-main/pygments/lexers/text.py +3 -2
- data/vendor/pygments-main/pygments/lexers/textedit.py +41 -7
- data/vendor/pygments-main/pygments/lexers/textfmts.py +7 -5
- data/vendor/pygments-main/pygments/lexers/theorem.py +42 -36
- data/vendor/pygments-main/pygments/lexers/thingsdb.py +2 -4
- data/vendor/pygments-main/pygments/lexers/tlb.py +57 -0
- data/vendor/pygments-main/pygments/lexers/tnt.py +3 -4
- data/vendor/pygments-main/pygments/lexers/trafficscript.py +2 -4
- data/vendor/pygments-main/pygments/lexers/typoscript.py +2 -3
- data/vendor/pygments-main/pygments/lexers/ul4.py +267 -0
- data/vendor/pygments-main/pygments/lexers/unicon.py +1 -1
- data/vendor/pygments-main/pygments/lexers/urbi.py +4 -4
- data/vendor/pygments-main/pygments/lexers/usd.py +2 -1
- data/vendor/pygments-main/pygments/lexers/varnish.py +5 -5
- data/vendor/pygments-main/pygments/lexers/verification.py +4 -3
- data/vendor/pygments-main/pygments/lexers/web.py +1 -1
- data/vendor/pygments-main/pygments/lexers/webassembly.py +5 -5
- data/vendor/pygments-main/pygments/lexers/webidl.py +2 -1
- data/vendor/pygments-main/pygments/lexers/webmisc.py +90 -71
- data/vendor/pygments-main/pygments/lexers/wgsl.py +407 -0
- data/vendor/pygments-main/pygments/lexers/whiley.py +2 -1
- data/vendor/pygments-main/pygments/lexers/wowtoc.py +120 -0
- data/vendor/pygments-main/pygments/lexers/wren.py +99 -0
- data/vendor/pygments-main/pygments/lexers/x10.py +5 -6
- data/vendor/pygments-main/pygments/lexers/xorg.py +3 -2
- data/vendor/pygments-main/pygments/lexers/yang.py +6 -5
- data/vendor/pygments-main/pygments/lexers/zig.py +3 -2
- data/vendor/pygments-main/pygments/modeline.py +1 -1
- data/vendor/pygments-main/pygments/plugin.py +28 -9
- data/vendor/pygments-main/pygments/regexopt.py +1 -1
- data/vendor/pygments-main/pygments/scanner.py +2 -2
- data/vendor/pygments-main/pygments/sphinxext.py +63 -1
- data/vendor/pygments-main/pygments/style.py +7 -1
- data/vendor/pygments-main/pygments/styles/__init__.py +19 -5
- data/vendor/pygments-main/pygments/styles/abap.py +2 -2
- data/vendor/pygments-main/pygments/styles/algol.py +1 -2
- data/vendor/pygments-main/pygments/styles/algol_nu.py +1 -2
- data/vendor/pygments-main/pygments/styles/arduino.py +2 -3
- data/vendor/pygments-main/pygments/styles/autumn.py +1 -3
- data/vendor/pygments-main/pygments/styles/borland.py +1 -3
- data/vendor/pygments-main/pygments/styles/bw.py +1 -2
- data/vendor/pygments-main/pygments/styles/colorful.py +1 -3
- data/vendor/pygments-main/pygments/styles/default.py +13 -14
- data/vendor/pygments-main/pygments/styles/dracula.py +102 -0
- data/vendor/pygments-main/pygments/styles/emacs.py +1 -2
- data/vendor/pygments-main/pygments/styles/friendly.py +1 -2
- data/vendor/pygments-main/pygments/styles/friendly_grayscale.py +75 -0
- data/vendor/pygments-main/pygments/styles/fruity.py +1 -1
- data/vendor/pygments-main/pygments/styles/gh_dark.py +107 -0
- data/vendor/pygments-main/pygments/styles/gruvbox.py +4 -2
- data/vendor/pygments-main/pygments/styles/igor.py +1 -2
- data/vendor/pygments-main/pygments/styles/inkpot.py +3 -2
- data/vendor/pygments-main/pygments/styles/lilypond.py +56 -0
- data/vendor/pygments-main/pygments/styles/lovelace.py +1 -3
- data/vendor/pygments-main/pygments/styles/manni.py +1 -1
- data/vendor/pygments-main/pygments/styles/material.py +1 -2
- data/vendor/pygments-main/pygments/styles/monokai.py +3 -3
- data/vendor/pygments-main/pygments/styles/murphy.py +1 -3
- data/vendor/pygments-main/pygments/styles/native.py +11 -11
- data/vendor/pygments-main/pygments/styles/nord.py +150 -0
- data/vendor/pygments-main/pygments/styles/onedark.py +59 -0
- data/vendor/pygments-main/pygments/styles/paraiso_dark.py +1 -6
- data/vendor/pygments-main/pygments/styles/paraiso_light.py +1 -6
- data/vendor/pygments-main/pygments/styles/pastie.py +1 -3
- data/vendor/pygments-main/pygments/styles/perldoc.py +1 -2
- data/vendor/pygments-main/pygments/styles/rainbow_dash.py +3 -3
- data/vendor/pygments-main/pygments/styles/rrt.py +3 -2
- data/vendor/pygments-main/pygments/styles/sas.py +2 -4
- data/vendor/pygments-main/pygments/styles/solarized.py +1 -1
- data/vendor/pygments-main/pygments/styles/staroffice.py +26 -0
- data/vendor/pygments-main/pygments/styles/stata_dark.py +4 -6
- data/vendor/pygments-main/pygments/styles/stata_light.py +1 -2
- data/vendor/pygments-main/pygments/styles/tango.py +2 -3
- data/vendor/pygments-main/pygments/styles/trac.py +1 -3
- data/vendor/pygments-main/pygments/styles/vim.py +1 -2
- data/vendor/pygments-main/pygments/styles/vs.py +1 -2
- data/vendor/pygments-main/pygments/styles/xcode.py +1 -3
- data/vendor/pygments-main/pygments/styles/zenburn.py +4 -6
- data/vendor/pygments-main/pygments/token.py +2 -1
- data/vendor/pygments-main/pygments/unistring.py +4 -6
- data/vendor/pygments-main/pygments/util.py +27 -5
- metadata +59 -14
- data/vendor/pygments-main/Pygments-2.10.0.dist-info/RECORD +0 -524
- /data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/INSTALLER +0 -0
- /data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/REQUESTED +0 -0
- /data/vendor/pygments-main/{Pygments-2.10.0.dist-info → Pygments-2.15.1.dist-info}/top_level.txt +0 -0
@@ -4,13 +4,13 @@
|
|
4
4
|
|
5
5
|
Lexers for graph query languages.
|
6
6
|
|
7
|
-
:copyright: Copyright 2006-
|
7
|
+
:copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS.
|
8
8
|
:license: BSD, see LICENSE for details.
|
9
9
|
"""
|
10
10
|
|
11
11
|
import re
|
12
12
|
|
13
|
-
from pygments.lexer import RegexLexer, include, bygroups, using, this
|
13
|
+
from pygments.lexer import RegexLexer, include, bygroups, using, this, words
|
14
14
|
from pygments.token import Keyword, Punctuation, Comment, Operator, Name,\
|
15
15
|
String, Number, Whitespace
|
16
16
|
|
@@ -20,14 +20,14 @@ __all__ = ['CypherLexer']
|
|
20
20
|
|
21
21
|
class CypherLexer(RegexLexer):
|
22
22
|
"""
|
23
|
-
For
|
24
|
-
<https://neo4j.com/docs/developer-manual/3.3/cypher/>`_
|
23
|
+
For Cypher Query Language
|
25
24
|
|
26
25
|
For the Cypher version in Neo4j 3.3
|
27
26
|
|
28
27
|
.. versionadded:: 2.0
|
29
28
|
"""
|
30
29
|
name = 'Cypher'
|
30
|
+
url = 'https://neo4j.com/docs/developer-manual/3.3/cypher/'
|
31
31
|
aliases = ['cypher']
|
32
32
|
filenames = ['*.cyp', '*.cypher']
|
33
33
|
|
@@ -36,15 +36,15 @@ class CypherLexer(RegexLexer):
|
|
36
36
|
tokens = {
|
37
37
|
'root': [
|
38
38
|
include('comment'),
|
39
|
-
include('keywords'),
|
40
39
|
include('clauses'),
|
40
|
+
include('keywords'),
|
41
41
|
include('relations'),
|
42
42
|
include('strings'),
|
43
43
|
include('whitespace'),
|
44
44
|
include('barewords'),
|
45
45
|
],
|
46
46
|
'comment': [
|
47
|
-
(r'
|
47
|
+
(r'^.*//.*$', Comment.Single),
|
48
48
|
],
|
49
49
|
'keywords': [
|
50
50
|
(r'(create|order|match|limit|set|skip|start|return|with|where|'
|
@@ -52,15 +52,36 @@ class CypherLexer(RegexLexer):
|
|
52
52
|
],
|
53
53
|
'clauses': [
|
54
54
|
# based on https://neo4j.com/docs/cypher-refcard/3.3/
|
55
|
-
(r'(
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
55
|
+
(r'(create)(\s+)(index|unique)\b',
|
56
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
57
|
+
(r'(drop)(\s+)(contraint|index)(\s+)(on)\b',
|
58
|
+
bygroups(Keyword, Whitespace, Keyword, Whitespace, Keyword)),
|
59
|
+
(r'(ends)(\s+)(with)\b',
|
60
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
61
|
+
(r'(is)(\s+)(node)(\s+)(key)\b',
|
62
|
+
bygroups(Keyword, Whitespace, Keyword, Whitespace, Keyword)),
|
63
|
+
(r'(is)(\s+)(null|unique)\b',
|
64
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
65
|
+
(r'(load)(\s+)(csv)(\s+)(from)\b',
|
66
|
+
bygroups(Keyword, Whitespace, Keyword, Whitespace, Keyword)),
|
67
|
+
(r'(on)(\s+)(match|create)\b',
|
68
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
69
|
+
(r'(optional)(\s+)(match)\b',
|
70
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
71
|
+
(r'(order)(\s+)(by)\b',
|
72
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
73
|
+
(r'(starts)(\s+)(with)\b',
|
74
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
75
|
+
(r'(union)(\s+)(all)\b',
|
76
|
+
bygroups(Keyword, Whitespace, Keyword)),
|
77
|
+
(r'(using)(\s+)(periodic)(\s+)(commit)\b',
|
78
|
+
bygroups(Keyword, Whitespace, Keyword, Whitespace, Keyword)),
|
79
|
+
(words((
|
80
|
+
'all', 'any', 'as', 'asc', 'ascending', 'assert', 'call', 'case', 'create',
|
81
|
+
'delete', 'desc', 'descending', 'distinct', 'end', 'fieldterminator',
|
82
|
+
'foreach', 'in', 'limit', 'match', 'merge', 'none', 'not', 'null',
|
83
|
+
'remove', 'return', 'set', 'skip', 'single', 'start', 'then', 'union',
|
84
|
+
'unwind', 'yield', 'where', 'when', 'with'), suffix=r'\b'), Keyword),
|
64
85
|
],
|
65
86
|
'relations': [
|
66
87
|
(r'(-\[)(.*?)(\]->)', bygroups(Operator, using(this), Operator)),
|
@@ -4,14 +4,14 @@
|
|
4
4
|
|
5
5
|
Lexers for computer graphics and plotting related languages.
|
6
6
|
|
7
|
-
:copyright: Copyright 2006-
|
7
|
+
:copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS.
|
8
8
|
:license: BSD, see LICENSE for details.
|
9
9
|
"""
|
10
10
|
|
11
11
|
from pygments.lexer import RegexLexer, words, include, bygroups, using, \
|
12
12
|
this, default
|
13
13
|
from pygments.token import Text, Comment, Operator, Keyword, Name, \
|
14
|
-
Number, Punctuation, String
|
14
|
+
Number, Punctuation, String, Whitespace
|
15
15
|
|
16
16
|
__all__ = ['GLShaderLexer', 'PostScriptLexer', 'AsymptoteLexer', 'GnuplotLexer',
|
17
17
|
'PovrayLexer', 'HLSLShaderLexer']
|
@@ -30,8 +30,8 @@ class GLShaderLexer(RegexLexer):
|
|
30
30
|
|
31
31
|
tokens = {
|
32
32
|
'root': [
|
33
|
-
(r'
|
34
|
-
(r'
|
33
|
+
(r'#(?:.*\\\n)*.*$', Comment.Preproc),
|
34
|
+
(r'//.*$', Comment.Single),
|
35
35
|
(r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline),
|
36
36
|
(r'\+|-|~|!=?|\*|/|%|<<|>>|<=?|>=?|==?|&&?|\^|\|\|?',
|
37
37
|
Operator),
|
@@ -143,7 +143,7 @@ class GLShaderLexer(RegexLexer):
|
|
143
143
|
(r'gl_\w*', Name.Builtin),
|
144
144
|
(r'[a-zA-Z_]\w*', Name),
|
145
145
|
(r'\.', Punctuation),
|
146
|
-
(r'\s+',
|
146
|
+
(r'\s+', Whitespace),
|
147
147
|
],
|
148
148
|
}
|
149
149
|
|
@@ -161,8 +161,8 @@ class HLSLShaderLexer(RegexLexer):
|
|
161
161
|
|
162
162
|
tokens = {
|
163
163
|
'root': [
|
164
|
-
(r'
|
165
|
-
(r'
|
164
|
+
(r'#(?:.*\\\n)*.*$', Comment.Preproc),
|
165
|
+
(r'//.*$', Comment.Single),
|
166
166
|
(r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline),
|
167
167
|
(r'\+|-|~|!=?|\*|/|%|<<|>>|<=?|>=?|==?|&&?|\^|\|\|?',
|
168
168
|
Operator),
|
@@ -289,7 +289,7 @@ class HLSLShaderLexer(RegexLexer):
|
|
289
289
|
Name.Decorator), # attributes
|
290
290
|
(r'[a-zA-Z_]\w*', Name),
|
291
291
|
(r'\\$', Comment.Preproc), # backslash at end of line -- usually macro continuation
|
292
|
-
(r'\s+',
|
292
|
+
(r'\s+', Whitespace),
|
293
293
|
],
|
294
294
|
'string': [
|
295
295
|
(r'"', String, '#pop'),
|
@@ -306,13 +306,10 @@ class PostScriptLexer(RegexLexer):
|
|
306
306
|
"""
|
307
307
|
Lexer for PostScript files.
|
308
308
|
|
309
|
-
The PostScript Language Reference published by Adobe at
|
310
|
-
<http://partners.adobe.com/public/developer/en/ps/PLRM.pdf>
|
311
|
-
is the authority for this.
|
312
|
-
|
313
309
|
.. versionadded:: 1.4
|
314
310
|
"""
|
315
311
|
name = 'PostScript'
|
312
|
+
url = 'https://en.wikipedia.org/wiki/PostScript'
|
316
313
|
aliases = ['postscript', 'postscr']
|
317
314
|
filenames = ['*.ps', '*.eps']
|
318
315
|
mimetypes = ['application/postscript']
|
@@ -326,10 +323,10 @@ class PostScriptLexer(RegexLexer):
|
|
326
323
|
tokens = {
|
327
324
|
'root': [
|
328
325
|
# All comment types
|
329
|
-
(r'
|
330
|
-
(r'
|
326
|
+
(r'^%!.+$', Comment.Preproc),
|
327
|
+
(r'%%.*$', Comment.Special),
|
331
328
|
(r'(^%.*\n){2,}', Comment.Multiline),
|
332
|
-
(r'
|
329
|
+
(r'%.*$', Comment.Single),
|
333
330
|
|
334
331
|
# String literals are awkward; enter separate state.
|
335
332
|
(r'\(', String, 'stringliteral'),
|
@@ -383,7 +380,7 @@ class PostScriptLexer(RegexLexer):
|
|
383
380
|
'undefinedfilename', 'undefinedresult'), suffix=delimiter_end),
|
384
381
|
Name.Builtin),
|
385
382
|
|
386
|
-
(r'\s+',
|
383
|
+
(r'\s+', Whitespace),
|
387
384
|
],
|
388
385
|
|
389
386
|
'stringliteral': [
|
@@ -402,11 +399,12 @@ class PostScriptLexer(RegexLexer):
|
|
402
399
|
|
403
400
|
class AsymptoteLexer(RegexLexer):
|
404
401
|
"""
|
405
|
-
For
|
402
|
+
For Asymptote source code.
|
406
403
|
|
407
404
|
.. versionadded:: 1.2
|
408
405
|
"""
|
409
406
|
name = 'Asymptote'
|
407
|
+
url = 'http://asymptote.sf.net/'
|
410
408
|
aliases = ['asymptote', 'asy']
|
411
409
|
filenames = ['*.asy']
|
412
410
|
mimetypes = ['text/x-asymptote']
|
@@ -416,9 +414,9 @@ class AsymptoteLexer(RegexLexer):
|
|
416
414
|
|
417
415
|
tokens = {
|
418
416
|
'whitespace': [
|
419
|
-
(r'\n',
|
420
|
-
(r'\s+',
|
421
|
-
(r'
|
417
|
+
(r'\n', Whitespace),
|
418
|
+
(r'\s+', Whitespace),
|
419
|
+
(r'(\\)(\n)', bygroups(Text, Whitespace)), # line continuation
|
422
420
|
(r'//(\n|(.|\n)*?[^\\]\n)', Comment),
|
423
421
|
(r'/(\\\n)?\*(.|\n)*?\*(\\\n)?/', Comment),
|
424
422
|
],
|
@@ -529,12 +527,13 @@ def _shortened_many(*words):
|
|
529
527
|
|
530
528
|
class GnuplotLexer(RegexLexer):
|
531
529
|
"""
|
532
|
-
For
|
530
|
+
For Gnuplot plotting scripts.
|
533
531
|
|
534
532
|
.. versionadded:: 0.11
|
535
533
|
"""
|
536
534
|
|
537
535
|
name = 'Gnuplot'
|
536
|
+
url = 'http://gnuplot.info/'
|
538
537
|
aliases = ['gnuplot']
|
539
538
|
filenames = ['*.plot', '*.plt']
|
540
539
|
mimetypes = ['text/x-gnuplot']
|
@@ -562,14 +561,15 @@ class GnuplotLexer(RegexLexer):
|
|
562
561
|
'she$ll', 'test$'),
|
563
562
|
Keyword, 'noargs'),
|
564
563
|
(r'([a-zA-Z_]\w*)(\s*)(=)',
|
565
|
-
bygroups(Name.Variable,
|
566
|
-
(r'([a-zA-Z_]\w*)(\s
|
567
|
-
bygroups(Name.Function,
|
564
|
+
bygroups(Name.Variable, Whitespace, Operator), 'genericargs'),
|
565
|
+
(r'([a-zA-Z_]\w*)(\s*)(\()(.*?)(\))(\s*)(=)',
|
566
|
+
bygroups(Name.Function, Whitespace, Punctuation,
|
567
|
+
Text, Punctuation, Whitespace, Operator), 'genericargs'),
|
568
568
|
(r'@[a-zA-Z_]\w*', Name.Constant), # macros
|
569
569
|
(r';', Keyword),
|
570
570
|
],
|
571
571
|
'comment': [
|
572
|
-
(r'[^\\\n]', Comment),
|
572
|
+
(r'[^\\\n]+', Comment),
|
573
573
|
(r'\\\n', Comment),
|
574
574
|
(r'\\', Comment),
|
575
575
|
# don't add the newline to the Comment token
|
@@ -577,13 +577,13 @@ class GnuplotLexer(RegexLexer):
|
|
577
577
|
],
|
578
578
|
'whitespace': [
|
579
579
|
('#', Comment, 'comment'),
|
580
|
-
(r'[ \t\v\f]+',
|
580
|
+
(r'[ \t\v\f]+', Whitespace),
|
581
581
|
],
|
582
582
|
'noargs': [
|
583
583
|
include('whitespace'),
|
584
584
|
# semicolon and newline end the argument list
|
585
585
|
(r';', Punctuation, '#pop'),
|
586
|
-
(r'\n',
|
586
|
+
(r'\n', Whitespace, '#pop'),
|
587
587
|
],
|
588
588
|
'dqstring': [
|
589
589
|
(r'"', String, '#pop'),
|
@@ -591,7 +591,7 @@ class GnuplotLexer(RegexLexer):
|
|
591
591
|
(r'[^\\"\n]+', String), # all other characters
|
592
592
|
(r'\\\n', String), # line continuation
|
593
593
|
(r'\\', String), # stray backslash
|
594
|
-
(r'\n',
|
594
|
+
(r'\n', Whitespace, '#pop'), # newline ends the string too
|
595
595
|
],
|
596
596
|
'sqstring': [
|
597
597
|
(r"''", String), # escaped single quote
|
@@ -599,7 +599,7 @@ class GnuplotLexer(RegexLexer):
|
|
599
599
|
(r"[^\\'\n]+", String), # all other characters
|
600
600
|
(r'\\\n', String), # line continuation
|
601
601
|
(r'\\', String), # normal backslash
|
602
|
-
(r'\n',
|
602
|
+
(r'\n', Whitespace, '#pop'), # newline ends the string too
|
603
603
|
],
|
604
604
|
'genericargs': [
|
605
605
|
include('noargs'),
|
@@ -615,7 +615,7 @@ class GnuplotLexer(RegexLexer):
|
|
615
615
|
bygroups(Name.Function, Text, Punctuation)),
|
616
616
|
(r'[a-zA-Z_]\w*', Name),
|
617
617
|
(r'@[a-zA-Z_]\w*', Name.Constant), # macros
|
618
|
-
(r'
|
618
|
+
(r'(\\)(\n)', bygroups(Text, Whitespace)),
|
619
619
|
],
|
620
620
|
'optionarg': [
|
621
621
|
include('whitespace'),
|
@@ -688,11 +688,12 @@ class GnuplotLexer(RegexLexer):
|
|
688
688
|
|
689
689
|
class PovrayLexer(RegexLexer):
|
690
690
|
"""
|
691
|
-
For
|
691
|
+
For Persistence of Vision Raytracer files.
|
692
692
|
|
693
693
|
.. versionadded:: 0.11
|
694
694
|
"""
|
695
695
|
name = 'POVRay'
|
696
|
+
url = 'http://www.povray.org/'
|
696
697
|
aliases = ['pov']
|
697
698
|
filenames = ['*.pov', '*.inc']
|
698
699
|
mimetypes = ['text/x-povray']
|
@@ -700,7 +701,7 @@ class PovrayLexer(RegexLexer):
|
|
700
701
|
tokens = {
|
701
702
|
'root': [
|
702
703
|
(r'/\*[\w\W]*?\*/', Comment.Multiline),
|
703
|
-
(r'
|
704
|
+
(r'//.*$', Comment.Single),
|
704
705
|
(r'(?s)"(?:\\.|[^"\\])+"', String.Double),
|
705
706
|
(words((
|
706
707
|
'break', 'case', 'debug', 'declare', 'default', 'define', 'else',
|
@@ -766,16 +767,14 @@ class PovrayLexer(RegexLexer):
|
|
766
767
|
'quadric', 'quartic', 'smooth_triangle', 'sor', 'sphere', 'superellipsoid',
|
767
768
|
'text', 'torus', 'triangle', 'union'), suffix=r'\b'),
|
768
769
|
Name.Builtin),
|
769
|
-
# TODO: <=, etc
|
770
|
-
(r'[\[\](){}<>;,]', Punctuation),
|
771
|
-
(r'[-+*/=]', Operator),
|
772
770
|
(r'\b(x|y|z|u|v)\b', Name.Builtin.Pseudo),
|
773
771
|
(r'[a-zA-Z_]\w*', Name),
|
774
|
-
(r'[0-9]
|
775
|
-
(r'\.[0-9]+', Number.Float),
|
772
|
+
(r'[0-9]*\.[0-9]+', Number.Float),
|
776
773
|
(r'[0-9]+', Number.Integer),
|
774
|
+
(r'[\[\](){}<>;,]', Punctuation),
|
775
|
+
(r'[-+*/=.|&]|<=|>=|!=', Operator),
|
777
776
|
(r'"(\\\\|\\[^\\]|[^"\\])*"', String),
|
778
|
-
(r'\s+',
|
777
|
+
(r'\s+', Whitespace),
|
779
778
|
]
|
780
779
|
}
|
781
780
|
|
@@ -4,7 +4,7 @@
|
|
4
4
|
|
5
5
|
Lexer for the DOT language (graphviz).
|
6
6
|
|
7
|
-
:copyright: Copyright 2006-
|
7
|
+
:copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS.
|
8
8
|
:license: BSD, see LICENSE for details.
|
9
9
|
"""
|
10
10
|
|
@@ -23,6 +23,7 @@ class GraphvizLexer(RegexLexer):
|
|
23
23
|
.. versionadded:: 2.8
|
24
24
|
"""
|
25
25
|
name = 'Graphviz'
|
26
|
+
url = 'https://www.graphviz.org/doc/info/lang.html'
|
26
27
|
aliases = ['graphviz', 'dot']
|
27
28
|
filenames = ['*.gv', '*.dot']
|
28
29
|
mimetypes = ['text/x-graphviz', 'text/vnd.graphviz']
|
@@ -4,27 +4,29 @@
|
|
4
4
|
|
5
5
|
Lexers for TigerGraph GSQL graph query language
|
6
6
|
|
7
|
-
:copyright: Copyright 2006-
|
7
|
+
:copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS.
|
8
8
|
:license: BSD, see LICENSE for details.
|
9
9
|
"""
|
10
10
|
|
11
11
|
import re
|
12
12
|
|
13
13
|
from pygments.lexer import RegexLexer, include, bygroups, using, this, words
|
14
|
-
from pygments.token import Keyword, Punctuation, Comment, Operator, Name
|
15
|
-
String, Number, Whitespace
|
16
|
-
|
14
|
+
from pygments.token import Keyword, Punctuation, Comment, Operator, Name, \
|
15
|
+
String, Number, Whitespace
|
17
16
|
|
18
17
|
__all__ = ["GSQLLexer"]
|
19
18
|
|
19
|
+
|
20
20
|
class GSQLLexer(RegexLexer):
|
21
21
|
|
22
22
|
"""
|
23
|
-
For
|
23
|
+
For GSQL queries (version 3.x).
|
24
|
+
|
24
25
|
.. versionadded:: 2.10
|
25
26
|
"""
|
26
27
|
|
27
28
|
name = 'GSQL'
|
29
|
+
url = 'https://docs.tigergraph.com/dev/gsql-ref'
|
28
30
|
aliases = ['gsql']
|
29
31
|
filenames = ['*.gsql']
|
30
32
|
|
@@ -43,40 +45,49 @@ class GSQLLexer(RegexLexer):
|
|
43
45
|
include('operators'),
|
44
46
|
],
|
45
47
|
'comment': [
|
46
|
-
(r'
|
47
|
-
(r'
|
48
|
+
(r'\#.*', Comment.Single),
|
49
|
+
(r'/\*(.|\n)*?\*/', Comment.Multiline),
|
48
50
|
],
|
49
51
|
'keywords': [
|
50
52
|
(words((
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
53
|
+
'ACCUM', 'AND', 'ANY', 'API', 'AS', 'ASC', 'AVG', 'BAG', 'BATCH',
|
54
|
+
'BETWEEN', 'BOOL', 'BOTH', 'BREAK', 'BY', 'CASE', 'CATCH', 'COALESCE',
|
55
|
+
'COMPRESS', 'CONTINUE', 'COUNT', 'CREATE', 'DATETIME', 'DATETIME_ADD',
|
56
|
+
'DATETIME_SUB', 'DELETE', 'DESC', 'DISTRIBUTED', 'DO', 'DOUBLE',
|
57
|
+
'EDGE', 'ELSE', 'END', 'ESCAPE', 'EXCEPTION', 'FALSE', 'FILE',
|
58
|
+
'FILTER', 'FLOAT', 'FOREACH', 'FOR', 'FROM', 'GRAPH', 'GROUP',
|
59
|
+
'GSQL_INT_MAX', 'GSQL_INT_MIN', 'GSQL_UINT_MAX', 'HAVING', 'IF',
|
60
|
+
'IN', 'INSERT', 'INT', 'INTERPRET', 'INTERSECT', 'INTERVAL', 'INTO',
|
61
|
+
'IS', 'ISEMPTY', 'JSONARRAY', 'JSONOBJECT', 'LASTHOP', 'LEADING',
|
62
|
+
'LIKE', 'LIMIT', 'LIST', 'LOAD_ACCUM', 'LOG', 'MAP', 'MATCH', 'MAX',
|
63
|
+
'MIN', 'MINUS', 'NOT', 'NOW', 'NULL', 'OFFSET', 'OR', 'ORDER', 'PATH',
|
64
|
+
'PER', 'PINNED', 'POST_ACCUM', 'POST-ACCUM', 'PRIMARY_ID', 'PRINT',
|
65
|
+
'QUERY', 'RAISE', 'RANGE', 'REPLACE', 'RESET_COLLECTION_ACCUM',
|
66
|
+
'RETURN', 'RETURNS', 'RUN', 'SAMPLE', 'SELECT', 'SELECT_VERTEX',
|
67
|
+
'SET', 'SRC', 'STATIC', 'STRING', 'SUM', 'SYNTAX', 'TARGET',
|
68
|
+
'TAGSTGT', 'THEN', 'TO', 'TO_CSV', 'TO_DATETIME', 'TRAILING',
|
69
|
+
'TRIM', 'TRUE', 'TRY', 'TUPLE', 'TYPEDEF', 'UINT', 'UNION', 'UPDATE',
|
70
|
+
'VALUES', 'VERTEX', 'WHEN', 'WHERE', 'WHILE', 'WITH'),
|
71
|
+
prefix=r'(?<!\.)', suffix=r'\b'), Keyword),
|
62
72
|
],
|
63
73
|
'clauses': [
|
64
|
-
(words(('accum', 'having', 'limit', 'order', 'postAccum', 'sample', 'where')),
|
74
|
+
(words(('accum', 'having', 'limit', 'order', 'postAccum', 'sample', 'where')),
|
75
|
+
Name.Builtin),
|
65
76
|
],
|
66
77
|
'accums': [
|
67
|
-
(words(('andaccum', 'arrayaccum', 'avgaccum', 'bagaccum', 'bitwiseandaccum',
|
68
|
-
|
69
|
-
|
78
|
+
(words(('andaccum', 'arrayaccum', 'avgaccum', 'bagaccum', 'bitwiseandaccum',
|
79
|
+
'bitwiseoraccum', 'groupbyaccum', 'heapaccum', 'listaccum',
|
80
|
+
'MapAccum', 'maxaccum', 'minaccum', 'oraccum', 'setaccum',
|
81
|
+
'sumaccum')), Name.Builtin),
|
70
82
|
],
|
71
83
|
'relations': [
|
72
84
|
(r'(-\s?)(\(.*\:\w?\))(\s?-)', bygroups(Operator, using(this), Operator)),
|
73
85
|
(r'->|<-', Operator),
|
74
|
-
(r'[.*{}]', Punctuation),
|
86
|
+
(r'[.*{}\[\]\<\>\_]', Punctuation),
|
75
87
|
],
|
76
88
|
'strings': [
|
77
|
-
(r'"(
|
89
|
+
(r'"([^"\\]|\\.)*"', String),
|
78
90
|
(r'@{1,2}\w+', Name.Variable),
|
79
|
-
(r'(\<\w+)?\<(\w+\>?\,?\s?)+\>+', Name.Constant),
|
80
91
|
],
|
81
92
|
'whitespace': [
|
82
93
|
(r'\s+', Whitespace),
|
@@ -86,7 +97,8 @@ class GSQLLexer(RegexLexer):
|
|
86
97
|
(r'(\d+\.\d+|\d+)', Number),
|
87
98
|
],
|
88
99
|
'operators': [
|
89
|
-
(r'[^0-9|\/|\-](
|
90
|
-
|
100
|
+
(r'\$|[^0-9|\/|\-](\-\=|\+\=|\*\=|\\\=|\=|\=\=|\=\=\=|'
|
101
|
+
r'\+|\-|\*|\\|\+\=|\>|\<)[^\>|\/]', Operator),
|
102
|
+
(r'(\||\(|\)|\,|\;|\=|\-|\+|\*|\/|\>|\<|\:)', Operator),
|
91
103
|
],
|
92
104
|
}
|