From a289cfa85f1b54d0bdc81848a047b7d5819057ef Mon Sep 17 00:00:00 2001 From: NSDont Date: Mon, 6 Apr 2015 21:29:38 +0800 Subject: [PATCH 01/10] Removed Gui Open FullScreen --- vimrcs/extended.vim | 1 - 1 file changed, 1 deletion(-) diff --git a/vimrcs/extended.vim b/vimrcs/extended.vim index 255a31cfca..2a1e38400f 100644 --- a/vimrcs/extended.vim +++ b/vimrcs/extended.vim @@ -22,7 +22,6 @@ endif " Open MacVim in fullscreen mode if has("gui_macvim") set fuoptions=maxvert,maxhorz - au GUIEnter * set fullscreen endif " Disable scrollbars (real hackers don't use scrollbars for navigation!) From 624f1993d8048f6f738e270538e42691be80d5c3 Mon Sep 17 00:00:00 2001 From: NSDont Date: Tue, 7 Apr 2015 13:49:31 +0800 Subject: [PATCH 02/10] Updated plugins 1. Change taglist to tagbar. 2. Added Dockerfile.vim. 3. Added vim-gitgutter. 4. Added vim-wakatime. --- sources_non_forked/Dockerfile.vim/.gitignore | 2 + sources_non_forked/Dockerfile.vim/LICENSE | 20 + sources_non_forked/Dockerfile.vim/Makefile | 12 + sources_non_forked/Dockerfile.vim/README.md | 41 + .../Dockerfile.vim/ftdetect/Dockerfile.vim | 4 + .../snippets/Dockerfile.snippets | 62 + .../Dockerfile.vim/syntax/Dockerfile.vim | 54 + .../Dockerfile.vim/vim-dockerfile-example.png | Bin 0 -> 57722 bytes sources_non_forked/tagbar/.gitattributes | 4 + sources_non_forked/tagbar/.gitignore | 1 + sources_non_forked/tagbar/.info | 2 + sources_non_forked/tagbar/LICENSE | 82 + sources_non_forked/tagbar/README.md | 89 + sources_non_forked/tagbar/autoload/tagbar.vim | 4263 ++++++++++++++ sources_non_forked/tagbar/doc/tagbar.txt | 1508 +++++ sources_non_forked/tagbar/plugin/tagbar.vim | 146 + sources_non_forked/tagbar/syntax/tagbar.vim | 63 + sources_non_forked/taglist.vim/README | 18 - .../taglist.vim/doc/taglist.txt | 1501 ----- .../taglist.vim/plugin/taglist.vim | 4546 --------------- sources_non_forked/vim-gitgutter/.gitignore | 3 + sources_non_forked/vim-gitgutter/README.mkd | 329 ++ .../vim-gitgutter/autoload/gitgutter.vim | 217 + .../autoload/gitgutter/debug.vim | 66 + .../vim-gitgutter/autoload/gitgutter/diff.vim | 293 + .../autoload/gitgutter/highlight.vim | 115 + .../vim-gitgutter/autoload/gitgutter/hunk.vim | 109 + .../vim-gitgutter/autoload/gitgutter/sign.vim | 173 + .../autoload/gitgutter/utility.vim | 149 + .../vim-gitgutter/doc/gitgutter.txt | 272 + .../vim-gitgutter/plugin/gitgutter.vim | 190 + .../vim-gitgutter/screenshot.png | Bin 0 -> 16191 bytes .../vim-gitgutter/test/README.markdown | 30 + .../vim-gitgutter/test/addLines.expected | 4 + .../vim-gitgutter/test/ambiguousFile.expected | 4 + .../test/fileAddedToGit.expected | 4 + .../test/filenameWithSquareBrackets.expected | 5 + .../vim-gitgutter/test/fix[tu]re.txt | 0 .../vim-gitgutter/test/fixture.txt | 11 + .../vim-gitgutter/test/followSymlink.expected | 4 + .../vim-gitgutter/test/helper.vim | 27 + ...unkOutsideNoopRevertGitDiffStaged.expected | 0 ...HunkOutsideNoopStageGitDiffStaged.expected | 0 .../test/hunkOutsideNoopRevertSigns.expected | 2 + .../test/hunkOutsideNoopStageSigns.expected | 2 + .../test/hunkRevertGitDiff.expected | 0 .../test/hunkRevertNearbyGitDiff.expected | 13 + .../test/hunkRevertNearbySigns.expected | 6 + .../test/hunkRevertSigns.expected | 2 + .../test/hunkStageGitDiff.expected | 13 + .../test/hunkStageNearbyGitDiff.expected | 13 + .../hunkStageNearbyGitDiffStaged.expected | 12 + .../test/hunkStageNearbySigns.expected | 6 + .../test/hunkStageSigns.expected | 2 + .../vim-gitgutter/test/keepAlt.expected | 3 + .../vim-gitgutter/test/keepModified.expected | 2 + .../vim-gitgutter/test/keepOpMarks.expected | 4 + .../vim-gitgutter/test/modifyLines.expected | 4 + .../test/noModifications.expected | 2 + .../vim-gitgutter/test/orphanedSigns.expected | 4 + .../test/removeFirstLines.expected | 4 + .../vim-gitgutter/test/removeLines.expected | 4 + .../test/signColumnAlways.expected | 4 + sources_non_forked/vim-gitgutter/test/test | 38 + .../vim-gitgutter/test/testAddLines.vim | 6 + .../test/testEditAmbiguousFile.vim | 9 + .../vim-gitgutter/test/testFileAddedToGit.vim | 12 + .../test/testFilenameWithSquareBrackets.vim | 9 + .../vim-gitgutter/test/testFollowSymlink.vim | 10 + .../test/testHunkOutsideNoop.vim | 13 + .../vim-gitgutter/test/testHunkRevert.vim | 7 + .../test/testHunkRevertNearbyHunk.vim | 9 + .../vim-gitgutter/test/testHunkStage.vim | 7 + .../test/testHunkStageNearbyHunk.vim | 10 + .../vim-gitgutter/test/testKeepAlt.vim | 12 + .../vim-gitgutter/test/testKeepModified.vim | 8 + .../vim-gitgutter/test/testKeepOpMarks.vim | 10 + .../vim-gitgutter/test/testModifyLines.vim | 6 + .../test/testNoModifications.vim | 4 + .../vim-gitgutter/test/testOrphanedSigns.vim | 8 + .../test/testRemoveFirstLines.vim | 6 + .../vim-gitgutter/test/testRemoveLines.vim | 6 + .../test/testSignColumnAlways.vim | 7 + .../test/testUntrackedFileOutsideRepo.vim | 6 + .../test/testUntrackedFileWithinRepo.vim | 8 + .../test/untrackedFileOutsideRepo.expected | 2 + .../test/untrackedFileWithinRepo.expected | 2 + sources_non_forked/vim-wakatime/.gitignore | 36 + sources_non_forked/vim-wakatime/AUTHORS | 15 + sources_non_forked/vim-wakatime/HISTORY.rst | 392 ++ sources_non_forked/vim-wakatime/LICENSE.txt | 31 + sources_non_forked/vim-wakatime/README.md | 43 + .../vim-wakatime/doc/wakatime.txt | 0 .../plugin/packages/wakatime/__about__.py | 9 + .../plugin/packages/wakatime/__init__.py | 17 + .../plugin/packages/wakatime/base.py | 461 ++ .../plugin/packages/wakatime/cli.py | 18 + .../plugin/packages/wakatime/compat.py | 76 + .../packages/wakatime/languages/__init__.py | 106 + .../packages/wakatime/languages/c_cpp.py | 37 + .../packages/wakatime/languages/data.py | 66 + .../packages/wakatime/languages/dotnet.py | 36 + .../plugin/packages/wakatime/languages/jvm.py | 36 + .../plugin/packages/wakatime/languages/php.py | 87 + .../packages/wakatime/languages/python.py | 120 + .../packages/wakatime/languages/templates.py | 224 + .../packages/wakatime/languages/unknown.py | 33 + .../plugin/packages/wakatime/logger.py | 104 + .../plugin/packages/wakatime/offlinequeue.py | 123 + .../packages/wakatime/packages/__init__.py | 0 .../packages/wakatime/packages/argparse.py | 2362 ++++++++ .../packages/wakatime/packages/ordereddict.py | 127 + .../pygments_py2/pygments/__init__.py | 91 + .../packages/pygments_py2/pygments/cmdline.py | 509 ++ .../packages/pygments_py2/pygments/console.py | 74 + .../packages/pygments_py2/pygments/filter.py | 74 + .../pygments_py2/pygments/filters/__init__.py | 350 ++ .../pygments_py2/pygments/formatter.py | 95 + .../pygments/formatters/__init__.py | 118 + .../pygments/formatters/_mapping.py | 76 + .../pygments/formatters/bbcode.py | 109 + .../pygments_py2/pygments/formatters/html.py | 839 +++ .../pygments_py2/pygments/formatters/img.py | 560 ++ .../pygments_py2/pygments/formatters/latex.py | 476 ++ .../pygments_py2/pygments/formatters/other.py | 160 + .../pygments_py2/pygments/formatters/rtf.py | 147 + .../pygments_py2/pygments/formatters/svg.py | 153 + .../pygments/formatters/terminal.py | 151 + .../pygments/formatters/terminal256.py | 223 + .../packages/pygments_py2/pygments/lexer.py | 870 +++ .../pygments_py2/pygments/lexers/__init__.py | 273 + .../pygments/lexers/_asy_builtins.py | 1645 ++++++ .../pygments/lexers/_cl_builtins.py | 232 + .../pygments/lexers/_cocoa_builtins.py | 73 + .../pygments/lexers/_lasso_builtins.py | 5182 +++++++++++++++++ .../pygments/lexers/_lua_builtins.py | 250 + .../pygments_py2/pygments/lexers/_mapping.py | 413 ++ .../pygments/lexers/_mql_builtins.py | 1172 ++++ .../pygments/lexers/_openedge_builtins.py | 2547 ++++++++ .../pygments/lexers/_php_builtins.py | 4755 +++++++++++++++ .../pygments/lexers/_postgres_builtins.py | 620 ++ .../pygments/lexers/_scilab_builtins.py | 3093 ++++++++++ .../pygments/lexers/_sourcemod_builtins.py | 1161 ++++ .../pygments/lexers/_stan_builtins.py | 498 ++ .../pygments/lexers/_vim_builtins.py | 1939 ++++++ .../pygments/lexers/actionscript.py | 240 + .../pygments_py2/pygments/lexers/agile.py | 24 + .../pygments_py2/pygments/lexers/algebra.py | 187 + .../pygments_py2/pygments/lexers/ambient.py | 76 + .../pygments_py2/pygments/lexers/apl.py | 101 + .../pygments_py2/pygments/lexers/asm.py | 435 ++ .../pygments/lexers/automation.py | 373 ++ .../pygments_py2/pygments/lexers/basic.py | 500 ++ .../pygments_py2/pygments/lexers/business.py | 592 ++ .../pygments_py2/pygments/lexers/c_cpp.py | 233 + .../pygments_py2/pygments/lexers/c_like.py | 413 ++ .../pygments_py2/pygments/lexers/chapel.py | 98 + .../pygments_py2/pygments/lexers/compiled.py | 33 + .../pygments_py2/pygments/lexers/configs.py | 546 ++ .../pygments_py2/pygments/lexers/console.py | 114 + .../pygments_py2/pygments/lexers/css.py | 498 ++ .../pygments_py2/pygments/lexers/d.py | 251 + .../pygments_py2/pygments/lexers/dalvik.py | 125 + .../pygments_py2/pygments/lexers/data.py | 530 ++ .../pygments_py2/pygments/lexers/diff.py | 106 + .../pygments_py2/pygments/lexers/dotnet.py | 689 +++ .../pygments_py2/pygments/lexers/dsls.py | 514 ++ .../pygments_py2/pygments/lexers/dylan.py | 289 + .../pygments_py2/pygments/lexers/ecl.py | 125 + .../pygments_py2/pygments/lexers/eiffel.py | 65 + .../pygments_py2/pygments/lexers/erlang.py | 511 ++ .../pygments_py2/pygments/lexers/esoteric.py | 114 + .../pygments_py2/pygments/lexers/factor.py | 344 ++ .../pygments_py2/pygments/lexers/fantom.py | 250 + .../pygments_py2/pygments/lexers/felix.py | 273 + .../pygments_py2/pygments/lexers/fortran.py | 161 + .../pygments_py2/pygments/lexers/foxpro.py | 428 ++ .../pygments/lexers/functional.py | 21 + .../pygments_py2/pygments/lexers/go.py | 101 + .../pygments_py2/pygments/lexers/graph.py | 79 + .../pygments_py2/pygments/lexers/graphics.py | 553 ++ .../pygments_py2/pygments/lexers/haskell.py | 840 +++ .../pygments_py2/pygments/lexers/haxe.py | 936 +++ .../pygments_py2/pygments/lexers/hdl.py | 375 ++ .../pygments_py2/pygments/lexers/html.py | 589 ++ .../pygments_py2/pygments/lexers/idl.py | 262 + .../pygments_py2/pygments/lexers/igor.py | 279 + .../pygments_py2/pygments/lexers/inferno.py | 96 + .../pygments/lexers/installers.py | 322 + .../pygments/lexers/int_fiction.py | 1342 +++++ .../pygments_py2/pygments/lexers/iolang.py | 63 + .../pygments/lexers/javascript.py | 1199 ++++ .../pygments_py2/pygments/lexers/julia.py | 194 + .../pygments_py2/pygments/lexers/jvm.py | 1560 +++++ .../pygments_py2/pygments/lexers/lisp.py | 1480 +++++ .../pygments_py2/pygments/lexers/make.py | 201 + .../pygments_py2/pygments/lexers/markup.py | 502 ++ .../pygments_py2/pygments/lexers/math.py | 21 + .../pygments_py2/pygments/lexers/matlab.py | 663 +++ .../pygments_py2/pygments/lexers/ml.py | 769 +++ .../pygments_py2/pygments/lexers/modeling.py | 356 ++ .../pygments_py2/pygments/lexers/nimrod.py | 159 + .../pygments_py2/pygments/lexers/nit.py | 64 + .../pygments_py2/pygments/lexers/nix.py | 136 + .../pygments_py2/pygments/lexers/objective.py | 487 ++ .../pygments_py2/pygments/lexers/ooc.py | 85 + .../pygments_py2/pygments/lexers/other.py | 40 + .../pygments_py2/pygments/lexers/parsers.py | 835 +++ .../pygments_py2/pygments/lexers/pascal.py | 831 +++ .../pygments_py2/pygments/lexers/pawn.py | 199 + .../pygments_py2/pygments/lexers/perl.py | 614 ++ .../pygments_py2/pygments/lexers/php.py | 245 + .../pygments_py2/pygments/lexers/prolog.py | 306 + .../pygments_py2/pygments/lexers/python.py | 833 +++ .../pygments_py2/pygments/lexers/r.py | 453 ++ .../pygments_py2/pygments/lexers/rdf.py | 99 + .../pygments_py2/pygments/lexers/rebol.py | 431 ++ .../pygments_py2/pygments/lexers/resource.py | 84 + .../pygments/lexers/robotframework.py | 560 ++ .../pygments_py2/pygments/lexers/ruby.py | 518 ++ .../pygments_py2/pygments/lexers/rust.py | 167 + .../pygments_py2/pygments/lexers/scripting.py | 923 +++ .../pygments_py2/pygments/lexers/shell.py | 437 ++ .../pygments_py2/pygments/lexers/smalltalk.py | 195 + .../pygments_py2/pygments/lexers/snobol.py | 83 + .../pygments_py2/pygments/lexers/special.py | 100 + .../pygments_py2/pygments/lexers/sql.py | 598 ++ .../pygments_py2/pygments/lexers/tcl.py | 145 + .../pygments_py2/pygments/lexers/templates.py | 2174 +++++++ .../pygments_py2/pygments/lexers/testing.py | 131 + .../pygments_py2/pygments/lexers/text.py | 25 + .../pygments_py2/pygments/lexers/textedit.py | 169 + .../pygments_py2/pygments/lexers/textfmts.py | 292 + .../pygments_py2/pygments/lexers/theorem.py | 466 ++ .../pygments_py2/pygments/lexers/urbi.py | 133 + .../pygments_py2/pygments/lexers/web.py | 24 + .../pygments_py2/pygments/lexers/webmisc.py | 920 +++ .../pygments_py2/pygments/modeline.py | 40 + .../packages/pygments_py2/pygments/plugin.py | 74 + .../pygments_py2/pygments/regexopt.py | 92 + .../packages/pygments_py2/pygments/scanner.py | 104 + .../pygments_py2/pygments/sphinxext.py | 155 + .../packages/pygments_py2/pygments/style.py | 118 + .../pygments_py2/pygments/styles/__init__.py | 74 + .../pygments_py2/pygments/styles/autumn.py | 65 + .../pygments_py2/pygments/styles/borland.py | 51 + .../pygments_py2/pygments/styles/bw.py | 49 + .../pygments_py2/pygments/styles/colorful.py | 81 + .../pygments_py2/pygments/styles/default.py | 73 + .../pygments_py2/pygments/styles/emacs.py | 72 + .../pygments_py2/pygments/styles/friendly.py | 72 + .../pygments_py2/pygments/styles/fruity.py | 42 + .../pygments_py2/pygments/styles/igor.py | 29 + .../pygments_py2/pygments/styles/manni.py | 75 + .../pygments_py2/pygments/styles/monokai.py | 106 + .../pygments_py2/pygments/styles/murphy.py | 80 + .../pygments_py2/pygments/styles/native.py | 65 + .../pygments/styles/paraiso_dark.py | 125 + .../pygments/styles/paraiso_light.py | 125 + .../pygments_py2/pygments/styles/pastie.py | 75 + .../pygments_py2/pygments/styles/perldoc.py | 69 + .../pygments_py2/pygments/styles/rrt.py | 33 + .../pygments_py2/pygments/styles/tango.py | 141 + .../pygments_py2/pygments/styles/trac.py | 63 + .../pygments_py2/pygments/styles/vim.py | 63 + .../pygments_py2/pygments/styles/vs.py | 38 + .../pygments_py2/pygments/styles/xcode.py | 51 + .../packages/pygments_py2/pygments/token.py | 198 + .../pygments_py2/pygments/unistring.py | 217 + .../packages/pygments_py2/pygments/util.py | 377 ++ .../pygments_py3/pygments/__init__.py | 91 + .../packages/pygments_py3/pygments/cmdline.py | 509 ++ .../packages/pygments_py3/pygments/console.py | 74 + .../packages/pygments_py3/pygments/filter.py | 74 + .../pygments_py3/pygments/filters/__init__.py | 350 ++ .../pygments_py3/pygments/formatter.py | 95 + .../pygments/formatters/__init__.py | 118 + .../pygments/formatters/_mapping.py | 76 + .../pygments/formatters/bbcode.py | 109 + .../pygments_py3/pygments/formatters/html.py | 839 +++ .../pygments_py3/pygments/formatters/img.py | 560 ++ .../pygments_py3/pygments/formatters/latex.py | 476 ++ .../pygments_py3/pygments/formatters/other.py | 160 + .../pygments_py3/pygments/formatters/rtf.py | 147 + .../pygments_py3/pygments/formatters/svg.py | 153 + .../pygments/formatters/terminal.py | 151 + .../pygments/formatters/terminal256.py | 223 + .../packages/pygments_py3/pygments/lexer.py | 870 +++ .../pygments_py3/pygments/lexers/__init__.py | 273 + .../pygments/lexers/_asy_builtins.py | 1645 ++++++ .../pygments/lexers/_cl_builtins.py | 232 + .../pygments/lexers/_cocoa_builtins.py | 73 + .../pygments/lexers/_lasso_builtins.py | 5182 +++++++++++++++++ .../pygments/lexers/_lua_builtins.py | 250 + .../pygments_py3/pygments/lexers/_mapping.py | 413 ++ .../pygments/lexers/_mql_builtins.py | 1172 ++++ .../pygments/lexers/_openedge_builtins.py | 2547 ++++++++ .../pygments/lexers/_php_builtins.py | 4755 +++++++++++++++ .../pygments/lexers/_postgres_builtins.py | 620 ++ .../pygments/lexers/_scilab_builtins.py | 3093 ++++++++++ .../pygments/lexers/_sourcemod_builtins.py | 1161 ++++ .../pygments/lexers/_stan_builtins.py | 498 ++ .../pygments/lexers/_vim_builtins.py | 1939 ++++++ .../pygments/lexers/actionscript.py | 240 + .../pygments_py3/pygments/lexers/agile.py | 24 + .../pygments_py3/pygments/lexers/algebra.py | 187 + .../pygments_py3/pygments/lexers/ambient.py | 76 + .../pygments_py3/pygments/lexers/apl.py | 101 + .../pygments_py3/pygments/lexers/asm.py | 435 ++ .../pygments/lexers/automation.py | 373 ++ .../pygments_py3/pygments/lexers/basic.py | 500 ++ .../pygments_py3/pygments/lexers/business.py | 592 ++ .../pygments_py3/pygments/lexers/c_cpp.py | 233 + .../pygments_py3/pygments/lexers/c_like.py | 413 ++ .../pygments_py3/pygments/lexers/chapel.py | 98 + .../pygments_py3/pygments/lexers/compiled.py | 33 + .../pygments_py3/pygments/lexers/configs.py | 546 ++ .../pygments_py3/pygments/lexers/console.py | 114 + .../pygments_py3/pygments/lexers/css.py | 498 ++ .../pygments_py3/pygments/lexers/d.py | 251 + .../pygments_py3/pygments/lexers/dalvik.py | 125 + .../pygments_py3/pygments/lexers/data.py | 530 ++ .../pygments_py3/pygments/lexers/diff.py | 106 + .../pygments_py3/pygments/lexers/dotnet.py | 689 +++ .../pygments_py3/pygments/lexers/dsls.py | 514 ++ .../pygments_py3/pygments/lexers/dylan.py | 289 + .../pygments_py3/pygments/lexers/ecl.py | 125 + .../pygments_py3/pygments/lexers/eiffel.py | 65 + .../pygments_py3/pygments/lexers/erlang.py | 511 ++ .../pygments_py3/pygments/lexers/esoteric.py | 114 + .../pygments_py3/pygments/lexers/factor.py | 344 ++ .../pygments_py3/pygments/lexers/fantom.py | 250 + .../pygments_py3/pygments/lexers/felix.py | 273 + .../pygments_py3/pygments/lexers/fortran.py | 161 + .../pygments_py3/pygments/lexers/foxpro.py | 428 ++ .../pygments/lexers/functional.py | 21 + .../pygments_py3/pygments/lexers/go.py | 101 + .../pygments_py3/pygments/lexers/graph.py | 79 + .../pygments_py3/pygments/lexers/graphics.py | 553 ++ .../pygments_py3/pygments/lexers/haskell.py | 840 +++ .../pygments_py3/pygments/lexers/haxe.py | 936 +++ .../pygments_py3/pygments/lexers/hdl.py | 375 ++ .../pygments_py3/pygments/lexers/html.py | 589 ++ .../pygments_py3/pygments/lexers/idl.py | 262 + .../pygments_py3/pygments/lexers/igor.py | 279 + .../pygments_py3/pygments/lexers/inferno.py | 96 + .../pygments/lexers/installers.py | 322 + .../pygments/lexers/int_fiction.py | 1342 +++++ .../pygments_py3/pygments/lexers/iolang.py | 63 + .../pygments/lexers/javascript.py | 1199 ++++ .../pygments_py3/pygments/lexers/julia.py | 194 + .../pygments_py3/pygments/lexers/jvm.py | 1560 +++++ .../pygments_py3/pygments/lexers/lisp.py | 1480 +++++ .../pygments_py3/pygments/lexers/make.py | 201 + .../pygments_py3/pygments/lexers/markup.py | 502 ++ .../pygments_py3/pygments/lexers/math.py | 21 + .../pygments_py3/pygments/lexers/matlab.py | 663 +++ .../pygments_py3/pygments/lexers/ml.py | 769 +++ .../pygments_py3/pygments/lexers/modeling.py | 356 ++ .../pygments_py3/pygments/lexers/nimrod.py | 159 + .../pygments_py3/pygments/lexers/nit.py | 64 + .../pygments_py3/pygments/lexers/nix.py | 136 + .../pygments_py3/pygments/lexers/objective.py | 487 ++ .../pygments_py3/pygments/lexers/ooc.py | 85 + .../pygments_py3/pygments/lexers/other.py | 40 + .../pygments_py3/pygments/lexers/parsers.py | 835 +++ .../pygments_py3/pygments/lexers/pascal.py | 831 +++ .../pygments_py3/pygments/lexers/pawn.py | 199 + .../pygments_py3/pygments/lexers/perl.py | 614 ++ .../pygments_py3/pygments/lexers/php.py | 245 + .../pygments_py3/pygments/lexers/prolog.py | 306 + .../pygments_py3/pygments/lexers/python.py | 833 +++ .../pygments_py3/pygments/lexers/r.py | 453 ++ .../pygments_py3/pygments/lexers/rdf.py | 99 + .../pygments_py3/pygments/lexers/rebol.py | 431 ++ .../pygments_py3/pygments/lexers/resource.py | 84 + .../pygments/lexers/robotframework.py | 560 ++ .../pygments_py3/pygments/lexers/ruby.py | 518 ++ .../pygments_py3/pygments/lexers/rust.py | 167 + .../pygments_py3/pygments/lexers/scripting.py | 923 +++ .../pygments_py3/pygments/lexers/shell.py | 437 ++ .../pygments_py3/pygments/lexers/smalltalk.py | 195 + .../pygments_py3/pygments/lexers/snobol.py | 83 + .../pygments_py3/pygments/lexers/special.py | 100 + .../pygments_py3/pygments/lexers/sql.py | 598 ++ .../pygments_py3/pygments/lexers/tcl.py | 145 + .../pygments_py3/pygments/lexers/templates.py | 2174 +++++++ .../pygments_py3/pygments/lexers/testing.py | 131 + .../pygments_py3/pygments/lexers/text.py | 25 + .../pygments_py3/pygments/lexers/textedit.py | 169 + .../pygments_py3/pygments/lexers/textfmts.py | 292 + .../pygments_py3/pygments/lexers/theorem.py | 466 ++ .../pygments_py3/pygments/lexers/urbi.py | 133 + .../pygments_py3/pygments/lexers/web.py | 24 + .../pygments_py3/pygments/lexers/webmisc.py | 920 +++ .../pygments_py3/pygments/modeline.py | 40 + .../packages/pygments_py3/pygments/plugin.py | 74 + .../pygments_py3/pygments/regexopt.py | 92 + .../packages/pygments_py3/pygments/scanner.py | 104 + .../pygments_py3/pygments/sphinxext.py | 155 + .../packages/pygments_py3/pygments/style.py | 118 + .../pygments_py3/pygments/styles/__init__.py | 74 + .../pygments_py3/pygments/styles/autumn.py | 65 + .../pygments_py3/pygments/styles/borland.py | 51 + .../pygments_py3/pygments/styles/bw.py | 49 + .../pygments_py3/pygments/styles/colorful.py | 81 + .../pygments_py3/pygments/styles/default.py | 73 + .../pygments_py3/pygments/styles/emacs.py | 72 + .../pygments_py3/pygments/styles/friendly.py | 72 + .../pygments_py3/pygments/styles/fruity.py | 42 + .../pygments_py3/pygments/styles/igor.py | 29 + .../pygments_py3/pygments/styles/manni.py | 75 + .../pygments_py3/pygments/styles/monokai.py | 106 + .../pygments_py3/pygments/styles/murphy.py | 80 + .../pygments_py3/pygments/styles/native.py | 65 + .../pygments/styles/paraiso_dark.py | 125 + .../pygments/styles/paraiso_light.py | 125 + .../pygments_py3/pygments/styles/pastie.py | 75 + .../pygments_py3/pygments/styles/perldoc.py | 69 + .../pygments_py3/pygments/styles/rrt.py | 33 + .../pygments_py3/pygments/styles/tango.py | 141 + .../pygments_py3/pygments/styles/trac.py | 63 + .../pygments_py3/pygments/styles/vim.py | 63 + .../pygments_py3/pygments/styles/vs.py | 38 + .../pygments_py3/pygments/styles/xcode.py | 51 + .../packages/pygments_py3/pygments/token.py | 198 + .../pygments_py3/pygments/unistring.py | 217 + .../packages/pygments_py3/pygments/util.py | 377 ++ .../wakatime/packages/pytz/__init__.py | 1512 +++++ .../wakatime/packages/pytz/exceptions.py | 48 + .../packages/wakatime/packages/pytz/lazy.py | 148 + .../wakatime/packages/pytz/reference.py | 127 + .../wakatime/packages/pytz/tests/test_docs.py | 36 + .../packages/pytz/tests/test_tzinfo.py | 813 +++ .../packages/wakatime/packages/pytz/tzfile.py | 137 + .../packages/wakatime/packages/pytz/tzinfo.py | 563 ++ .../packages/pytz/zoneinfo/Africa/Abidjan | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/Africa/Accra | Bin 0 -> 378 bytes .../packages/pytz/zoneinfo/Africa/Addis_Ababa | Bin 0 -> 180 bytes .../packages/pytz/zoneinfo/Africa/Algiers | Bin 0 -> 734 bytes .../packages/pytz/zoneinfo/Africa/Asmara | Bin 0 -> 201 bytes .../packages/pytz/zoneinfo/Africa/Asmera | Bin 0 -> 201 bytes .../packages/pytz/zoneinfo/Africa/Bamako | Bin 0 -> 224 bytes .../packages/pytz/zoneinfo/Africa/Bangui | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Banjul | Bin 0 -> 232 bytes .../packages/pytz/zoneinfo/Africa/Bissau | Bin 0 -> 194 bytes .../packages/pytz/zoneinfo/Africa/Blantyre | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Brazzaville | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Bujumbura | Bin 0 -> 140 bytes .../packages/pytz/zoneinfo/Africa/Cairo | Bin 0 -> 1906 bytes .../packages/pytz/zoneinfo/Africa/Casablanca | Bin 0 -> 1558 bytes .../packages/pytz/zoneinfo/Africa/Ceuta | Bin 0 -> 2049 bytes .../packages/pytz/zoneinfo/Africa/Conakry | Bin 0 -> 224 bytes .../packages/pytz/zoneinfo/Africa/Dakar | Bin 0 -> 194 bytes .../pytz/zoneinfo/Africa/Dar_es_Salaam | Bin 0 -> 229 bytes .../packages/pytz/zoneinfo/Africa/Djibouti | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Douala | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/El_Aaiun | Bin 0 -> 194 bytes .../packages/pytz/zoneinfo/Africa/Freetown | Bin 0 -> 665 bytes .../packages/pytz/zoneinfo/Africa/Gaborone | Bin 0 -> 234 bytes .../packages/pytz/zoneinfo/Africa/Harare | Bin 0 -> 157 bytes .../pytz/zoneinfo/Africa/Johannesburg | Bin 0 -> 245 bytes .../packages/pytz/zoneinfo/Africa/Juba | Bin 0 -> 669 bytes .../packages/pytz/zoneinfo/Africa/Kampala | Bin 0 -> 269 bytes .../packages/pytz/zoneinfo/Africa/Khartoum | Bin 0 -> 669 bytes .../packages/pytz/zoneinfo/Africa/Kigali | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Kinshasa | Bin 0 -> 140 bytes .../packages/pytz/zoneinfo/Africa/Lagos | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Libreville | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Lome | Bin 0 -> 139 bytes .../packages/pytz/zoneinfo/Africa/Luanda | Bin 0 -> 178 bytes .../packages/pytz/zoneinfo/Africa/Lubumbashi | Bin 0 -> 140 bytes .../packages/pytz/zoneinfo/Africa/Lusaka | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Malabo | Bin 0 -> 195 bytes .../packages/pytz/zoneinfo/Africa/Maputo | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Africa/Maseru | Bin 0 -> 204 bytes .../packages/pytz/zoneinfo/Africa/Mbabane | Bin 0 -> 160 bytes .../packages/pytz/zoneinfo/Africa/Mogadishu | Bin 0 -> 210 bytes .../packages/pytz/zoneinfo/Africa/Monrovia | Bin 0 -> 215 bytes .../packages/pytz/zoneinfo/Africa/Nairobi | Bin 0 -> 269 bytes .../packages/pytz/zoneinfo/Africa/Ndjamena | Bin 0 -> 211 bytes .../packages/pytz/zoneinfo/Africa/Niamey | Bin 0 -> 225 bytes .../packages/pytz/zoneinfo/Africa/Nouakchott | Bin 0 -> 224 bytes .../packages/pytz/zoneinfo/Africa/Ouagadougou | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/Africa/Porto-Novo | Bin 0 -> 195 bytes .../packages/pytz/zoneinfo/Africa/Sao_Tome | Bin 0 -> 173 bytes .../packages/pytz/zoneinfo/Africa/Timbuktu | Bin 0 -> 224 bytes .../packages/pytz/zoneinfo/Africa/Tripoli | Bin 0 -> 1350 bytes .../packages/pytz/zoneinfo/Africa/Tunis | Bin 0 -> 684 bytes .../packages/pytz/zoneinfo/Africa/Windhoek | Bin 0 -> 1556 bytes .../packages/pytz/zoneinfo/America/Adak | Bin 0 -> 2353 bytes .../packages/pytz/zoneinfo/America/Anchorage | Bin 0 -> 2358 bytes .../packages/pytz/zoneinfo/America/Anguilla | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Antigua | Bin 0 -> 194 bytes .../packages/pytz/zoneinfo/America/Araguaina | Bin 0 -> 1609 bytes .../zoneinfo/America/Argentina/Buenos_Aires | Bin 0 -> 1061 bytes .../pytz/zoneinfo/America/Argentina/Catamarca | Bin 0 -> 1103 bytes .../zoneinfo/America/Argentina/ComodRivadavia | Bin 0 -> 1103 bytes .../pytz/zoneinfo/America/Argentina/Cordoba | Bin 0 -> 1103 bytes .../pytz/zoneinfo/America/Argentina/Jujuy | Bin 0 -> 1119 bytes .../pytz/zoneinfo/America/Argentina/La_Rioja | Bin 0 -> 1117 bytes .../pytz/zoneinfo/America/Argentina/Mendoza | Bin 0 -> 1147 bytes .../zoneinfo/America/Argentina/Rio_Gallegos | Bin 0 -> 1103 bytes .../pytz/zoneinfo/America/Argentina/Salta | Bin 0 -> 1075 bytes .../pytz/zoneinfo/America/Argentina/San_Juan | Bin 0 -> 1117 bytes .../pytz/zoneinfo/America/Argentina/San_Luis | Bin 0 -> 1125 bytes .../pytz/zoneinfo/America/Argentina/Tucuman | Bin 0 -> 1131 bytes .../pytz/zoneinfo/America/Argentina/Ushuaia | Bin 0 -> 1103 bytes .../packages/pytz/zoneinfo/America/Aruba | Bin 0 -> 194 bytes .../packages/pytz/zoneinfo/America/Asuncion | Bin 0 -> 2036 bytes .../packages/pytz/zoneinfo/America/Atikokan | Bin 0 -> 319 bytes .../packages/pytz/zoneinfo/America/Atka | Bin 0 -> 2353 bytes .../packages/pytz/zoneinfo/America/Bahia | Bin 0 -> 1022 bytes .../pytz/zoneinfo/America/Bahia_Banderas | Bin 0 -> 1574 bytes .../packages/pytz/zoneinfo/America/Barbados | Bin 0 -> 330 bytes .../packages/pytz/zoneinfo/America/Belem | Bin 0 -> 574 bytes .../packages/pytz/zoneinfo/America/Belize | Bin 0 -> 962 bytes .../pytz/zoneinfo/America/Blanc-Sablon | Bin 0 -> 281 bytes .../packages/pytz/zoneinfo/America/Boa_Vista | Bin 0 -> 630 bytes .../packages/pytz/zoneinfo/America/Bogota | Bin 0 -> 231 bytes .../packages/pytz/zoneinfo/America/Boise | Bin 0 -> 2377 bytes .../pytz/zoneinfo/America/Buenos_Aires | Bin 0 -> 1061 bytes .../pytz/zoneinfo/America/Cambridge_Bay | Bin 0 -> 2084 bytes .../pytz/zoneinfo/America/Campo_Grande | Bin 0 -> 2001 bytes .../packages/pytz/zoneinfo/America/Cancun | Bin 0 -> 1466 bytes .../packages/pytz/zoneinfo/America/Caracas | Bin 0 -> 240 bytes .../packages/pytz/zoneinfo/America/Catamarca | Bin 0 -> 1103 bytes .../packages/pytz/zoneinfo/America/Cayenne | Bin 0 -> 186 bytes .../packages/pytz/zoneinfo/America/Cayman | Bin 0 -> 177 bytes .../packages/pytz/zoneinfo/America/Chicago | Bin 0 -> 3559 bytes .../packages/pytz/zoneinfo/America/Chihuahua | Bin 0 -> 1508 bytes .../pytz/zoneinfo/America/Coral_Harbour | Bin 0 -> 319 bytes .../packages/pytz/zoneinfo/America/Cordoba | Bin 0 -> 1103 bytes .../packages/pytz/zoneinfo/America/Costa_Rica | Bin 0 -> 315 bytes .../packages/pytz/zoneinfo/America/Creston | Bin 0 -> 207 bytes .../packages/pytz/zoneinfo/America/Cuiaba | Bin 0 -> 1973 bytes .../packages/pytz/zoneinfo/America/Curacao | Bin 0 -> 194 bytes .../pytz/zoneinfo/America/Danmarkshavn | Bin 0 -> 700 bytes .../packages/pytz/zoneinfo/America/Dawson | Bin 0 -> 2067 bytes .../pytz/zoneinfo/America/Dawson_Creek | Bin 0 -> 1033 bytes .../packages/pytz/zoneinfo/America/Denver | Bin 0 -> 2427 bytes .../packages/pytz/zoneinfo/America/Detroit | Bin 0 -> 2202 bytes .../packages/pytz/zoneinfo/America/Dominica | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Edmonton | Bin 0 -> 2388 bytes .../packages/pytz/zoneinfo/America/Eirunepe | Bin 0 -> 640 bytes .../pytz/zoneinfo/America/El_Salvador | Bin 0 -> 236 bytes .../packages/pytz/zoneinfo/America/Ensenada | Bin 0 -> 2342 bytes .../packages/pytz/zoneinfo/America/Fort_Wayne | Bin 0 -> 1649 bytes .../packages/pytz/zoneinfo/America/Fortaleza | Bin 0 -> 714 bytes .../packages/pytz/zoneinfo/America/Glace_Bay | Bin 0 -> 2192 bytes .../packages/pytz/zoneinfo/America/Godthab | Bin 0 -> 8296 bytes .../packages/pytz/zoneinfo/America/Goose_Bay | Bin 0 -> 3193 bytes .../packages/pytz/zoneinfo/America/Grand_Turk | Bin 0 -> 1871 bytes .../packages/pytz/zoneinfo/America/Grenada | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Guadeloupe | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Guatemala | Bin 0 -> 292 bytes .../packages/pytz/zoneinfo/America/Guayaquil | Bin 0 -> 177 bytes .../packages/pytz/zoneinfo/America/Guyana | Bin 0 -> 256 bytes .../packages/pytz/zoneinfo/America/Halifax | Bin 0 -> 3424 bytes .../packages/pytz/zoneinfo/America/Havana | Bin 0 -> 2411 bytes .../packages/pytz/zoneinfo/America/Hermosillo | Bin 0 -> 440 bytes .../zoneinfo/America/Indiana/Indianapolis | Bin 0 -> 1649 bytes .../pytz/zoneinfo/America/Indiana/Knox | Bin 0 -> 2411 bytes .../pytz/zoneinfo/America/Indiana/Marengo | Bin 0 -> 1705 bytes .../pytz/zoneinfo/America/Indiana/Petersburg | Bin 0 -> 1887 bytes .../pytz/zoneinfo/America/Indiana/Tell_City | Bin 0 -> 1709 bytes .../pytz/zoneinfo/America/Indiana/Vevay | Bin 0 -> 1397 bytes .../pytz/zoneinfo/America/Indiana/Vincennes | Bin 0 -> 1677 bytes .../pytz/zoneinfo/America/Indiana/Winamac | Bin 0 -> 1761 bytes .../pytz/zoneinfo/America/Indianapolis | Bin 0 -> 1649 bytes .../packages/pytz/zoneinfo/America/Inuvik | Bin 0 -> 1914 bytes .../packages/pytz/zoneinfo/America/Iqaluit | Bin 0 -> 2032 bytes .../packages/pytz/zoneinfo/America/Jamaica | Bin 0 -> 481 bytes .../packages/pytz/zoneinfo/America/Jujuy | Bin 0 -> 1119 bytes .../packages/pytz/zoneinfo/America/Juneau | Bin 0 -> 2336 bytes .../pytz/zoneinfo/America/Kentucky/Louisville | Bin 0 -> 2755 bytes .../pytz/zoneinfo/America/Kentucky/Monticello | Bin 0 -> 2335 bytes .../packages/pytz/zoneinfo/America/Knox_IN | Bin 0 -> 2411 bytes .../packages/pytz/zoneinfo/America/Kralendijk | Bin 0 -> 194 bytes .../packages/pytz/zoneinfo/America/La_Paz | Bin 0 -> 217 bytes .../packages/pytz/zoneinfo/America/Lima | Bin 0 -> 395 bytes .../pytz/zoneinfo/America/Los_Angeles | Bin 0 -> 2819 bytes .../packages/pytz/zoneinfo/America/Louisville | Bin 0 -> 2755 bytes .../pytz/zoneinfo/America/Lower_Princes | Bin 0 -> 194 bytes .../packages/pytz/zoneinfo/America/Maceio | Bin 0 -> 742 bytes .../packages/pytz/zoneinfo/America/Managua | Bin 0 -> 437 bytes .../packages/pytz/zoneinfo/America/Manaus | Bin 0 -> 602 bytes .../packages/pytz/zoneinfo/America/Marigot | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Martinique | Bin 0 -> 231 bytes .../packages/pytz/zoneinfo/America/Matamoros | Bin 0 -> 1402 bytes .../packages/pytz/zoneinfo/America/Mazatlan | Bin 0 -> 1550 bytes .../packages/pytz/zoneinfo/America/Mendoza | Bin 0 -> 1147 bytes .../packages/pytz/zoneinfo/America/Menominee | Bin 0 -> 2257 bytes .../packages/pytz/zoneinfo/America/Merida | Bin 0 -> 1442 bytes .../packages/pytz/zoneinfo/America/Metlakatla | Bin 0 -> 717 bytes .../pytz/zoneinfo/America/Mexico_City | Bin 0 -> 1604 bytes .../packages/pytz/zoneinfo/America/Miquelon | Bin 0 -> 1670 bytes .../packages/pytz/zoneinfo/America/Moncton | Bin 0 -> 3137 bytes .../packages/pytz/zoneinfo/America/Monterrey | Bin 0 -> 1402 bytes .../packages/pytz/zoneinfo/America/Montevideo | Bin 0 -> 2134 bytes .../packages/pytz/zoneinfo/America/Montreal | Bin 0 -> 3477 bytes .../packages/pytz/zoneinfo/America/Montserrat | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Nassau | Bin 0 -> 2270 bytes .../packages/pytz/zoneinfo/America/New_York | Bin 0 -> 3519 bytes .../packages/pytz/zoneinfo/America/Nipigon | Bin 0 -> 2105 bytes .../packages/pytz/zoneinfo/America/Nome | Bin 0 -> 2350 bytes .../packages/pytz/zoneinfo/America/Noronha | Bin 0 -> 714 bytes .../pytz/zoneinfo/America/North_Dakota/Beulah | Bin 0 -> 2363 bytes .../pytz/zoneinfo/America/North_Dakota/Center | Bin 0 -> 2363 bytes .../zoneinfo/America/North_Dakota/New_Salem | Bin 0 -> 2363 bytes .../packages/pytz/zoneinfo/America/Ojinaga | Bin 0 -> 1508 bytes .../packages/pytz/zoneinfo/America/Panama | Bin 0 -> 177 bytes .../pytz/zoneinfo/America/Pangnirtung | Bin 0 -> 2094 bytes .../packages/pytz/zoneinfo/America/Paramaribo | Bin 0 -> 294 bytes .../packages/pytz/zoneinfo/America/Phoenix | Bin 0 -> 327 bytes .../pytz/zoneinfo/America/Port-au-Prince | Bin 0 -> 1457 bytes .../pytz/zoneinfo/America/Port_of_Spain | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Porto_Acre | Bin 0 -> 612 bytes .../pytz/zoneinfo/America/Porto_Velho | Bin 0 -> 574 bytes .../pytz/zoneinfo/America/Puerto_Rico | Bin 0 -> 229 bytes .../pytz/zoneinfo/America/Rainy_River | Bin 0 -> 2105 bytes .../pytz/zoneinfo/America/Rankin_Inlet | Bin 0 -> 1916 bytes .../packages/pytz/zoneinfo/America/Recife | Bin 0 -> 714 bytes .../packages/pytz/zoneinfo/America/Regina | Bin 0 -> 980 bytes .../packages/pytz/zoneinfo/America/Resolute | Bin 0 -> 1916 bytes .../packages/pytz/zoneinfo/America/Rio_Branco | Bin 0 -> 612 bytes .../packages/pytz/zoneinfo/America/Rosario | Bin 0 -> 1103 bytes .../pytz/zoneinfo/America/Santa_Isabel | Bin 0 -> 2342 bytes .../packages/pytz/zoneinfo/America/Santarem | Bin 0 -> 612 bytes .../packages/pytz/zoneinfo/America/Santiago | Bin 0 -> 9227 bytes .../pytz/zoneinfo/America/Santo_Domingo | Bin 0 -> 463 bytes .../packages/pytz/zoneinfo/America/Sao_Paulo | Bin 0 -> 2001 bytes .../pytz/zoneinfo/America/Scoresbysund | Bin 0 -> 1911 bytes .../packages/pytz/zoneinfo/America/Shiprock | Bin 0 -> 2427 bytes .../packages/pytz/zoneinfo/America/Sitka | Bin 0 -> 2324 bytes .../pytz/zoneinfo/America/St_Barthelemy | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/St_Johns | Bin 0 -> 3638 bytes .../packages/pytz/zoneinfo/America/St_Kitts | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/St_Lucia | Bin 0 -> 177 bytes .../packages/pytz/zoneinfo/America/St_Thomas | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/St_Vincent | Bin 0 -> 177 bytes .../pytz/zoneinfo/America/Swift_Current | Bin 0 -> 560 bytes .../pytz/zoneinfo/America/Tegucigalpa | Bin 0 -> 264 bytes .../packages/pytz/zoneinfo/America/Thule | Bin 0 -> 1514 bytes .../pytz/zoneinfo/America/Thunder_Bay | Bin 0 -> 2185 bytes .../packages/pytz/zoneinfo/America/Tijuana | Bin 0 -> 2342 bytes .../packages/pytz/zoneinfo/America/Toronto | Bin 0 -> 3477 bytes .../packages/pytz/zoneinfo/America/Tortola | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Vancouver | Bin 0 -> 2875 bytes .../packages/pytz/zoneinfo/America/Virgin | Bin 0 -> 156 bytes .../packages/pytz/zoneinfo/America/Whitehorse | Bin 0 -> 2067 bytes .../packages/pytz/zoneinfo/America/Winnipeg | Bin 0 -> 2865 bytes .../packages/pytz/zoneinfo/America/Yakutat | Bin 0 -> 2288 bytes .../pytz/zoneinfo/America/Yellowknife | Bin 0 -> 1966 bytes .../packages/pytz/zoneinfo/Antarctica/Casey | Bin 0 -> 255 bytes .../packages/pytz/zoneinfo/Antarctica/Davis | Bin 0 -> 276 bytes .../pytz/zoneinfo/Antarctica/DumontDUrville | Bin 0 -> 213 bytes .../pytz/zoneinfo/Antarctica/Macquarie | Bin 0 -> 1496 bytes .../packages/pytz/zoneinfo/Antarctica/Mawson | Bin 0 -> 190 bytes .../packages/pytz/zoneinfo/Antarctica/McMurdo | Bin 0 -> 2001 bytes .../packages/pytz/zoneinfo/Antarctica/Palmer | Bin 0 -> 8762 bytes .../packages/pytz/zoneinfo/Antarctica/Rothera | Bin 0 -> 159 bytes .../pytz/zoneinfo/Antarctica/South_Pole | Bin 0 -> 2001 bytes .../packages/pytz/zoneinfo/Antarctica/Syowa | Bin 0 -> 160 bytes .../packages/pytz/zoneinfo/Antarctica/Vostok | Bin 0 -> 160 bytes .../pytz/zoneinfo/Arctic/Longyearbyen | Bin 0 -> 2225 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Aden | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Asia/Almaty | Bin 0 -> 922 bytes .../packages/pytz/zoneinfo/Asia/Amman | Bin 0 -> 1863 bytes .../packages/pytz/zoneinfo/Asia/Anadyr | Bin 0 -> 1183 bytes .../packages/pytz/zoneinfo/Asia/Aqtau | Bin 0 -> 1128 bytes .../packages/pytz/zoneinfo/Asia/Aqtobe | Bin 0 -> 1038 bytes .../packages/pytz/zoneinfo/Asia/Ashgabat | Bin 0 -> 657 bytes .../packages/pytz/zoneinfo/Asia/Ashkhabad | Bin 0 -> 657 bytes .../packages/pytz/zoneinfo/Asia/Baghdad | Bin 0 -> 962 bytes .../packages/pytz/zoneinfo/Asia/Bahrain | Bin 0 -> 195 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Baku | Bin 0 -> 1942 bytes .../packages/pytz/zoneinfo/Asia/Bangkok | Bin 0 -> 178 bytes .../packages/pytz/zoneinfo/Asia/Beirut | Bin 0 -> 2149 bytes .../packages/pytz/zoneinfo/Asia/Bishkek | Bin 0 -> 1047 bytes .../packages/pytz/zoneinfo/Asia/Brunei | Bin 0 -> 187 bytes .../packages/pytz/zoneinfo/Asia/Calcutta | Bin 0 -> 265 bytes .../packages/pytz/zoneinfo/Asia/Choibalsan | Bin 0 -> 890 bytes .../packages/pytz/zoneinfo/Asia/Chongqing | Bin 0 -> 389 bytes .../packages/pytz/zoneinfo/Asia/Chungking | Bin 0 -> 389 bytes .../packages/pytz/zoneinfo/Asia/Colombo | Bin 0 -> 363 bytes .../packages/pytz/zoneinfo/Asia/Dacca | Bin 0 -> 364 bytes .../packages/pytz/zoneinfo/Asia/Damascus | Bin 0 -> 2306 bytes .../packages/pytz/zoneinfo/Asia/Dhaka | Bin 0 -> 364 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Dili | Bin 0 -> 293 bytes .../packages/pytz/zoneinfo/Asia/Dubai | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Asia/Dushanbe | Bin 0 -> 597 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Gaza | Bin 0 -> 9025 bytes .../packages/pytz/zoneinfo/Asia/Harbin | Bin 0 -> 463 bytes .../packages/pytz/zoneinfo/Asia/Hebron | Bin 0 -> 9053 bytes .../packages/pytz/zoneinfo/Asia/Ho_Chi_Minh | Bin 0 -> 255 bytes .../packages/pytz/zoneinfo/Asia/Hong_Kong | Bin 0 -> 1175 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Hovd | Bin 0 -> 834 bytes .../packages/pytz/zoneinfo/Asia/Irkutsk | Bin 0 -> 1203 bytes .../packages/pytz/zoneinfo/Asia/Istanbul | Bin 0 -> 2721 bytes .../packages/pytz/zoneinfo/Asia/Jakarta | Bin 0 -> 344 bytes .../packages/pytz/zoneinfo/Asia/Jayapura | Bin 0 -> 225 bytes .../packages/pytz/zoneinfo/Asia/Jerusalem | Bin 0 -> 8981 bytes .../packages/pytz/zoneinfo/Asia/Kabul | Bin 0 -> 173 bytes .../packages/pytz/zoneinfo/Asia/Kamchatka | Bin 0 -> 1167 bytes .../packages/pytz/zoneinfo/Asia/Karachi | Bin 0 -> 389 bytes .../packages/pytz/zoneinfo/Asia/Kashgar | Bin 0 -> 419 bytes .../packages/pytz/zoneinfo/Asia/Kathmandu | Bin 0 -> 198 bytes .../packages/pytz/zoneinfo/Asia/Katmandu | Bin 0 -> 198 bytes .../packages/pytz/zoneinfo/Asia/Khandyga | Bin 0 -> 1281 bytes .../packages/pytz/zoneinfo/Asia/Kolkata | Bin 0 -> 265 bytes .../packages/pytz/zoneinfo/Asia/Krasnoyarsk | Bin 0 -> 1182 bytes .../packages/pytz/zoneinfo/Asia/Kuala_Lumpur | Bin 0 -> 372 bytes .../packages/pytz/zoneinfo/Asia/Kuching | Bin 0 -> 505 bytes .../packages/pytz/zoneinfo/Asia/Kuwait | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Asia/Macao | Bin 0 -> 781 bytes .../packages/pytz/zoneinfo/Asia/Macau | Bin 0 -> 781 bytes .../packages/pytz/zoneinfo/Asia/Magadan | Bin 0 -> 1183 bytes .../packages/pytz/zoneinfo/Asia/Makassar | Bin 0 -> 263 bytes .../packages/pytz/zoneinfo/Asia/Manila | Bin 0 -> 335 bytes .../packages/pytz/zoneinfo/Asia/Muscat | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Asia/Nicosia | Bin 0 -> 2002 bytes .../packages/pytz/zoneinfo/Asia/Novokuznetsk | Bin 0 -> 1220 bytes .../packages/pytz/zoneinfo/Asia/Novosibirsk | Bin 0 -> 1196 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Omsk | Bin 0 -> 1182 bytes .../wakatime/packages/pytz/zoneinfo/Asia/Oral | Bin 0 -> 1086 bytes .../packages/pytz/zoneinfo/Asia/Phnom_Penh | Bin 0 -> 255 bytes .../packages/pytz/zoneinfo/Asia/Pontianak | Bin 0 -> 359 bytes .../packages/pytz/zoneinfo/Asia/Pyongyang | Bin 0 -> 258 bytes .../packages/pytz/zoneinfo/Asia/Qatar | Bin 0 -> 195 bytes .../packages/pytz/zoneinfo/Asia/Qyzylorda | Bin 0 -> 1068 bytes .../packages/pytz/zoneinfo/Asia/Rangoon | Bin 0 -> 259 bytes .../packages/pytz/zoneinfo/Asia/Riyadh | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Asia/Riyadh87 | Bin 0 -> 8685 bytes .../packages/pytz/zoneinfo/Asia/Riyadh88 | Bin 0 -> 8539 bytes .../packages/pytz/zoneinfo/Asia/Riyadh89 | Bin 0 -> 8539 bytes .../packages/pytz/zoneinfo/Asia/Saigon | Bin 0 -> 255 bytes .../packages/pytz/zoneinfo/Asia/Sakhalin | Bin 0 -> 1213 bytes .../packages/pytz/zoneinfo/Asia/Samarkand | Bin 0 -> 677 bytes .../packages/pytz/zoneinfo/Asia/Seoul | Bin 0 -> 396 bytes .../packages/pytz/zoneinfo/Asia/Shanghai | Bin 0 -> 405 bytes .../packages/pytz/zoneinfo/Asia/Singapore | Bin 0 -> 402 bytes .../packages/pytz/zoneinfo/Asia/Taipei | Bin 0 -> 724 bytes .../packages/pytz/zoneinfo/Asia/Tashkent | Bin 0 -> 667 bytes .../packages/pytz/zoneinfo/Asia/Tbilisi | Bin 0 -> 1116 bytes .../packages/pytz/zoneinfo/Asia/Tehran | Bin 0 -> 1638 bytes .../packages/pytz/zoneinfo/Asia/Tel_Aviv | Bin 0 -> 8981 bytes .../packages/pytz/zoneinfo/Asia/Thimbu | Bin 0 -> 195 bytes .../packages/pytz/zoneinfo/Asia/Thimphu | Bin 0 -> 195 bytes .../packages/pytz/zoneinfo/Asia/Tokyo | Bin 0 -> 331 bytes .../packages/pytz/zoneinfo/Asia/Ujung_Pandang | Bin 0 -> 263 bytes .../packages/pytz/zoneinfo/Asia/Ulaanbaatar | Bin 0 -> 834 bytes .../packages/pytz/zoneinfo/Asia/Ulan_Bator | Bin 0 -> 834 bytes .../packages/pytz/zoneinfo/Asia/Urumqi | Bin 0 -> 389 bytes .../packages/pytz/zoneinfo/Asia/Ust-Nera | Bin 0 -> 1249 bytes .../packages/pytz/zoneinfo/Asia/Vientiane | Bin 0 -> 255 bytes .../packages/pytz/zoneinfo/Asia/Vladivostok | Bin 0 -> 1197 bytes .../packages/pytz/zoneinfo/Asia/Yakutsk | Bin 0 -> 1183 bytes .../packages/pytz/zoneinfo/Asia/Yekaterinburg | Bin 0 -> 1252 bytes .../packages/pytz/zoneinfo/Asia/Yerevan | Bin 0 -> 1263 bytes .../packages/pytz/zoneinfo/Atlantic/Azores | Bin 0 -> 3462 bytes .../packages/pytz/zoneinfo/Atlantic/Bermuda | Bin 0 -> 1990 bytes .../packages/pytz/zoneinfo/Atlantic/Canary | Bin 0 -> 1899 bytes .../pytz/zoneinfo/Atlantic/Cape_Verde | Bin 0 -> 240 bytes .../packages/pytz/zoneinfo/Atlantic/Faeroe | Bin 0 -> 1815 bytes .../packages/pytz/zoneinfo/Atlantic/Faroe | Bin 0 -> 1815 bytes .../packages/pytz/zoneinfo/Atlantic/Jan_Mayen | Bin 0 -> 2225 bytes .../packages/pytz/zoneinfo/Atlantic/Madeira | Bin 0 -> 3452 bytes .../packages/pytz/zoneinfo/Atlantic/Reykjavik | Bin 0 -> 1141 bytes .../pytz/zoneinfo/Atlantic/South_Georgia | Bin 0 -> 139 bytes .../packages/pytz/zoneinfo/Atlantic/St_Helena | Bin 0 -> 177 bytes .../packages/pytz/zoneinfo/Atlantic/Stanley | Bin 0 -> 1220 bytes .../packages/pytz/zoneinfo/Australia/ACT | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/Adelaide | Bin 0 -> 2202 bytes .../packages/pytz/zoneinfo/Australia/Brisbane | Bin 0 -> 413 bytes .../pytz/zoneinfo/Australia/Broken_Hill | Bin 0 -> 2237 bytes .../packages/pytz/zoneinfo/Australia/Canberra | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/Currie | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/Darwin | Bin 0 -> 288 bytes .../packages/pytz/zoneinfo/Australia/Eucla | Bin 0 -> 446 bytes .../packages/pytz/zoneinfo/Australia/Hobart | Bin 0 -> 2295 bytes .../packages/pytz/zoneinfo/Australia/LHI | Bin 0 -> 1821 bytes .../packages/pytz/zoneinfo/Australia/Lindeman | Bin 0 -> 483 bytes .../pytz/zoneinfo/Australia/Lord_Howe | Bin 0 -> 1821 bytes .../pytz/zoneinfo/Australia/Melbourne | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/NSW | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/North | Bin 0 -> 288 bytes .../packages/pytz/zoneinfo/Australia/Perth | Bin 0 -> 440 bytes .../pytz/zoneinfo/Australia/Queensland | Bin 0 -> 413 bytes .../packages/pytz/zoneinfo/Australia/South | Bin 0 -> 2202 bytes .../packages/pytz/zoneinfo/Australia/Sydney | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/Tasmania | Bin 0 -> 2295 bytes .../packages/pytz/zoneinfo/Australia/Victoria | Bin 0 -> 2183 bytes .../packages/pytz/zoneinfo/Australia/West | Bin 0 -> 440 bytes .../pytz/zoneinfo/Australia/Yancowinna | Bin 0 -> 2237 bytes .../packages/pytz/zoneinfo/Brazil/Acre | Bin 0 -> 612 bytes .../packages/pytz/zoneinfo/Brazil/DeNoronha | Bin 0 -> 714 bytes .../packages/pytz/zoneinfo/Brazil/East | Bin 0 -> 2001 bytes .../packages/pytz/zoneinfo/Brazil/West | Bin 0 -> 602 bytes .../wakatime/packages/pytz/zoneinfo/CET | Bin 0 -> 2102 bytes .../wakatime/packages/pytz/zoneinfo/CST6CDT | Bin 0 -> 2294 bytes .../packages/pytz/zoneinfo/Canada/Atlantic | Bin 0 -> 3424 bytes .../packages/pytz/zoneinfo/Canada/Central | Bin 0 -> 2865 bytes .../pytz/zoneinfo/Canada/East-Saskatchewan | Bin 0 -> 980 bytes .../packages/pytz/zoneinfo/Canada/Eastern | Bin 0 -> 3477 bytes .../packages/pytz/zoneinfo/Canada/Mountain | Bin 0 -> 2388 bytes .../pytz/zoneinfo/Canada/Newfoundland | Bin 0 -> 3638 bytes .../packages/pytz/zoneinfo/Canada/Pacific | Bin 0 -> 2875 bytes .../pytz/zoneinfo/Canada/Saskatchewan | Bin 0 -> 980 bytes .../packages/pytz/zoneinfo/Canada/Yukon | Bin 0 -> 2067 bytes .../packages/pytz/zoneinfo/Chile/Continental | Bin 0 -> 9227 bytes .../packages/pytz/zoneinfo/Chile/EasterIsland | Bin 0 -> 8989 bytes .../wakatime/packages/pytz/zoneinfo/Cuba | Bin 0 -> 2411 bytes .../wakatime/packages/pytz/zoneinfo/EET | Bin 0 -> 1876 bytes .../wakatime/packages/pytz/zoneinfo/EST | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/EST5EDT | Bin 0 -> 2294 bytes .../wakatime/packages/pytz/zoneinfo/Egypt | Bin 0 -> 1906 bytes .../wakatime/packages/pytz/zoneinfo/Eire | Bin 0 -> 3533 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+0 | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+1 | Bin 0 -> 126 bytes .../packages/pytz/zoneinfo/Etc/GMT+10 | Bin 0 -> 130 bytes .../packages/pytz/zoneinfo/Etc/GMT+11 | Bin 0 -> 130 bytes .../packages/pytz/zoneinfo/Etc/GMT+12 | Bin 0 -> 130 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+2 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+3 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+4 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+5 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+6 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+7 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+8 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT+9 | Bin 0 -> 126 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-0 | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-1 | Bin 0 -> 127 bytes .../packages/pytz/zoneinfo/Etc/GMT-10 | Bin 0 -> 131 bytes .../packages/pytz/zoneinfo/Etc/GMT-11 | Bin 0 -> 131 bytes .../packages/pytz/zoneinfo/Etc/GMT-12 | Bin 0 -> 131 bytes .../packages/pytz/zoneinfo/Etc/GMT-13 | Bin 0 -> 131 bytes .../packages/pytz/zoneinfo/Etc/GMT-14 | Bin 0 -> 131 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-2 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-3 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-4 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-5 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-6 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-7 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-8 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT-9 | Bin 0 -> 127 bytes .../wakatime/packages/pytz/zoneinfo/Etc/GMT0 | Bin 0 -> 118 bytes .../packages/pytz/zoneinfo/Etc/Greenwich | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Etc/UCT | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Etc/UTC | Bin 0 -> 118 bytes .../packages/pytz/zoneinfo/Etc/Universal | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Etc/Zulu | Bin 0 -> 118 bytes .../packages/pytz/zoneinfo/Europe/Amsterdam | Bin 0 -> 2917 bytes .../packages/pytz/zoneinfo/Europe/Andorra | Bin 0 -> 1725 bytes .../packages/pytz/zoneinfo/Europe/Athens | Bin 0 -> 2245 bytes .../packages/pytz/zoneinfo/Europe/Belfast | Bin 0 -> 3661 bytes .../packages/pytz/zoneinfo/Europe/Belgrade | Bin 0 -> 1931 bytes .../packages/pytz/zoneinfo/Europe/Berlin | Bin 0 -> 2309 bytes .../packages/pytz/zoneinfo/Europe/Bratislava | Bin 0 -> 2246 bytes .../packages/pytz/zoneinfo/Europe/Brussels | Bin 0 -> 2944 bytes .../packages/pytz/zoneinfo/Europe/Bucharest | Bin 0 -> 2195 bytes .../packages/pytz/zoneinfo/Europe/Budapest | Bin 0 -> 2407 bytes .../packages/pytz/zoneinfo/Europe/Busingen | Bin 0 -> 1892 bytes .../packages/pytz/zoneinfo/Europe/Chisinau | Bin 0 -> 2407 bytes .../packages/pytz/zoneinfo/Europe/Copenhagen | Bin 0 -> 2134 bytes .../packages/pytz/zoneinfo/Europe/Dublin | Bin 0 -> 3533 bytes .../packages/pytz/zoneinfo/Europe/Gibraltar | Bin 0 -> 3035 bytes .../packages/pytz/zoneinfo/Europe/Guernsey | Bin 0 -> 3661 bytes .../packages/pytz/zoneinfo/Europe/Helsinki | Bin 0 -> 1883 bytes .../packages/pytz/zoneinfo/Europe/Isle_of_Man | Bin 0 -> 3661 bytes .../packages/pytz/zoneinfo/Europe/Istanbul | Bin 0 -> 2721 bytes .../packages/pytz/zoneinfo/Europe/Jersey | Bin 0 -> 3661 bytes .../packages/pytz/zoneinfo/Europe/Kaliningrad | Bin 0 -> 1494 bytes .../packages/pytz/zoneinfo/Europe/Kiev | Bin 0 -> 2057 bytes .../packages/pytz/zoneinfo/Europe/Lisbon | Bin 0 -> 3439 bytes .../packages/pytz/zoneinfo/Europe/Ljubljana | Bin 0 -> 1931 bytes .../packages/pytz/zoneinfo/Europe/London | Bin 0 -> 3661 bytes .../packages/pytz/zoneinfo/Europe/Luxembourg | Bin 0 -> 2960 bytes .../packages/pytz/zoneinfo/Europe/Madrid | Bin 0 -> 2593 bytes .../packages/pytz/zoneinfo/Europe/Malta | Bin 0 -> 2603 bytes .../packages/pytz/zoneinfo/Europe/Mariehamn | Bin 0 -> 1883 bytes .../packages/pytz/zoneinfo/Europe/Minsk | Bin 0 -> 1328 bytes .../packages/pytz/zoneinfo/Europe/Monaco | Bin 0 -> 2927 bytes .../packages/pytz/zoneinfo/Europe/Moscow | Bin 0 -> 1464 bytes .../packages/pytz/zoneinfo/Europe/Nicosia | Bin 0 -> 2002 bytes .../packages/pytz/zoneinfo/Europe/Oslo | Bin 0 -> 2225 bytes .../packages/pytz/zoneinfo/Europe/Paris | Bin 0 -> 2945 bytes .../packages/pytz/zoneinfo/Europe/Podgorica | Bin 0 -> 1931 bytes .../packages/pytz/zoneinfo/Europe/Prague | Bin 0 -> 2246 bytes .../packages/pytz/zoneinfo/Europe/Riga | Bin 0 -> 2209 bytes .../packages/pytz/zoneinfo/Europe/Rome | Bin 0 -> 2652 bytes .../packages/pytz/zoneinfo/Europe/Samara | Bin 0 -> 1330 bytes .../packages/pytz/zoneinfo/Europe/San_Marino | Bin 0 -> 2652 bytes .../packages/pytz/zoneinfo/Europe/Sarajevo | Bin 0 -> 1931 bytes .../packages/pytz/zoneinfo/Europe/Simferopol | Bin 0 -> 2113 bytes .../packages/pytz/zoneinfo/Europe/Skopje | Bin 0 -> 1931 bytes .../packages/pytz/zoneinfo/Europe/Sofia | Bin 0 -> 2104 bytes .../packages/pytz/zoneinfo/Europe/Stockholm | Bin 0 -> 1892 bytes .../packages/pytz/zoneinfo/Europe/Tallinn | Bin 0 -> 2175 bytes .../packages/pytz/zoneinfo/Europe/Tirane | Bin 0 -> 2084 bytes .../packages/pytz/zoneinfo/Europe/Tiraspol | Bin 0 -> 2407 bytes .../packages/pytz/zoneinfo/Europe/Uzhgorod | Bin 0 -> 2077 bytes .../packages/pytz/zoneinfo/Europe/Vaduz | Bin 0 -> 1799 bytes .../packages/pytz/zoneinfo/Europe/Vatican | Bin 0 -> 2652 bytes .../packages/pytz/zoneinfo/Europe/Vienna | Bin 0 -> 2211 bytes .../packages/pytz/zoneinfo/Europe/Vilnius | Bin 0 -> 2173 bytes .../packages/pytz/zoneinfo/Europe/Volgograd | Bin 0 -> 1234 bytes .../packages/pytz/zoneinfo/Europe/Warsaw | Bin 0 -> 2679 bytes .../packages/pytz/zoneinfo/Europe/Zagreb | Bin 0 -> 1931 bytes .../packages/pytz/zoneinfo/Europe/Zaporozhye | Bin 0 -> 2085 bytes .../packages/pytz/zoneinfo/Europe/Zurich | Bin 0 -> 1892 bytes .../wakatime/packages/pytz/zoneinfo/Factory | Bin 0 -> 255 bytes .../wakatime/packages/pytz/zoneinfo/GB | Bin 0 -> 3661 bytes .../wakatime/packages/pytz/zoneinfo/GB-Eire | Bin 0 -> 3661 bytes .../wakatime/packages/pytz/zoneinfo/GMT | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/GMT+0 | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/GMT-0 | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/GMT0 | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Greenwich | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/HST | Bin 0 -> 119 bytes .../wakatime/packages/pytz/zoneinfo/Hongkong | Bin 0 -> 1175 bytes .../wakatime/packages/pytz/zoneinfo/Iceland | Bin 0 -> 1141 bytes .../pytz/zoneinfo/Indian/Antananarivo | Bin 0 -> 227 bytes .../packages/pytz/zoneinfo/Indian/Chagos | Bin 0 -> 187 bytes .../packages/pytz/zoneinfo/Indian/Christmas | Bin 0 -> 140 bytes .../packages/pytz/zoneinfo/Indian/Cocos | Bin 0 -> 143 bytes .../packages/pytz/zoneinfo/Indian/Comoro | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Indian/Kerguelen | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Indian/Mahe | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Indian/Maldives | Bin 0 -> 178 bytes .../packages/pytz/zoneinfo/Indian/Mauritius | Bin 0 -> 239 bytes .../packages/pytz/zoneinfo/Indian/Mayotte | Bin 0 -> 157 bytes .../packages/pytz/zoneinfo/Indian/Reunion | Bin 0 -> 157 bytes .../wakatime/packages/pytz/zoneinfo/Iran | Bin 0 -> 1638 bytes .../wakatime/packages/pytz/zoneinfo/Israel | Bin 0 -> 8981 bytes .../wakatime/packages/pytz/zoneinfo/Jamaica | Bin 0 -> 481 bytes .../wakatime/packages/pytz/zoneinfo/Japan | Bin 0 -> 331 bytes .../wakatime/packages/pytz/zoneinfo/Kwajalein | Bin 0 -> 211 bytes .../wakatime/packages/pytz/zoneinfo/Libya | Bin 0 -> 1350 bytes .../wakatime/packages/pytz/zoneinfo/MET | Bin 0 -> 2102 bytes .../wakatime/packages/pytz/zoneinfo/MST | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/MST7MDT | Bin 0 -> 2294 bytes .../packages/pytz/zoneinfo/Mexico/BajaNorte | Bin 0 -> 2342 bytes .../packages/pytz/zoneinfo/Mexico/BajaSur | Bin 0 -> 1550 bytes .../packages/pytz/zoneinfo/Mexico/General | Bin 0 -> 1604 bytes .../packages/pytz/zoneinfo/Mideast/Riyadh87 | Bin 0 -> 8685 bytes .../packages/pytz/zoneinfo/Mideast/Riyadh88 | Bin 0 -> 8539 bytes .../packages/pytz/zoneinfo/Mideast/Riyadh89 | Bin 0 -> 8539 bytes .../wakatime/packages/pytz/zoneinfo/NZ | Bin 0 -> 2434 bytes .../wakatime/packages/pytz/zoneinfo/NZ-CHAT | Bin 0 -> 2018 bytes .../wakatime/packages/pytz/zoneinfo/Navajo | Bin 0 -> 2427 bytes .../wakatime/packages/pytz/zoneinfo/PRC | Bin 0 -> 405 bytes .../wakatime/packages/pytz/zoneinfo/PST8PDT | Bin 0 -> 2294 bytes .../packages/pytz/zoneinfo/Pacific/Apia | Bin 0 -> 1079 bytes .../packages/pytz/zoneinfo/Pacific/Auckland | Bin 0 -> 2434 bytes .../packages/pytz/zoneinfo/Pacific/Chatham | Bin 0 -> 2018 bytes .../packages/pytz/zoneinfo/Pacific/Chuuk | Bin 0 -> 144 bytes .../packages/pytz/zoneinfo/Pacific/Easter | Bin 0 -> 8989 bytes .../packages/pytz/zoneinfo/Pacific/Efate | Bin 0 -> 464 bytes .../packages/pytz/zoneinfo/Pacific/Enderbury | Bin 0 -> 204 bytes .../packages/pytz/zoneinfo/Pacific/Fakaofo | Bin 0 -> 171 bytes .../packages/pytz/zoneinfo/Pacific/Fiji | Bin 0 -> 7782 bytes .../packages/pytz/zoneinfo/Pacific/Funafuti | Bin 0 -> 141 bytes .../packages/pytz/zoneinfo/Pacific/Galapagos | Bin 0 -> 197 bytes .../packages/pytz/zoneinfo/Pacific/Gambier | Bin 0 -> 159 bytes .../pytz/zoneinfo/Pacific/Guadalcanal | Bin 0 -> 158 bytes .../packages/pytz/zoneinfo/Pacific/Guam | Bin 0 -> 199 bytes .../packages/pytz/zoneinfo/Pacific/Honolulu | Bin 0 -> 250 bytes .../packages/pytz/zoneinfo/Pacific/Johnston | Bin 0 -> 119 bytes .../packages/pytz/zoneinfo/Pacific/Kiritimati | Bin 0 -> 204 bytes .../packages/pytz/zoneinfo/Pacific/Kosrae | Bin 0 -> 204 bytes .../packages/pytz/zoneinfo/Pacific/Kwajalein | Bin 0 -> 211 bytes .../packages/pytz/zoneinfo/Pacific/Majuro | Bin 0 -> 171 bytes .../packages/pytz/zoneinfo/Pacific/Marquesas | Bin 0 -> 162 bytes .../packages/pytz/zoneinfo/Pacific/Midway | Bin 0 -> 268 bytes .../packages/pytz/zoneinfo/Pacific/Nauru | Bin 0 -> 240 bytes .../packages/pytz/zoneinfo/Pacific/Niue | Bin 0 -> 200 bytes .../packages/pytz/zoneinfo/Pacific/Norfolk | Bin 0 -> 182 bytes .../packages/pytz/zoneinfo/Pacific/Noumea | Bin 0 -> 300 bytes .../packages/pytz/zoneinfo/Pacific/Pago_Pago | Bin 0 -> 290 bytes .../packages/pytz/zoneinfo/Pacific/Palau | Bin 0 -> 140 bytes .../packages/pytz/zoneinfo/Pacific/Pitcairn | Bin 0 -> 177 bytes .../packages/pytz/zoneinfo/Pacific/Pohnpei | Bin 0 -> 144 bytes .../packages/pytz/zoneinfo/Pacific/Ponape | Bin 0 -> 144 bytes .../pytz/zoneinfo/Pacific/Port_Moresby | Bin 0 -> 163 bytes .../packages/pytz/zoneinfo/Pacific/Rarotonga | Bin 0 -> 548 bytes .../packages/pytz/zoneinfo/Pacific/Saipan | Bin 0 -> 229 bytes .../packages/pytz/zoneinfo/Pacific/Samoa | Bin 0 -> 290 bytes .../packages/pytz/zoneinfo/Pacific/Tahiti | Bin 0 -> 160 bytes .../packages/pytz/zoneinfo/Pacific/Tarawa | Bin 0 -> 144 bytes .../packages/pytz/zoneinfo/Pacific/Tongatapu | Bin 0 -> 313 bytes .../packages/pytz/zoneinfo/Pacific/Truk | Bin 0 -> 144 bytes .../packages/pytz/zoneinfo/Pacific/Wake | Bin 0 -> 144 bytes .../packages/pytz/zoneinfo/Pacific/Wallis | Bin 0 -> 141 bytes .../packages/pytz/zoneinfo/Pacific/Yap | Bin 0 -> 144 bytes .../wakatime/packages/pytz/zoneinfo/Poland | Bin 0 -> 2679 bytes .../wakatime/packages/pytz/zoneinfo/Portugal | Bin 0 -> 3439 bytes .../wakatime/packages/pytz/zoneinfo/ROC | Bin 0 -> 724 bytes .../wakatime/packages/pytz/zoneinfo/ROK | Bin 0 -> 396 bytes .../wakatime/packages/pytz/zoneinfo/Singapore | Bin 0 -> 402 bytes .../wakatime/packages/pytz/zoneinfo/Turkey | Bin 0 -> 2721 bytes .../wakatime/packages/pytz/zoneinfo/UCT | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/US/Alaska | Bin 0 -> 2358 bytes .../packages/pytz/zoneinfo/US/Aleutian | Bin 0 -> 2353 bytes .../packages/pytz/zoneinfo/US/Arizona | Bin 0 -> 327 bytes .../packages/pytz/zoneinfo/US/Central | Bin 0 -> 3559 bytes .../packages/pytz/zoneinfo/US/East-Indiana | Bin 0 -> 1649 bytes .../packages/pytz/zoneinfo/US/Eastern | Bin 0 -> 3519 bytes .../wakatime/packages/pytz/zoneinfo/US/Hawaii | Bin 0 -> 250 bytes .../packages/pytz/zoneinfo/US/Indiana-Starke | Bin 0 -> 2411 bytes .../packages/pytz/zoneinfo/US/Michigan | Bin 0 -> 2202 bytes .../packages/pytz/zoneinfo/US/Mountain | Bin 0 -> 2427 bytes .../packages/pytz/zoneinfo/US/Pacific | Bin 0 -> 2819 bytes .../packages/pytz/zoneinfo/US/Pacific-New | Bin 0 -> 2819 bytes .../wakatime/packages/pytz/zoneinfo/US/Samoa | Bin 0 -> 290 bytes .../wakatime/packages/pytz/zoneinfo/UTC | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/Universal | Bin 0 -> 118 bytes .../wakatime/packages/pytz/zoneinfo/W-SU | Bin 0 -> 1464 bytes .../wakatime/packages/pytz/zoneinfo/WET | Bin 0 -> 1873 bytes .../wakatime/packages/pytz/zoneinfo/Zulu | Bin 0 -> 118 bytes .../packages/pytz/zoneinfo/iso3166.tab | 275 + .../wakatime/packages/pytz/zoneinfo/localtime | Bin 0 -> 118 bytes .../packages/pytz/zoneinfo/posixrules | Bin 0 -> 3519 bytes .../wakatime/packages/pytz/zoneinfo/zone.tab | 451 ++ .../wakatime/packages/pytz3/__init__.py | 1512 +++++ .../wakatime/packages/pytz3/exceptions.py | 48 + .../packages/wakatime/packages/pytz3/lazy.py | 148 + .../wakatime/packages/pytz3/reference.py | 127 + .../packages/pytz3/tests/test_docs.py | 36 + .../packages/pytz3/tests/test_tzinfo.py | 813 +++ .../wakatime/packages/pytz3/tzfile.py | 137 + .../wakatime/packages/pytz3/tzinfo.py | 563 ++ .../wakatime/packages/requests/__init__.py | 77 + .../wakatime/packages/requests/adapters.py | 437 ++ .../wakatime/packages/requests/api.py | 146 + .../wakatime/packages/requests/auth.py | 211 + .../wakatime/packages/requests/cacert.pem | 5026 ++++++++++++++++ .../wakatime/packages/requests/certs.py | 25 + .../wakatime/packages/requests/compat.py | 62 + .../wakatime/packages/requests/cookies.py | 463 ++ .../wakatime/packages/requests/exceptions.py | 99 + .../wakatime/packages/requests/hooks.py | 45 + .../wakatime/packages/requests/models.py | 846 +++ .../packages/requests/packages/README.rst | 8 + .../packages/requests/packages/__init__.py | 107 + .../requests/packages/chardet/__init__.py | 32 + .../requests/packages/chardet/big5freq.py | 925 +++ .../requests/packages/chardet/big5prober.py | 42 + .../requests/packages/chardet/chardetect.py | 80 + .../packages/chardet/chardistribution.py | 231 + .../packages/chardet/charsetgroupprober.py | 106 + .../packages/chardet/charsetprober.py | 62 + .../packages/chardet/codingstatemachine.py | 61 + .../requests/packages/chardet/compat.py | 34 + .../requests/packages/chardet/constants.py | 39 + .../requests/packages/chardet/cp949prober.py | 44 + .../requests/packages/chardet/escprober.py | 86 + .../requests/packages/chardet/escsm.py | 242 + .../requests/packages/chardet/eucjpprober.py | 90 + .../requests/packages/chardet/euckrfreq.py | 596 ++ .../requests/packages/chardet/euckrprober.py | 42 + .../requests/packages/chardet/euctwfreq.py | 428 ++ .../requests/packages/chardet/euctwprober.py | 41 + .../requests/packages/chardet/gb2312freq.py | 472 ++ .../requests/packages/chardet/gb2312prober.py | 41 + .../requests/packages/chardet/hebrewprober.py | 283 + .../requests/packages/chardet/jisfreq.py | 569 ++ .../requests/packages/chardet/jpcntx.py | 227 + .../packages/chardet/langbulgarianmodel.py | 229 + .../packages/chardet/langcyrillicmodel.py | 329 ++ .../packages/chardet/langgreekmodel.py | 225 + .../packages/chardet/langhebrewmodel.py | 201 + .../packages/chardet/langhungarianmodel.py | 225 + .../packages/chardet/langthaimodel.py | 200 + .../requests/packages/chardet/latin1prober.py | 139 + .../packages/chardet/mbcharsetprober.py | 86 + .../packages/chardet/mbcsgroupprober.py | 54 + .../requests/packages/chardet/mbcssm.py | 572 ++ .../packages/chardet/sbcharsetprober.py | 120 + .../packages/chardet/sbcsgroupprober.py | 69 + .../requests/packages/chardet/sjisprober.py | 91 + .../packages/chardet/universaldetector.py | 170 + .../requests/packages/chardet/utf8prober.py | 76 + .../requests/packages/urllib3/__init__.py | 66 + .../requests/packages/urllib3/_collections.py | 320 + .../requests/packages/urllib3/connection.py | 262 + .../packages/urllib3/connectionpool.py | 796 +++ .../packages/urllib3/contrib/__init__.py | 0 .../packages/urllib3/contrib/ntlmpool.py | 114 + .../packages/urllib3/contrib/pyopenssl.py | 308 + .../requests/packages/urllib3/exceptions.py | 164 + .../requests/packages/urllib3/fields.py | 177 + .../requests/packages/urllib3/filepost.py | 93 + .../packages/urllib3/packages/__init__.py | 4 + .../packages/urllib3/packages/ordered_dict.py | 259 + .../requests/packages/urllib3/packages/six.py | 385 ++ .../packages/ssl_match_hostname/__init__.py | 13 + .../ssl_match_hostname/_implementation.py | 105 + .../requests/packages/urllib3/poolmanager.py | 280 + .../requests/packages/urllib3/request.py | 141 + .../requests/packages/urllib3/response.py | 353 ++ .../packages/urllib3/util/__init__.py | 24 + .../packages/urllib3/util/connection.py | 98 + .../requests/packages/urllib3/util/request.py | 71 + .../packages/urllib3/util/response.py | 22 + .../requests/packages/urllib3/util/retry.py | 285 + .../requests/packages/urllib3/util/ssl_.py | 266 + .../requests/packages/urllib3/util/timeout.py | 240 + .../requests/packages/urllib3/util/url.py | 212 + .../wakatime/packages/requests/sessions.py | 685 +++ .../packages/requests/status_codes.py | 89 + .../wakatime/packages/requests/structures.py | 104 + .../wakatime/packages/requests/utils.py | 707 +++ .../wakatime/packages/simplejson/__init__.py | 564 ++ .../wakatime/packages/simplejson/_speedups.c | 3340 +++++++++++ .../wakatime/packages/simplejson/compat.py | 46 + .../wakatime/packages/simplejson/decoder.py | 400 ++ .../wakatime/packages/simplejson/encoder.py | 648 +++ .../packages/simplejson/ordered_dict.py | 119 + .../wakatime/packages/simplejson/scanner.py | 133 + .../packages/simplejson/tests/__init__.py | 88 + .../simplejson/tests/test_bigint_as_string.py | 67 + .../tests/test_bitsize_int_as_string.py | 73 + .../simplejson/tests/test_check_circular.py | 30 + .../packages/simplejson/tests/test_decimal.py | 71 + .../packages/simplejson/tests/test_decode.py | 99 + .../packages/simplejson/tests/test_default.py | 9 + .../packages/simplejson/tests/test_dump.py | 130 + .../tests/test_encode_basestring_ascii.py | 47 + .../simplejson/tests/test_encode_for_html.py | 30 + .../packages/simplejson/tests/test_errors.py | 51 + .../packages/simplejson/tests/test_fail.py | 176 + .../packages/simplejson/tests/test_float.py | 35 + .../simplejson/tests/test_for_json.py | 97 + .../packages/simplejson/tests/test_indent.py | 86 + .../simplejson/tests/test_item_sort_key.py | 20 + .../simplejson/tests/test_namedtuple.py | 122 + .../packages/simplejson/tests/test_pass1.py | 71 + .../packages/simplejson/tests/test_pass2.py | 14 + .../packages/simplejson/tests/test_pass3.py | 20 + .../simplejson/tests/test_recursion.py | 67 + .../simplejson/tests/test_scanstring.py | 194 + .../simplejson/tests/test_separators.py | 42 + .../simplejson/tests/test_speedups.py | 39 + .../packages/simplejson/tests/test_tool.py | 97 + .../packages/simplejson/tests/test_tuple.py | 51 + .../packages/simplejson/tests/test_unicode.py | 153 + .../wakatime/packages/simplejson/tool.py | 42 + .../wakatime/packages/tzlocal/__init__.py | 6 + .../packages/tzlocal/test_data/Harare | Bin 0 -> 157 bytes .../tzlocal/test_data/localtime/etc/localtime | Bin 0 -> 157 bytes .../tzlocal/test_data/timezone/etc/timezone | 1 + .../timezone_setting/etc/conf.d/clock | 1 + .../zone_setting/etc/sysconfig/clock | 1 + .../wakatime/packages/tzlocal/tests.py | 64 + .../wakatime/packages/tzlocal/unix.py | 113 + .../wakatime/packages/tzlocal/win32.py | 88 + .../wakatime/packages/tzlocal/windows_tz.py | 101 + .../wakatime/packages/tzlocal3/__init__.py | 6 + .../wakatime/packages/tzlocal3/tests.py | 64 + .../wakatime/packages/tzlocal3/unix.py | 113 + .../wakatime/packages/tzlocal3/win32.py | 88 + .../wakatime/packages/tzlocal3/windows_tz.py | 101 + .../plugin/packages/wakatime/project.py | 44 + .../packages/wakatime/projects/__init__.py | 0 .../plugin/packages/wakatime/projects/base.py | 53 + .../plugin/packages/wakatime/projects/git.py | 59 + .../packages/wakatime/projects/mercurial.py | 52 + .../packages/wakatime/projects/projectmap.py | 66 + .../packages/wakatime/projects/subversion.py | 96 + .../packages/wakatime/projects/wakatime.py | 58 + .../plugin/packages/wakatime/stats.py | 105 + .../vim-wakatime/plugin/wakatime.vim | 177 + 1174 files changed, 187254 insertions(+), 6065 deletions(-) create mode 100644 sources_non_forked/Dockerfile.vim/.gitignore create mode 100644 sources_non_forked/Dockerfile.vim/LICENSE create mode 100644 sources_non_forked/Dockerfile.vim/Makefile create mode 100644 sources_non_forked/Dockerfile.vim/README.md create mode 100644 sources_non_forked/Dockerfile.vim/ftdetect/Dockerfile.vim create mode 100644 sources_non_forked/Dockerfile.vim/snippets/Dockerfile.snippets create mode 100644 sources_non_forked/Dockerfile.vim/syntax/Dockerfile.vim create mode 100644 sources_non_forked/Dockerfile.vim/vim-dockerfile-example.png create mode 100644 sources_non_forked/tagbar/.gitattributes create mode 100644 sources_non_forked/tagbar/.gitignore create mode 100644 sources_non_forked/tagbar/.info create mode 100644 sources_non_forked/tagbar/LICENSE create mode 100644 sources_non_forked/tagbar/README.md create mode 100644 sources_non_forked/tagbar/autoload/tagbar.vim create mode 100644 sources_non_forked/tagbar/doc/tagbar.txt create mode 100644 sources_non_forked/tagbar/plugin/tagbar.vim create mode 100644 sources_non_forked/tagbar/syntax/tagbar.vim delete mode 100644 sources_non_forked/taglist.vim/README delete mode 100644 sources_non_forked/taglist.vim/doc/taglist.txt delete mode 100644 sources_non_forked/taglist.vim/plugin/taglist.vim create mode 100644 sources_non_forked/vim-gitgutter/.gitignore create mode 100644 sources_non_forked/vim-gitgutter/README.mkd create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter.vim create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter/debug.vim create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter/diff.vim create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter/highlight.vim create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter/hunk.vim create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter/sign.vim create mode 100644 sources_non_forked/vim-gitgutter/autoload/gitgutter/utility.vim create mode 100644 sources_non_forked/vim-gitgutter/doc/gitgutter.txt create mode 100644 sources_non_forked/vim-gitgutter/plugin/gitgutter.vim create mode 100644 sources_non_forked/vim-gitgutter/screenshot.png create mode 100644 sources_non_forked/vim-gitgutter/test/README.markdown create mode 100644 sources_non_forked/vim-gitgutter/test/addLines.expected create mode 100644 sources_non_forked/vim-gitgutter/test/ambiguousFile.expected create mode 100644 sources_non_forked/vim-gitgutter/test/fileAddedToGit.expected create mode 100644 sources_non_forked/vim-gitgutter/test/filenameWithSquareBrackets.expected create mode 100644 sources_non_forked/vim-gitgutter/test/fix[tu]re.txt create mode 100644 sources_non_forked/vim-gitgutter/test/fixture.txt create mode 100644 sources_non_forked/vim-gitgutter/test/followSymlink.expected create mode 100644 sources_non_forked/vim-gitgutter/test/helper.vim create mode 100644 sources_non_forked/vim-gitgutter/test/hunkHunkOutsideNoopRevertGitDiffStaged.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkHunkOutsideNoopStageGitDiffStaged.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkOutsideNoopRevertSigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkOutsideNoopStageSigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkRevertGitDiff.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkRevertNearbyGitDiff.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkRevertNearbySigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkRevertSigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkStageGitDiff.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkStageNearbyGitDiff.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkStageNearbyGitDiffStaged.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkStageNearbySigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/hunkStageSigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/keepAlt.expected create mode 100644 sources_non_forked/vim-gitgutter/test/keepModified.expected create mode 100644 sources_non_forked/vim-gitgutter/test/keepOpMarks.expected create mode 100644 sources_non_forked/vim-gitgutter/test/modifyLines.expected create mode 100644 sources_non_forked/vim-gitgutter/test/noModifications.expected create mode 100644 sources_non_forked/vim-gitgutter/test/orphanedSigns.expected create mode 100644 sources_non_forked/vim-gitgutter/test/removeFirstLines.expected create mode 100644 sources_non_forked/vim-gitgutter/test/removeLines.expected create mode 100644 sources_non_forked/vim-gitgutter/test/signColumnAlways.expected create mode 100755 sources_non_forked/vim-gitgutter/test/test create mode 100644 sources_non_forked/vim-gitgutter/test/testAddLines.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testEditAmbiguousFile.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testFileAddedToGit.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testFilenameWithSquareBrackets.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testFollowSymlink.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testHunkOutsideNoop.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testHunkRevert.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testHunkRevertNearbyHunk.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testHunkStage.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testHunkStageNearbyHunk.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testKeepAlt.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testKeepModified.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testKeepOpMarks.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testModifyLines.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testNoModifications.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testOrphanedSigns.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testRemoveFirstLines.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testRemoveLines.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testSignColumnAlways.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testUntrackedFileOutsideRepo.vim create mode 100644 sources_non_forked/vim-gitgutter/test/testUntrackedFileWithinRepo.vim create mode 100644 sources_non_forked/vim-gitgutter/test/untrackedFileOutsideRepo.expected create mode 100644 sources_non_forked/vim-gitgutter/test/untrackedFileWithinRepo.expected create mode 100644 sources_non_forked/vim-wakatime/.gitignore create mode 100644 sources_non_forked/vim-wakatime/AUTHORS create mode 100644 sources_non_forked/vim-wakatime/HISTORY.rst create mode 100644 sources_non_forked/vim-wakatime/LICENSE.txt create mode 100644 sources_non_forked/vim-wakatime/README.md create mode 100644 sources_non_forked/vim-wakatime/doc/wakatime.txt create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/__about__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/base.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/cli.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/compat.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/c_cpp.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/data.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/dotnet.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/jvm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/php.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/python.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/templates.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/languages/unknown.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/logger.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/offlinequeue.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/argparse.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/ordereddict.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/cmdline.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/console.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/filter.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/filters/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatter.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/_mapping.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/bbcode.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/html.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/img.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/latex.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/other.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/rtf.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/svg.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/terminal.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/formatters/terminal256.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexer.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_asy_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_cl_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_cocoa_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_lasso_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_lua_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_mapping.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_mql_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_openedge_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_php_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_postgres_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_scilab_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_sourcemod_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_stan_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/_vim_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/actionscript.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/agile.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/algebra.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ambient.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/apl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/asm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/automation.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/basic.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/business.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/c_cpp.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/c_like.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/chapel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/compiled.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/configs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/console.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/css.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/d.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dalvik.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/data.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/diff.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dotnet.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dsls.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dylan.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ecl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/eiffel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/erlang.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/esoteric.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/factor.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fantom.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/felix.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fortran.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/foxpro.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/functional.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/go.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graph.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graphics.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haskell.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haxe.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/hdl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/html.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/idl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/igor.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/inferno.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/installers.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/int_fiction.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/iolang.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/javascript.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/julia.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/jvm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/lisp.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/make.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/markup.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/math.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/matlab.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ml.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/modeling.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nimrod.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nit.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nix.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/objective.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ooc.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/other.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/parsers.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pascal.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pawn.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/perl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/php.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/prolog.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/python.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/r.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rdf.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rebol.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/resource.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/robotframework.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ruby.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rust.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/scripting.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/shell.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/smalltalk.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/snobol.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/special.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/sql.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/tcl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/templates.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/testing.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/text.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/textedit.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/textfmts.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/theorem.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/urbi.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/web.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/webmisc.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/modeline.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/plugin.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/regexopt.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/scanner.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/sphinxext.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/style.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/autumn.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/borland.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/bw.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/colorful.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/default.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/emacs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/friendly.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/fruity.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/igor.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/manni.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/monokai.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/murphy.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/native.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/paraiso_dark.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/paraiso_light.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/pastie.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/perldoc.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/rrt.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/tango.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/trac.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/vim.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/vs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/styles/xcode.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/token.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/unistring.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/util.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/cmdline.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/console.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/filter.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/filters/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatter.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/_mapping.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/bbcode.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/html.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/img.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/latex.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/other.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/rtf.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/svg.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/terminal.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/formatters/terminal256.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexer.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_asy_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_cl_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_cocoa_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_lasso_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_lua_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_mapping.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_mql_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_openedge_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_php_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_postgres_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_scilab_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_sourcemod_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_stan_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/_vim_builtins.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/actionscript.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/agile.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/algebra.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/ambient.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/apl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/asm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/automation.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/basic.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/business.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/c_cpp.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/c_like.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/chapel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/compiled.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/configs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/console.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/css.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/d.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/dalvik.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/data.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/diff.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/dotnet.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/dsls.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/dylan.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/ecl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/eiffel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/erlang.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/esoteric.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/factor.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/fantom.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/felix.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/fortran.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/foxpro.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/functional.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/go.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/graph.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/graphics.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/haskell.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/haxe.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/hdl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/html.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/idl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/igor.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/inferno.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/installers.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/int_fiction.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/iolang.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/javascript.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/julia.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/jvm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/lisp.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/make.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/markup.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/math.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/matlab.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/ml.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/modeling.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/nimrod.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/nit.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/nix.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/objective.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/ooc.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/other.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/parsers.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/pascal.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/pawn.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/perl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/php.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/prolog.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/python.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/r.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/rdf.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/rebol.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/resource.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/robotframework.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/ruby.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/rust.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/scripting.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/shell.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/smalltalk.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/snobol.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/special.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/sql.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/tcl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/templates.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/testing.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/text.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/textedit.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/textfmts.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/theorem.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/urbi.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/web.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/lexers/webmisc.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/modeline.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/plugin.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/regexopt.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/scanner.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/sphinxext.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/style.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/autumn.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/borland.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/bw.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/colorful.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/default.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/emacs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/friendly.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/fruity.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/igor.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/manni.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/monokai.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/murphy.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/native.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/paraiso_dark.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/paraiso_light.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/pastie.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/perldoc.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/rrt.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/tango.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/trac.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/vim.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/vs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/styles/xcode.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/token.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/unistring.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py3/pygments/util.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/exceptions.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/lazy.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/reference.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/tests/test_docs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/tests/test_tzinfo.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/tzfile.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/tzinfo.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Abidjan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Accra create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Addis_Ababa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Algiers create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Asmara create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Asmera create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Bamako create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Bangui create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Banjul create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Bissau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Blantyre create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Brazzaville create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Bujumbura create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Cairo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Casablanca create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Ceuta create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Conakry create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Dakar create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Dar_es_Salaam create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Djibouti create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Douala create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/El_Aaiun create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Freetown create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Gaborone create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Harare create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Johannesburg create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Juba create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Kampala create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Khartoum create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Kigali create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Kinshasa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Lagos create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Libreville create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Lome create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Luanda create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Lubumbashi create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Lusaka create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Malabo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Maputo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Maseru create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Mbabane create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Mogadishu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Monrovia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Nairobi create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Ndjamena create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Niamey create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Nouakchott create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Ouagadougou create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Porto-Novo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Sao_Tome create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Timbuktu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Tripoli create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Tunis create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Africa/Windhoek create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Adak create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Anchorage create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Anguilla create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Antigua create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Araguaina create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Buenos_Aires create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Catamarca create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/ComodRivadavia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Cordoba create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Jujuy create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/La_Rioja create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Mendoza create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Rio_Gallegos create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Salta create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/San_Juan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/San_Luis create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Tucuman create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Argentina/Ushuaia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Aruba create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Asuncion create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Atikokan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Atka create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Bahia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Bahia_Banderas create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Barbados create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Belem create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Belize create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Blanc-Sablon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Boa_Vista create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Bogota create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Boise create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Buenos_Aires create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Cambridge_Bay create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Campo_Grande create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Cancun create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Caracas create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Catamarca create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Cayenne create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Cayman create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Chicago create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Chihuahua create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Coral_Harbour create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Cordoba create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Costa_Rica create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Creston create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Cuiaba create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Curacao create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Danmarkshavn create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Dawson create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Dawson_Creek create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Denver create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Detroit create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Dominica create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Edmonton create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Eirunepe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/El_Salvador create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Ensenada create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Fort_Wayne create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Fortaleza create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Glace_Bay create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Godthab create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Goose_Bay create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Grand_Turk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Grenada create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Guadeloupe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Guatemala create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Guayaquil create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Guyana create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Halifax create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Havana create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Hermosillo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Indianapolis create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Knox create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Marengo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Petersburg create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Tell_City create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Vevay create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Vincennes create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indiana/Winamac create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Indianapolis create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Inuvik create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Iqaluit create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Jamaica create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Jujuy create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Juneau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Kentucky/Louisville create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Kentucky/Monticello create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Knox_IN create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Kralendijk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/La_Paz create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Lima create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Los_Angeles create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Louisville create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Lower_Princes create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Maceio create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Managua create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Manaus create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Marigot create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Martinique create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Matamoros create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Mazatlan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Mendoza create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Menominee create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Merida create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Metlakatla create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Mexico_City create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Miquelon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Moncton create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Monterrey create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Montevideo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Montreal create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Montserrat create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Nassau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/New_York create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Nipigon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Nome create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Noronha create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/North_Dakota/Beulah create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/North_Dakota/Center create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/North_Dakota/New_Salem create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Ojinaga create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Panama create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Pangnirtung create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Paramaribo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Phoenix create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Port-au-Prince create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Port_of_Spain create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Porto_Acre create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Porto_Velho create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Puerto_Rico create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Rainy_River create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Rankin_Inlet create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Recife create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Regina create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Resolute create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Rio_Branco create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Rosario create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Santa_Isabel create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Santarem create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Santiago create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Santo_Domingo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Sao_Paulo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Scoresbysund create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Shiprock create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Sitka create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/St_Barthelemy create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/St_Johns create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/St_Kitts create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/St_Lucia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/St_Thomas create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/St_Vincent create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Swift_Current create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Tegucigalpa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Thule create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Thunder_Bay create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Tijuana create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Toronto create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Tortola create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Vancouver create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Virgin create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Whitehorse create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Winnipeg create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Yakutat create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/America/Yellowknife create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Casey create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Davis create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/DumontDUrville create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Macquarie create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Mawson create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/McMurdo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Palmer create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Rothera create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/South_Pole create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Syowa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Antarctica/Vostok create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Arctic/Longyearbyen create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Aden create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Almaty create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Amman create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Anadyr create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Aqtau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Aqtobe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ashgabat create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ashkhabad create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Baghdad create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Bahrain create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Baku create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Bangkok create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Beirut create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Bishkek create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Brunei create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Calcutta create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Choibalsan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Chongqing create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Chungking create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Colombo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Dacca create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Damascus create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Dhaka create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Dili create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Dubai create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Dushanbe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Gaza create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Harbin create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Hebron create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ho_Chi_Minh create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Hong_Kong create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Hovd create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Irkutsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Istanbul create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Jakarta create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Jayapura create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Jerusalem create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kabul create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kamchatka create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Karachi create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kashgar create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kathmandu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Katmandu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Khandyga create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kolkata create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Krasnoyarsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kuala_Lumpur create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kuching create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Kuwait create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Macao create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Macau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Magadan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Makassar create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Manila create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Muscat create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Nicosia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Novokuznetsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Novosibirsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Omsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Oral create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Phnom_Penh create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Pontianak create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Pyongyang create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Qatar create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Qyzylorda create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Rangoon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Riyadh create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Riyadh87 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Riyadh88 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Riyadh89 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Saigon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Sakhalin create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Samarkand create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Seoul create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Shanghai create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Singapore create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Taipei create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Tashkent create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Tbilisi create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Tehran create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Tel_Aviv create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Thimbu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Thimphu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Tokyo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ujung_Pandang create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ulaanbaatar create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ulan_Bator create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Urumqi create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Ust-Nera create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Vientiane create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Vladivostok create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Yakutsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Yekaterinburg create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Asia/Yerevan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Azores create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Bermuda create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Canary create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Cape_Verde create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Faeroe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Faroe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Jan_Mayen create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Madeira create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Reykjavik create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/South_Georgia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/St_Helena create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Atlantic/Stanley create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/ACT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Adelaide create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Brisbane create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Broken_Hill create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Canberra create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Currie create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Darwin create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Eucla create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Hobart create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/LHI create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Lindeman create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Lord_Howe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Melbourne create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/NSW create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/North create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Perth create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Queensland create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/South create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Sydney create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Tasmania create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Victoria create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/West create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Australia/Yancowinna create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Brazil/Acre create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Brazil/DeNoronha create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Brazil/East create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Brazil/West create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/CET create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/CST6CDT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Atlantic create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Central create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/East-Saskatchewan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Eastern create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Mountain create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Newfoundland create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Pacific create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Saskatchewan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Canada/Yukon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Chile/Continental create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Chile/EasterIsland create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Cuba create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/EET create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/EST create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/EST5EDT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Egypt create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Eire create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+0 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+1 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+10 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+11 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+12 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+2 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+3 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+4 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+5 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+6 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+7 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+8 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT+9 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-0 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-1 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-10 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-11 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-12 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-13 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-14 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-2 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-3 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-4 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-5 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-6 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-7 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-8 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT-9 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/GMT0 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/Greenwich create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/UCT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/UTC create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/Universal create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Etc/Zulu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Amsterdam create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Andorra create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Athens create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Belfast create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Belgrade create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Berlin create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Bratislava create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Brussels create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Bucharest create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Budapest create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Busingen create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Chisinau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Copenhagen create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Dublin create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Gibraltar create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Guernsey create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Helsinki create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Isle_of_Man create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Istanbul create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Jersey create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Kaliningrad create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Kiev create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Lisbon create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Ljubljana create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/London create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Luxembourg create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Madrid create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Malta create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Mariehamn create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Minsk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Monaco create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Moscow create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Nicosia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Oslo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Paris create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Podgorica create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Prague create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Riga create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Rome create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Samara create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/San_Marino create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Sarajevo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Simferopol create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Skopje create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Sofia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Stockholm create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Tallinn create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Tirane create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Tiraspol create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Uzhgorod create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Vaduz create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Vatican create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Vienna create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Vilnius create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Volgograd create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Warsaw create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Zagreb create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Zaporozhye create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Europe/Zurich create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Factory create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/GB create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/GB-Eire create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/GMT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/GMT+0 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/GMT-0 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/GMT0 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Greenwich create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/HST create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Hongkong create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Iceland create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Antananarivo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Chagos create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Christmas create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Cocos create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Comoro create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Kerguelen create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Mahe create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Maldives create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Mauritius create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Mayotte create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Indian/Reunion create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Iran create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Israel create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Jamaica create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Japan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Kwajalein create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Libya create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/MET create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/MST create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/MST7MDT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Mexico/BajaNorte create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Mexico/BajaSur create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Mexico/General create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Mideast/Riyadh87 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Mideast/Riyadh88 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Mideast/Riyadh89 create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/NZ create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/NZ-CHAT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Navajo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/PRC create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/PST8PDT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Apia create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Auckland create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Chatham create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Chuuk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Easter create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Efate create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Enderbury create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Fakaofo create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Fiji create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Funafuti create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Galapagos create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Gambier create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Guadalcanal create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Guam create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Honolulu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Johnston create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Kiritimati create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Kosrae create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Kwajalein create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Majuro create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Marquesas create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Midway create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Nauru create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Niue create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Norfolk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Noumea create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Pago_Pago create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Palau create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Pitcairn create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Pohnpei create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Ponape create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Port_Moresby create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Rarotonga create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Saipan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Samoa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Tahiti create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Tarawa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Tongatapu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Truk create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Wake create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Wallis create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Pacific/Yap create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Poland create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Portugal create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/ROC create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/ROK create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Singapore create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Turkey create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/UCT create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Alaska create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Aleutian create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Arizona create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Central create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/East-Indiana create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Eastern create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Hawaii create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Indiana-Starke create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Michigan create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Mountain create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Pacific create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Pacific-New create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/US/Samoa create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/UTC create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Universal create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/W-SU create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/WET create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/Zulu create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/iso3166.tab create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/localtime create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/posixrules create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz/zoneinfo/zone.tab create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/exceptions.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/lazy.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/reference.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/tests/test_docs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/tests/test_tzinfo.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/tzfile.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pytz3/tzinfo.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/adapters.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/api.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/auth.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/cacert.pem create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/certs.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/compat.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/cookies.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/exceptions.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/hooks.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/models.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/README.rst create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/big5freq.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/big5prober.py create mode 100755 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/chardetect.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/chardistribution.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/charsetgroupprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/charsetprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/codingstatemachine.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/compat.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/constants.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/cp949prober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/escprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/escsm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/eucjpprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/euckrfreq.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/euckrprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/euctwfreq.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/euctwprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/gb2312freq.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/gb2312prober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/hebrewprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/jisfreq.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/jpcntx.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/langbulgarianmodel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/langcyrillicmodel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/langgreekmodel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/langhebrewmodel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/langhungarianmodel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/langthaimodel.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/latin1prober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/mbcharsetprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/mbcsgroupprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/mbcssm.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/sbcharsetprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/sbcsgroupprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/sjisprober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/universaldetector.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/chardet/utf8prober.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/_collections.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/connection.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/connectionpool.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/contrib/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/contrib/ntlmpool.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/contrib/pyopenssl.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/exceptions.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/fields.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/filepost.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/packages/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/packages/ordered_dict.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/packages/six.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/packages/ssl_match_hostname/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/packages/ssl_match_hostname/_implementation.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/poolmanager.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/request.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/response.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/connection.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/request.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/response.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/retry.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/ssl_.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/timeout.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/packages/urllib3/util/url.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/sessions.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/status_codes.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/structures.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/requests/utils.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/_speedups.c create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/compat.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/decoder.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/encoder.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/ordered_dict.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/scanner.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_bigint_as_string.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_bitsize_int_as_string.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_check_circular.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_decimal.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_decode.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_default.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_dump.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_encode_basestring_ascii.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_encode_for_html.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_errors.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_fail.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_float.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_for_json.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_indent.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_item_sort_key.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_namedtuple.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_pass1.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_pass2.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_pass3.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_recursion.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_scanstring.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_separators.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_speedups.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_tool.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_tuple.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tests/test_unicode.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/simplejson/tool.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/test_data/Harare create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/test_data/localtime/etc/localtime create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/test_data/timezone/etc/timezone create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/test_data/timezone_setting/etc/conf.d/clock create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/test_data/zone_setting/etc/sysconfig/clock create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/tests.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/unix.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/win32.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal/windows_tz.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal3/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal3/tests.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal3/unix.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal3/win32.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/tzlocal3/windows_tz.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/project.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/__init__.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/base.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/git.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/mercurial.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/projectmap.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/subversion.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/projects/wakatime.py create mode 100644 sources_non_forked/vim-wakatime/plugin/packages/wakatime/stats.py create mode 100644 sources_non_forked/vim-wakatime/plugin/wakatime.vim diff --git a/sources_non_forked/Dockerfile.vim/.gitignore b/sources_non_forked/Dockerfile.vim/.gitignore new file mode 100644 index 0000000000..3819313818 --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/.gitignore @@ -0,0 +1,2 @@ +*.swp +*.swo diff --git a/sources_non_forked/Dockerfile.vim/LICENSE b/sources_non_forked/Dockerfile.vim/LICENSE new file mode 100644 index 0000000000..27856ca5fd --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/LICENSE @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2013 Eugene Kalinin + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/sources_non_forked/Dockerfile.vim/Makefile b/sources_non_forked/Dockerfile.vim/Makefile new file mode 100644 index 0000000000..1e327613dd --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/Makefile @@ -0,0 +1,12 @@ +install: + @echo "Installation:" + @mkdir -p ~/.vim/syntax + @mkdir -p ~/.vim/ftdetect + @mkdir -p ~/.vim/snippets + @echo " * Dirs ... success." + @cp ./syntax/Dockerfile.vim ~/.vim/syntax/ + @echo " * Syntax ... success." + @cp ./ftdetect/Dockerfile.vim ~/.vim/ftdetect/ + @echo " * Filetype ... success." + @cp ./snippets/Dockerfile.snippets ~/.vim/snippets/ + @echo " * Snippets ... success." diff --git a/sources_non_forked/Dockerfile.vim/README.md b/sources_non_forked/Dockerfile.vim/README.md new file mode 100644 index 0000000000..f1d838dd87 --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/README.md @@ -0,0 +1,41 @@ +Dockerfile.vim +============== + +Vim syntax file for [Docker](http://docker.io/)'s [Dockerfile](http://docs.docker.io/en/latest/use/builder/) +and snippets for [snipMate](http://www.vim.org/scripts/script.php?script_id=2540). + +Screenshot +========== + +Here is an example in gnome-terminal with [vim-monokai](https://github.com/sickill/vim-monokai) color scheme: + + +![Vim & Dockerfile.vim ](https://raw.github.com/ekalinin/Dockerfile.vim/master/vim-dockerfile-example.png) + + + +Installation +============ + +````bash +$ git clone https://github.com/ekalinin/Dockerfile.vim.git +$ cd Dockerfile.vim +$ make install +```` + +####OR using Pathogen: +```bash +# Clone directly into the bundle folder. +git clone https://github.com/ekalinin/Dockerfile.vim.git bundle/Dockerfile +``` + +####OR using Vundle: +```bash +# near the top of your .vimrc +Plugin "ekalinin/Dockerfile.vim" +``` + +License +======= + +See [LICENSE](https://github.com/ekalinin/Dockerfile.vim/blob/master/LICENSE) file. diff --git a/sources_non_forked/Dockerfile.vim/ftdetect/Dockerfile.vim b/sources_non_forked/Dockerfile.vim/ftdetect/Dockerfile.vim new file mode 100644 index 0000000000..ff20cd9125 --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/ftdetect/Dockerfile.vim @@ -0,0 +1,4 @@ +" Dockerfile +autocmd BufRead,BufNewFile Dockerfile set ft=Dockerfile +autocmd BufRead,BufNewFile Dockerfile* setf Dockerfile +autocmd BufRead,BufNewFile *.dock setf Dockerfile diff --git a/sources_non_forked/Dockerfile.vim/snippets/Dockerfile.snippets b/sources_non_forked/Dockerfile.vim/snippets/Dockerfile.snippets new file mode 100644 index 0000000000..3966ea34ad --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/snippets/Dockerfile.snippets @@ -0,0 +1,62 @@ +snippet F + FROM ${1:ubuntu} +snippet f + FROM ${1:ubuntu} +snippet M + MAINTAINER ${1:name} +snippet m + MAINTAINER ${1:name} +snippet R + RUN ${1:command} +snippet r + RUN ${1:command} +snippet C + CMD ${1:command} +snippet c + CMD ${1:command} +snippet CP + COPY ${1:src} ${2:dest} +snippet cp + COPY ${1:src} ${2:dest} +snippet EXP + EXPOSE ${1:port} +snippet exp + EXPOSE ${1:port} +snippet E + ENV ${1:key} ${2:value} +snippet e + ENV ${1:key} ${2:value} +snippet A + ADD ${1:src} ${2:dst} +snippet a + ADD ${1:src} ${2:dst} +snippet ENT + ENTRYPOINT ${1:command} +snippet ent + ENTRYPOINT ${1:command} +snippet V + VOLUME ["${1:path}"] +snippet v + VOLUME ["${1:path}"] +snippet U + USER ${1:name} +snippet u + USER ${1:name} +snippet W + WORKDIR ${1:path} +snippet w + WORKDIR ${1:path} +snippet upd + # update packages + RUN echo "deb http://archive.ubuntu.com/ubuntu ${1:precise} main universe" > /etc/apt/sources.list; \ + apt-get update && apt-get -y upgrade; \ + ${2} +snippet head + # ${1:Description} + # + # VERSION ${2:0.1.0} + ${3} +snippet O + ONBUILD ${1} +snippet o + ONBUILD ${1} diff --git a/sources_non_forked/Dockerfile.vim/syntax/Dockerfile.vim b/sources_non_forked/Dockerfile.vim/syntax/Dockerfile.vim new file mode 100644 index 0000000000..e7ebdd8e5a --- /dev/null +++ b/sources_non_forked/Dockerfile.vim/syntax/Dockerfile.vim @@ -0,0 +1,54 @@ +" Vim syntax file +" Language: Dockerfile +" Maintainer: Eugene Kalinin +" Latest Revision: 11 September 2013 +" Source: http://docs.docker.io/en/latest/use/builder/ + +if exists("b:current_syntax") + finish +endif + +" case sensitivity (fix #17) +" syn case ignore + +" Keywords +syn keyword dockerfileKeywords FROM MAINTAINER RUN CMD COPY +syn keyword dockerfileKeywords EXPOSE ENV ADD ENTRYPOINT +syn keyword dockerfileKeywords VOLUME USER WORKDIR ONBUILD + +" Bash statements +setlocal iskeyword+=- +syn keyword bashStatement add-apt-repository adduser apt-get aptitude apt-key autoconf bundle +syn keyword bashStatement cd chgrp chmod chown clear complete composer cp curl du echo egrep +syn keyword bashStatement expr fgrep find gem gnufind gnugrep gpg grep groupadd head less ln +syn keyword bashStatement ls make mkdir mv node npm pacman php python rails rm rmdir rpm ruby +syn keyword bashStatement sed sleep sort strip tail tailf touch useradd virtualenv yum + +" Strings +syn region dockerfileString start=/"/ skip=/\\"/ end=/"/ +syn region dockerfileString1 start=/'/ skip=/\\'/ end=/'/ + +" Emails +syn region dockerfileEmail start=// contains=@ oneline + +" Urls +syn match dockerfileUrl /\(http\|https\|ssh\|hg\|git\)\:\/\/[a-zA-Z0-9\/\-\.]\+/ + +" Comments +syn match dockerfileComment "#.*$" + +" Highlighting +hi link dockerfileKeywords Keyword +hi link dockerfileString String +hi link dockerfileString1 String +hi link dockerfileComment Comment +hi link dockerfileEmail Identifier +hi link dockerfileUrl Identifier +hi link bashStatement Function + +let b:current_syntax = "dockerfile" + +set commentstring=#\ %s + +" Enable automatic comment insertion +setlocal fo+=cro diff --git a/sources_non_forked/Dockerfile.vim/vim-dockerfile-example.png b/sources_non_forked/Dockerfile.vim/vim-dockerfile-example.png new file mode 100644 index 0000000000000000000000000000000000000000..c82f871f84f7a27ee90783ac65a997708e0f033f GIT binary patch literal 57722 zcmaI71#n!uwk>MMF;mP;am>u@j+vR6VrJ$xGsev9n3>s*DQ0G7X2$+W_CBx9{r|pS zU0q$J)>@M0oRY>I8VZw_6+?u>g#!ZvLzEB~Rs;ispala17l(oRT~h1h@%Z}(%1}y7 z7!361lhaWY|GNa%PF%wg3=AIa&lemlEd%>^A+(c(j0p4^EIbMdMtYEJ=I>Sf&Q_R}fPo-HQuCN&H&B z**~`j`g}S4@&M)k@vT#@s$DlQ{vg9N>&5HBF?id)P1$#7D*uxp3`yW8!O(Z%rU!pRK8WzY~V!i~dvp6!K<)6oc`2b#?DD?`B-3( z)|6EH=f5?dLo2%m6z2VmxPaQMg&ST%0-nUPI4nCBgI5=-y+DxdL1)j3n_AStUTsgt z=0%FaO9PUsnChjx6)8q$yj2AtW8?(NK59%7oxd?e?eeQ2B3=V^F=izL!H7yQudJla z4@82QGK$NzvLr`l$t9q&^lZbIjQdXv49mkoEF3e32?E6bb{Y1&|2*zQj=>-!Eg1sh z8FUk#H(Ny9amiAL79dd*BT7v!9MF9L(RdRsAQVRvoqiI04W*TeXF6DzmZHZNx6(1j zo1{JL!WJoY%<{NV3RZ+%UZ_3y{Tw=iC3?!wWM1E(QV6~@OdTUO5%P~oVMv~pL9Jh; zr%-vUSWBKQ8m%aMN(fhNl%vu=XcT z%@?M9c6;M8jiifgxfgON`JSLGmCh0r!HbKoB8Q5kYTlcAGOzD4$fU3$*l9@2^+~Ya zFsm=$^2QD1Uoh^eeEW_5Iir2fm1(%1!VJ%Cea5SWEc^9!%q(ybML%l4PzffvhjYrS=w}#t!uik&=0rSnfF5~^xb++=(InVAKWyGGzelQ% zmvUgT?c!`g&jP4D!4ayfcV;iQ&~~jecy0r0%NQ++bpLWaGG3g;ig?1PsFV@8a3Jj1 z+Qd|V{|VX~IRex1Cvj~Y?IMkqxwYMh8S3AzqE-hA>-Dn@-6^}iAJ4VgpV60RNe%z7 zlQ?Kht2V?OSh5SWbIu^o8T3ak>I|D;HD4`Nz4Ybp?l%iXDh?^6yeHUD`pFe3$0p!z ztK?};X(P~iEo}4)4V=CV?(kuOw;(N! z%HQGUO}xTw^yW>Q*~OY#Y)*mSrD#Dp))bLanz1%162O=?n#wh(ui8t)Hb3?3iX1HD zk@*r~w5`iluFHX4Qo<$qqP~(Cyt7+a!@>5V3AO78lQ@i8197VdKyeSCAN34;r9V%S&|s zQ-uNwA70kr^S1?h4i`S%(qqa&(sY#=O!Yt5zcdy-<{{LI3ZG*gQVK_<48RUjSqliE@TCq7qS1GF{FAs1Xx+a+k@U+N?p(eRLQTV z3|O%erw+q06n3GqN;pSjuE4imXgnj zBdapJ22NM94)pWOJ=%KC2q=$KFbsPSunh@RZ~+jw=puZ?lvh-6Kfc0%!^<}Eb%cf( z67CJW=V=-jGxmhgMpW4uSIB_++f0_AbRX#`ul{Er>-_P1e+m&jS3~)Cru;32Apr(CDMEf$ zb{JZisyLB)F7OWe9oth~LvRuQtX6^_FiC^~033B_WNFLkt8NQF5O&c@b(zCeZO=sBT})^ zRkjb^hjk(e;Q+lMsz1QtNxbNs|GkDS-mT1fL#?|>WY=!nm)$E1oqshonA`;3w4cik zLR0TEh)QC+?zZA}fh~@WZA-_*`oarVU@m%RqvEBjs51(W#qp6k zwtK`lfU9Ri0R>nQF!vpU7kx!sL_A)ZW#{}Q+(!?)X#-SsFffF5<9?#RkNZ=0H<3uM z=X!8R``R5Z$7u6aP5oV;+4kLqP|n8r_EDNuZ>dY2^MOX%K*`PQ=xhzCC1n(0)Pz8z z#-n@fgv8VA=#RmFBLXhBWf*3$9|mTNJ^Q>o!atZC7S+kQwA2$fM2XG1^GMf_F-`IF zA;!vkerktcDx=j<6I3AxkSsI#?yy>0$@ex-<{reu$Q{5FsnqT?GBHR_?6w*`vhcL9 z_K4P1vTz>qN{c!|nF?DUc(1L`s3n@5AdO4RGaj5Q}8?+P9vy!iEbs<2tVv}`xG*ihP5C$`wTXy-O6Jpt66PC{l+J)}%>GHdVk zmM7&IW7^Y9&(j63ly2Pk#j8K$c%)I%nfYISvs!aeg|`1d;(>k$JoeliT2XBNj@E$Eo2Q9DXg`)pek!6EVtdPc^u=`v@qS+7(hbP95x4bVexr7)QclN|Snj z=HEDQ(dKUOev@4H+{K4-2_6sUil|F&9}1^?+C8u}np=_LWa+q>rdazr?!8OU`N-6^ zQ(N{Q08vwf_mI-bQRBEud+z;2uGrNQkEc7fK`@FVw%Xk_Z*|gsYKf-T>4L|CCKU1F zs>7Vr}apfPp;w!Kj@w%-YQHL=MmVLj&^baj; z@sl?Mu?%2JXt|;BV9;GQ2-m*`@I()F>T1_lxjivg;+kr4-?Vph zErP^}e7cqg3SoUq-`tay>mgEJ`qF8+S`u9^n!`sbo3pwq8<p5JTd!6B%=x_xo?-a3e2Ly(Y=rGTFKV2g+c`pHXMlu*f%fGh@)|Ta>+rkV<2av}LkW^V&pD=T> zAgBE#wuaLnvNG7>*E%f_JIQeZq3hy?<0(u;_Ld@&@MXn@tG&HZe<;ctrEALWmuvF= z+F~llXf({3sg_|N!J zsS)RI!=&*D1je2(epTKC@}^FgYD&9Z(a^6;E)6#|Q%pM9*vTx~V_v?`)~k-WoRO=i_P|1*H|Ivl%t?9SFxNL&^gAtz>*+IA(U6{B zp*q>a5GXB6%4_!;MpnO9g#Gxn?83vP!pw>C<0aIr%?PABFYwB+(_Gj_V-r!zhpvrC8{-&b#+(G+&acY^N>DCBBhsD1cc`%ZpN+;jRA7Tz@-WX%dAkk}5yne6>E! znypgT`^NItatgIOCS1psqRHqzOiZErBf4}J_75m4-dNR9xy*Q{exflnjIhyL3w2Y3 zKpj=MD=0dnK%Uevd#_Nv0UI@U{7#K7I7+Kv^*VWAxgFXobwy z?p7Ffu|9~VV0Er#)&XhIRO8X@%n!{-?TA~lCD;fp&E3em*Do17&4b@-@-`PMaK1s# zevb(C=`yIu&2S}^)~zVx>!Tfcp_{tn#!UNz4o^<5fg6k88wBQD$Y2o}^{Vgm6yyWE zb_XY~<~C`hSvAU`_5JVg@17Hkr%7^)C-U@096OK3_uwUz@2Gb-?hyG0*Eq4ja>Q|Z zF=A?wEV)2zeGgtk6HgwC=9#<^9>$)`p#=AOk(uP9#D3F+^2isTT)63&syWC)ROxkH zRyJ8g{0$NFA5yVTXW|LvCk?*^(nOkM27F%goB63KMFyH1sO`p5+!A+rz_bi`2lrcJK6is62D*P#@quqD95l$7T)SDM^ zv2$-NcO`=JEh=>N?X0uyvg?%xBxwV@wx=e1L5580$#4)oK0jN}1nn&`U|r6l*}KfW`smoj{ATkmdJ&>mUx ztD>@*i)H3L?#5u3L*!zETcB%Bb38k_Bnwoyy#jqVIyvn+cVJhee6`gSLIG`Qh!Vv72M>EA zDBGm7yX^r8q@&G^DHqJy5C@sWED6BERfj~oeB*>Ozm>G+;NA;hP0hZJw=pZ7TCrtx ztq(1?^0Gj;2mV5*=HlI!FFJzX#$;tC!i{oY!KNJ~LjTcjw&v}GSJT_q7TTxl9_lku zN5l!}K;-ruHyqc`mq-Qj)!EBq<%yDmehazFCxzuRy4_sO-rCCJMD3>!(fUW8ZFV`! z>Y!6pe$E{>oA(`9+AentIo%iHB+sh-_XSKtsMm2($$8A_R@b5%^txNW1wd-FI zYMYcA;~iyy&x7+%Vx11_9T!|b0L}!+d_J(_nIkO+>Bd%;a7=n3X~2sdGM1=cj1V&P zEl0Y4qV_HRKeSZ}aL+uXzAg%ngK+96D=Vvb1fj~Pw3`{E)L?rb)xoRuGl9}jOYaE^|ekcY^J?7Qf35VSVo(KsarpDho;@u9)C(m)oe7kYUq@#5K3s~dZ z&Lv@_g3n!l+#fB9Tk_%0yM9;xNc)ysJ?|HZohT70@I49ZFD4ZHkOUO9B&S^s*WJeW zr(!hR+iCxI?$3&1%+!{|HL7%vI;@GdrcyR!XF&I~?|qJKe|ygS=5W-rkuj2X(P`@KLKXdJFO3&3evu`-`rq5oYAwS*J(w!e ztE?^tQZ$-SH13n9d2MAdv&T2Da+mVv1`*&|qNYlyqIajUCQM0q+BQg)!T-|=xYUNc zGFZ?$ZS_ZOI@T7$Fpj61g@wt}a~LOHLgZrI<@Vb3e}?$mmPCcw;XwT`yZ$L_G&CTUGOD1!Z>cU2K*xdtBUcBw+&?FI(_&loF?;3 zC<4pmZe05L--ISG)^|_-afNdIlCIyovCE|tt}$TM;omVT9I0LUqr$5Gn4UkJKZd5> zU3>dJ~R|{ydJITJN}Br5uHjA^I4N7YE4Zb zn&}Fg96vr%|nDk1QY|{UsSTP>#51QJKS71mY`m z9bnvU{%+>r^JNgT=NA>Jf}_uurge#55wzfV#w|gM9}EhRh<*lM5zd#>_2&8?mll2V zWYJAVj;#5H&k|UZuc^^dgBfE%Y_N;XEUmI@wHQ2BmctQZVCTW@kJ0~iyVwYaU`bfu zo?Fuk6E!4K|JIGDk;r8dSnTK#m35f{!y2`+q;4Zt^M%oDQ9PRMS);B6mjiQpK$dt$ zTW%}qtlsh`4x<~)e8>Ef2W@s&Y6cPT3#~f>8dPI^hXJ%T5DY+XdwETu&P$h+qKscwY&7#iir!Gx)ct zhw)>>;nK5@#YJbaEs%3OR*I`u?vmNzT*$x2qC|)&MNs4j*iLS{E}7Zb z^rL_+YuZQUAQV?T)&-Z6+q-$OYgm!j2Ew@6)i+%@mSh^9wRoxc zd9N)0SDLWOjQe+93xkl<(H*Jtp#+A~;P8)o&V-D@`_Rpb*7EbB!uxh@2lrKxx#c?V z$xpwaSjuUX^=AGd@}CIdAxdb{;D;o)UV9Z07+I5Ni=ke15rX(RnXoZPOdgs zu4@@JP?`eEV}ptFLI^ox;GR$w-qeufB8p-?CtoRQ^ix);t?DJVrsx_Ho+BV}qQSPB z`OA=hers$T6h~>K$lsYb)dhhGsbq-D^lWEnlF?J$!9l`MBW6MM|WyorUY8yPn^$ujz?h^!KXAu!dbQuQ!be-?M zrA|NAm3}~wM(gjLSbtgIPR)JioyTfKW7<{^c5_&ipADYa+14jS z{}Cfii~!AZ29B=7IkgWKwGvTmbqNl4&d6{KMDv(ikoDF8zuW8YL&zQ|$PEZBA1fT2 ziVP4C#^Xz1_w?v0&3U%-?7_AX7BYL-J^Z;-y?gLiu zQUB6U>qop-clyku1}{^ozAXbhy<=l_t@L&OA3$30w#^sv10fIl#QKy!PIl?G<6?D) zol@h*iI}Opohqw=qgg16Z(S*@mgfaM*L27rDxRgFkp!`k+2>j7{ArZ0bBpGVmg0o0 zDPNAOJ-hL9H_-H{L{USK$jdwY$lLH#jL6uvp>?tNF+M~~h95IyvplPdYPl%R?0?9_ ziTIIPOU)x7g>9#(cVTF^EFRp5p?Cmh+5GMcsQZFU-m4Qr_i3QpK;lsIy0{h^Mqa}H zjaW2>aN^QGbC&Bv;8~*X9VC^Wss2&j%B5NS5PnAFkExLHyg>ye3Cq~)GxOsAjZ6Og z?*u_qM@pTSt{;jS+ZUJ{_+)%-Sob1`tolLMN`@Wk3xcWF=gb($aRVIzHXDq~CdFnd z>a%4*In}c(TLg(|f;}pIvB}@0D-=c|G-msw# z!MoDuhpm+ZQL8tL8q8SSgB89-Varhy99cVCyFr`+%c4sI<`2Z==Y~dc?PWfE zY$;i9#5|isK_FyLQbyc-&@ZcVE>H_dtYX2c;Q6&=Zv5?;a=_GgLU-)`nOd`hFWGh@ z&k5@P%{*^^4IeyH1Sc1ZF?>!eBA6a$w^?-)hM$?7ygadyvHsXwL?ovDgxkr0L%aOwffv4bwZlWN#K=|ct9Viqy60N2s! zvkbYKUoA(aQ+)7~2}~2CpDfF}gw6nh$7(PneNzut-~Iy@VAZ4HJcxSbEDe-3!S?J3 zdK3Drr5N@qVLfQkOs>wSaUz+ViK>O8aC=tcw_#_3<9uk)Ch&W1oqBtmX*&{Oix5pM z(mDrkTMs$OWo3ya9qm?Ls(Y{xH?OxH@drT3M(0Az-~_{GkeK`1{qfD69lX&osGRfxfEBwMQ93&qvtN+96FNtj zy7Qp(jx=!uQeaBSi z-@1c;v;Y^?_@Ki*ninkigRFmfz&6;PEg=d~lrGO@B&s*U>S zxchOAut%Lt2L97j(Yg3-9c#7vq;oE{|GpMa>8liUhXe0tvGem!zM zU;891*aDut*kU--(MVk`hnv_Q_a3`EN{hm#{mEhE2IkM8g993*#!c4oa3vd?9@?01 zyNUvj5X|gnmS+XaZuCVxd_4j(t(1JNlz8s4%-*ddNciSuHN=njtY$+TrHnZBzBF!~ zT6Y`YGQMAP%VwStFBeay;SEtt^wqVrItGcN5gWTe6lGhIvMj~;`*%>rH6?$M-#vMZ zZ@w9B0T}{3SZ9G)BW(=AN>eztRH|5mdO9QJXlv>!bcq`S*Y7k6ZB5X7t_o|rUpMv# zrSN2AfSM1uV`;_cz=x0>PFKZ`qA{7*m?QkjMN|WnvaMd!SQCU_{io!FY`{S;qui=$ z7t3LS+ow3~UO-lRQKC7#TKA{aF)It$20Dzm37&vLEIh{T+|#x(-Wx&sAQz1Cl2y>Y z)qpv;q1)+NZl?LM+jXs+`X1im&AkgvolVA&h>~F_3(aOto%f!JE-*hfuH!k)P-6EX z<}G+8(d)d;n{LUaVI-I3u+L9edAGWf{?oNfZ;m~$-3GR(usJx7=!+Y(~A_30y? z&NeZ9rxj?uE+p2V+)RN zM~Z`2tByMo$DH0ZM?HnBP3v`S>qaJ7WWmVA6v5*QOZFdr7qx&_U|Z|K#QDlpILKS zsdVas4s?GN5+}UxNFKU_&Of!<%AFahO{wp2z8&v8t%cPH7t@D#u8qQ1?bh^G8sfXq zBCm4AZ7EDDst=fm@y-n3mgwD)BJ*mAH*ko9o(mVM*l7oL$AoY|M0#XGHmaiN?->Z&7Vx@|emJO8*Q^L*wnqzcQ+k(eS8i!|lUN zMUKpNvaxr?0~)?o_7P&h7Qy7YPjIUzQ4PTLB39S)Sri|_nwh;InpgYitGh=)qS zUD@!GJG$RuI>fSc5b1mbqN}9R`st82#)D?2Yd&<|!*zOYOWLSwhGR_%NA7QvA=|yB zl7^|K|I&Epec)|Qu+jn>jdydJ(?amR{sw%JWdr^egJ_NqVwLZ|DiM*dKtB5wInHcH zq&T07Pw$kQfy-S1TAbEtxtV_I!~jbeH>`KDF0Ek z18tsNrPI}iftd*l0j}JElDQJaU`MGZSKQ1BF5i%grF?a5tj&j|T*Sgap5El?NR~1` zSe!nR3YZ-=l`B--zGc3j)}+_YE4=@qUfMw|(M5L<9MP`qg*no-!Dx5`85%h+fANu9 zZ8L*w%By-ckY`|=YGKaNy)1Q5k7;Y_F{QfMzpi%F>*^c+9xfIIZTU`GKW>&Aqkoco zr^y|U`dgC~`{Q;HsC%y6X7|<_SYXpkXZ1Ga}1s4`2TmH=S z5Y?NBB7TwuoSs{$qU%92!eN``U*l^ki+zI=w)#bYw3*7ZUwp1D8n*}9r9!;+O$Xm@ zwy(J}n9Q}E*1nxvRqQOQ9ozF*x}EPMOYpcuJ-q%%ExK3{u7QSmEVfk>K&;gy;Cj1a=q?Wj}BW1N7SQ)MaSgK{$kIYA(KX zL0E{~$Qsze5>dQeBF_Tmr;=w!FPbqV$~wD(jw;`I+1yusjHpDVP!|9Wr{G3~WNj&# z(k9EFAoSRp<-w))iGxql+-X)MzFO`-W-WKcbbdN(1byU7PsQe?2e%xTd)=Ec`EX_a zdcHigYHYiihGk(7c>-t^0%YDV^5fF5U``kqs3J;bzxoTxd@!ZsjqakouRZJ`;56F7 z&Z9Y4;(^1iK13f^;<(;~fWum63L5F8+N+7mnta({r~wLLckxAM>mM-KPMjTF*uR2> zhfytL_qAN{xSg-hCDhXdB8Pr1U0%9Ew4L06rUJse5ly_j+W z?iK;hd2b%iUWn}8p})ReUl4A6U%4QE>0NN&n`?S1%{kjtg_aiLbX3JJ1ZfVPKee() zD-mf88yNw2!&c}`I`}eYY&&8obZzo4%ZrAZs`k$74!%2&E44qjeRyx*)Ns)G+AW|` z2A6{Eat3g__#yDE>xQ-okR;c!AZXa08TZEEcXa&dTjfENeP#ViV=p32tQ;LnK1=tn{RZ z8Miwh8MoG@7(Rx`(3at!God@47Rjv1WRp=fmDXQ4~)d+EWh9GV?&~e5~CIUz=+n ziS8Cd5VmVzOAsa(l#cHd_2vVo4~6bpN~o<(4)`~Qp_VF77Q4Jn5w&WyE{zuyCoT38 zc?OwS%qcEZoDgt*tVt$1zJ04z>@l6wLH^R)Eg&6cZqzT=NH2%EX8o{&tI^eXlbmOw zsmPq_H4cV)M^=A2T(&$OoJeN1c=4q?kj(MQy@s_NgyIUag*ew;$c{Kx#8U5VZSP~A zR3Bd?TU3D%G9@#jT^fD%U~_x9IE@H;AbggSF*{m`C|j&9%zv#2U~%)B z{u+1Nkl-eCL=<9o4mZu;I!g=WA?a>%wcFa%Q~^=t ziGDoX=8J7zRJO$+qqi?1UDjHBvi{pevU*orG?CS-3kR^Citk}#I+%EeX7c7yAfJp^ zFrp~;d&a6qDPMOqAH`xPHbCG-Eao7Y_z8Kr(|ZQEb^$Ww1~|_EChtXFoIy{xw{3l` z6Hhl8VeNLW?%Ke;MBclpG1l@oEFYgI=k=FP1XG5}7gm$3p3^|)bx`T=h47-a-hGv` zEwd{dM4>z841O|HBDGb3JYhJVgEchKq@h>xs3~1*xtwL$LHp33qOMqUtsK(ZCvIz2RhWI$?BS zf?<30cEYWs`QR0juX8|LxgN#U8R=x+Hg^{Bo9!|S2*-(jA!~DQrwsGvXOnetxq;LP zv1+>q-GPbMD7;Fp%ax=m-AkZ~%!@Y=x&*M6Lwr`3fAC6lFE!vlOXQceGFYou{oh>s zdF=J##Rp8E8P(1wFB(dZa(i=p7K1N?GEP@_F?-E|;TpHvitIsB+&*QnG$sZah|u~- z?)zI?CyO3771+NbL-%8EY{cz9Ro%rsDwD9>!)F2uo3i~nJ=LE8MX7mVX3(73~pdoK-=L?T^1ilAaFZ>%;;OYsSQ zaSdpQVWRpjtm#&?xWWZg!57&}h#&v;g<$02DAn_QPYpb(b^!!=;?p(yjOhOA@=)j) z`(Czi>*7Vw?9s6wWj)$yip%h3#JS<4+g+4>s;||7%$9ItS|z!z0^+Q{8JXDV>{tbD z@dMr>&lbEBIjLUG=?GtKsN@Q=yD=VK6WestCnOeR4SFQCinrhbZ7hSfkY8{Iw5leCL zzo>SmL+8}wai*ywV&tH$4#)z+MoMc_%A1saEP29E9zFmC{Y!I1`nxVNaXF*r+D))W z1k>x1V-#7ghX^Eg&s=Tn=gsvu--*}-NGX(waugm$*0xG-z^IoAAF8JN0O#ss&)$`4 zi2BG5I^iDjq>?0?N&@*#b!_U#ll;#rv+Hvu{Qf&JP1Bb`Oe$HrRvZI%Q*RVZMRdu@ zL{HIq>_NM!6!t5T@?}CtDi^S-KG2xlU(b-A(DnHJltS>9a&g9mjR>kLozFW)OUc%!Rie1sY_IWpxEp^;8x z*JR9w_lw#86ij5?ak3s>%&t?Iv2y-mVY@u^^%$iKXlcIr-p5~&t{NG6eSTy|Zi_AP zSUi2+1ofj?gK$OAQ0hZ~&}cx@vLGoT)Sy{01BZOuf?PV@tFws(AHS%qqa&l7*GdBj zCDrpM&CDmBFl@?7{#(WY9UUn)CVar^qVeG2B4JN4HkQgBUBbn?d49==ST1ECq6}#i zdu`dX4d;_K5Ir6?{(iIZA`>9>{1s|i7C5#pN65&0S`VwuP2qP*f1fKQc@PLLI}co0 z-s7lQvtCd)#7^Bby_t^kYAMOu&hv1P(k20H4QZ)~r4A17nk!%<7k+>M*VcuMQ1SfA z1AXjztx%a1=E#z2ugZKJY&Fjg>9O#>HmBDu6R$&J5{uy-YC7uuELS!2Q0o)e3bGmg zjhVQQ8N!WN?lO1Odbqztv0CjazuZ6hF2BF>XkY3>M(f^I=}EucZ=*GgT&?UpRlL08 zT|XWhyn;QR(UpVT2x8W+>81FCj*?@@N8A_>CeFJOPD*_Oy@0TBpa4MCt-=f8`HfOF zLmaZ_i}Osn3>Ci55nub&9XG$v9d2-P*O0SgwDG;a*i!-X?a9^cQIUg(1)rXeV*7-* zSmm^HLfm)_>{!C-Vo&rMfTzUq9QLXGui$wExU-MxckrpCLg- zIM4gWdg0v^w3;zywYa|8dyp--SdE4wO_n~QBXEOt`q;Lz&=_F5?hy&dUy*I1TF)+{qXttD&c4#AzXi?nuO0ZviHI?u`)f7d z{k#%(RuL;jj**LCTb*>4N4ea-G=q&e^dMZkxe92K`=eoj?~du{jQcIcrlzK*q^JMU zT(iJwWBjk z4xvO_FS#e_(F3l=&PIn9B^a)Ay6hB`67;WFg}AS!v5VTD!N+Pl51?u%;DDeNUSEvK zVDACHQN_4fr}1Q%>W6orW+x+zuu;Wk2>&rORINk>kM{dcxG z1GE*Y1A^g|BJt^8sbE~6w=%7IoLFJLlcqb*fh$6t9nE%@3cla%P};og;M+*74>XA& zDNA7wJ!|r7Oij1slz-yqOocV7I8;>RdI(2IXeiTASW`pRRjEnlm^Q@!3E4F!*ftj6 z>>GBh5|k-ddt~5wpj00xOW4~!peXq^mGS%{P3sP*&2yLt6ieq!z^lZQ!o_KBq+4;c z_A-qG=wIu{X%0VXl~j#ffVHj=+SM!0mK*Os8Kt67=GW?wko00-7YH<{T;JE4WMu$C zLP*(fhL%kVX5;o3&}4bSm#XZ7v7*4k)r!C$2P zRN;I&jka*{PQ})Id64&6cbTtfVgcQjyms0_0F;H6H{aya_-=`OD36c}L4l2+^WooH zP$`_d?HjgDi!+o;m9=RIxgQHK+t1{Uy0a4QtA)5;m&*nSNOFfqD-O#J^yKckTl5KN z*r*J#b>aYOoBYt_Pl~LCYfR+1!X?E?Hvnrx3jy3-IZocZ%10Rs%gFE>$o3ksJOjd&yz-5J)!Hk}(-p}2ta&5@%JR1l7ww3!=peMY- znD&15F;4oo8*{TxjnNmLj?F6lJq|Y7)<=GujeB&x1cCX`Uz2LC0dsoQ_rF(|wfN`R zjqAy`1?E5{`&XxVzvO9mi(e%Q%{D!A8J2n>3?z|xF`$?X9f%>F@qM@;0DXJ(%_(48 zA~eVC>BXvUFvRZle8qIIvg_)9Q9{9JhP=`0PZ=@}GI2V>V0L@}QjDo^y~b*d3-E2J z{|~{ED0J1A3*uV#M1TtU@7qp^EolIx;sW`tZrdPqXi#)xT@HUARiWPCJjKjro`)<~ zTX2nmua?*n7SwzN>!uP0^@hY=P!g0ZPg&Sg9S=G8{WMHc6?{=1-Qzn4fa}xETtkL~ z5eCbYVhgojvTiiY+f*3e`9{w%1^w9;9jhu$)u|4p(M9D^u3m+pB z?0C8GzQ(PWH=9RfgSNIT4x(q288#zzrwy}6-;J{Z=C;)P*ljK%kqfWkGrIWZ)AE{C zRxRX@W;AqL4bCFyjX}%f?EF6VEIT%My@;;S-8w3x@F%YFW)~@T%Z*k$C&5np+zwC0 z-A!_!!_QGmM8kXOv_q)(wsfMQ=@z*g>{DeJ|y`d-PC5I_&v zL6VlLhJ5hBNX(mkH}P_NhbvQ0G>9FD^xlWP{Z!cY+C*@i+G6`W@f$bap(79t-NVoN z^!-dFau7!rog-s$JlEG$U31(-JbLHm?>O^Hz)QXi*#L~$* zHt`MWRGD6NUl8r=1?e+9hkB~DPt3DZa82m`ghY&Z+QC@3I($;?mUHYG<`6@(Acb7YD=;;zj@4mS+ zjwQ#vbbtGqFx))>@51LhJUG6y6^J`#K6YHM=a@nK<>Q!-=^LAk$rus?PTIwy`i95= zZ$GW~CR;S1150=(iLb}2^9vTgeUB1vWLHzM|ioi#V5E=x|E34q;g=*SC`avu)zjZna$?ng>zYc_G&`kO^ z*INTV3<_9bZQI=gNcyTCUt@p4n#OcL^+H=&C+|e)5w?7h4*lfZQP3hrDV6q*e#-T~ z^ivU>+!~_nj{AGoeTUDc4^e4uT&}C^$;#eCM)Cza|BCpoM+&1{n7nEu zs_C`F$n1eQ$emilB>}U)?}p(~8{})I0^{0NlEDbJ(muNki)iz^B7E=omCX-ir5M8( zv(ihJ_-_ecsGeJQo>|S8Z_M}2I2j(#IHR}(GL()|6&!wDSOj9g9_4HJA8}f&Ny)f| zIE!3W96T&fCHe?h&-bI04V}XLl$=RjoNR}DR9>2li4%CVZ5vMIcVyQBe@-G_wd>>) zL(Lns?S*J+o^AX?{Rk068DJHT1qwiOApw8yvjV&b&7n#V{~SSwzE^^D4)d`k@Yxb! zC3H(&lBz2fgL_R#6CRGumHDXN!LpGT$7!GtB`P^>D)EN#tc-264`W(J%*Hn(i_hAt zlwJ(t%_)KWnWpc^$5P+?r2k_uM^T!TxIrfR&a8%w-Dx-Zs%S)c+v<30xL9k8qII;f zE^DTO!DT9Vs*aGTXFD5ngoB7a_Kc2-Nr5QZ_NuT*N{q?LW~%VLiGjG4V&D0Z0=zOV zDZceie zj|%r;6nv3g?a@l6JfZB=_4}gNLo8QTl}HAV!@OZ)Y90NP6mt7b7s@+ga{GCEUS2&G zviR-e#mEWAGfnX5pzs5A9oz3!$ruj9(;>b!S?{1%D||CckQ zrVP5j8Z+P>c*KC@@#M!_T$UZvtZ0pcqK?YIj0(uv79?^vg}*mzg&2yr_ePpM=!<1d zb*0&DAFd^l|{BUp`YnC4A#ysVd!T z#SWq%49l4_-v@9M#k)CRsJ##TYJ2Ec+ynoBo3=u-8M@to*UPA$k?|n@<_C=&$8Sbv z)*;>mZHd@x2Zghfz9`o}R&i}e|b4?A@CJgjr_C@K3Tt4My!6_1=bmJ-g| zZhXE^lC*&<&u$#JyVc;BjE{1$n2y_ybFoBJvsdirDi|F)4LPlAlJ4$cN{HtS@^HYV}h`n zvegWgjv7$}(u$_Cw<7FIzAF(_)~U(SM4NqmiA*ucdSW-73xo=aD%|oXH%>&1cC$i8 zGv)ti0b~s=tT}Itma(f@v6nhq_ryB=sua&|oBJfn>HYaOm>tg9>sYj604vfpYa<=V zi`cRFJ=3U&&LSS@Wl(cPg+C_0KD{H~ziE~SX;wdSTD@Yz)B2SLv=}NMIblC?}^<}1u#E3NKvL;XTkc?TiPQh` zisA@IMo^UwOLdZDpHa3L)FtI({JZ@7`1$sS>e?$QX$z`U5LL(5v4tfF5QsCQD{dkb zCW{Qti3Bva?x~49(v$abY=TLXT!e;PY?rpweTl03Y`Nlu(3$`>-Zmwu z1Tkx^El7C4$k_Xfw~(mhbU!FlEG?!$f3!K4YR1O6&lkavO=fZRJEet-I7KU!{ed#$eL3-?rz-wL)lx#MfL4{!y*WRgwlULw9#~cMUNN zaF71axt?=B&$(VaFL=X;Vb9)c?X`ZtZ!PJ!&ot9&U(de0X1HbP`3YZ_YAKQ)Y z6fU@V7*9M{mrO?sLy6KUJZ^`SF;lV@Jxq_5naY&0c=HZqbTSE3Iyq$6zxLzfwnZ=f z(CtS-=J`8l8@GH}x*WNUB<5FELGtC*M~R;_+}|U^$4X#Iyd_xmRKKYrAa6m{sPM3F zE?yn`zS{PPaBqKkR-fCmQ>sTI={ob=G&tplgUkDA>It^49K5Q)q0c{>JQBYCPUQd4kInZ&Zi13d3$|36i$Uoc1$da-j@8J$+VAj=xTmYXu|N-?Qwh?(d#U%0fGn;{{@V zk^A9srUGmEcs{m~YTsSy`QreW3Pm?b=Ybq`v++@H%d`WNWJ#8$*(O|;U|TYvul$M2 zBauia?qg1?znu#MDLe|m_QN)g4e6#2Wq>rM5Ooa$;)kknfPPlt8$)(X8(43e&9@VXihS_eWU?YCQ&68Qjvyr7)%#@BiMZ7uc(4bpl!L0n@6N) z{jKnnirxaPwl&?xs*}*u0FPk1J4y#Li0tM#1I!d{H#=8W=kZH=2a)yyYX&sO6VXHrYK3l6-B~; zU)8z#WAKzr>NY?kNpG#a2sltQXuCCUwtF@@O^)v{^$~bIo)pAFY%E@nl1Crz||Dz984)WVQ-g!`moZ1*4YM$nt4!5 z3v8^*kRhSUYHdiA_q@J?PAj)}9T8?=ojgtcP|q+zrrx7ZwuYJQoojGz(2d)@om90}d+!FfZ== zw8z}dpx$nLg2&mhyrAQQ?2hcW-!K+;_x(KU(lW#GslhKa3Y)cu6uZA9UudgZL+u$T zSo#30Zx?Z@ja}X{Xh#fF$NXc;0Ad99F2h<2eA$Hfe3tHdt1BRfvrnZc%F4=4hP$=x z-F>scdr%kTD!|lc!sY45o^-+bTcZGP`!`g&!@XYLkJIO^g_o$2nEf7e0{@yaHg01S za$h;f8n*`jbvPjX^%KEsZ18&`Y??0AjWf}a>nKXIKa=8?F`E1z4d@@=&nFljOW7X6 zti#h(h((zIrdCzXc#9c+g{N4h+MjnDyZq;B1b2^Eo$rSZF3|AR(`Ra_rOcxGlZ}z>=~yg-)LNMs5Z&! zZ4w7>58z%X}-uW5y;c9k+#;{OxyfOXd*TWqN8+{cFnGnZ|Eyn;1$2T_51r3gL z@q53!{i1Vw9#3O?t3aPt^UT)vZfvDe6^BB5F&*Q2ZJ!aJz|XGOa4&L)QpYkTJUY%{ z$cq{~g#y`*w*8?U7xc`Y!i5x2sUPzu1g!i2s!-XTYg1y zYke-arR_wctd8RGDt_NMUGtn=$24Pj6+qV;5nil?f3c0X>NJ1W+kc(Qw$o3LBv>ub zkB?D5_!YdSYB~h_c`P@)8$nY^pf1GerzM{HITimohKVtYhcEpk{+A6zorNDuz#CO` zp&)jAT8vd#=BXjC2#!3V1 zrmN?44F=2gXYm643r-gnn?%A+I+ppYL%oQ)++o8!X6tzTgT;6?#@Hm_D>It*N3y+-T8|uPhV( zzgPbP)mMJoO(WRh7NhT-z%e~EEC|mOC|5re8E@Qm_Oq9oh73y1BrT8av~=L#pA!S~ zlroxv_0)DZby@=CYH?e=w(-UDK*QQDxI7rBXTx1^O=&eI9vRnzWkcO=dkURN_xCal z0|Dm@n2Xle*6Quv8SP>x7K6Qdk!l{MUs(^-+KYAR3S}(`d_}~*akzEh&?xn4ZELa~ z*1IL~mBu6Tl_3WNt9i}1fuxLxt?xs#?%B6(`rWaKQhCN4a=ETYToZ^?e~N2V4f(gk zOa)1wy#{X^Doa`z`Aa_#cTF>c89Ln9C|eOw^wIb6^wxS6(_*cZHkzC_|HW^akM&U<#C*+&)1tftz1 zu@-ggh98kDl4-0@ByqV?Sli}W|7k}8GgwRpNI(DPj+4LSVO#%3Etk{lUr`p4%crrQ zYTculE+G;|k|g)nLkfR1`R?7aj+(qD!E#e~3yqZ#V#l@TjVpaMCTWEER=*^xKsah5 zc_*_lWxVSATdY)zZ-$6imH3eL*g2WO;6cD22B>k5>I5)|lfk zNK^hoS>R9{PsR_ES%>lNH1};l3!gwq^7dfJd4TH~((}yensu^v%WpehWJSjPvtGB6 z@DA*ND^TjdLMcU-tJ_ghH&r!iGSEFUcc8J1lI1hJ7h#TD-%x5Vhvu5T>gJK#kIW=A zeq`g$c#Jo$jAo|$M&0nLB^nFe_HP>oPqRy-4{(oW7A~HLR6n#g{nMaCO+%sn#a2w5i z7Q)ZErBFOZG9xZnB#!vn%di8rNvz}tTZT$?MTea26G355K!n4rUVmf4~*;0GB4kBr^2M( zS~dj<0tVNzC2BPiQ)vemt|L|FefL>6_9EroVl#{e-o$LD)o=x-E}A;Y4DA+n?gUe{ z@8uOVe%Ew!vfn&+{|He!jeGoC2}!nHG);)pV2dC&9YolqerYN2PY8Xeuj3DYQNX2g zXziVAH(H`fWG$UfgT;|ug#B|W;jBb{d#xAd>O`MmzDY=7$P#fdrmR%NzQ#@h&ps$5 zrljcv^?fX=uPRBk2+Qm^H64RM2y1C8OPyDr9PvmjIOq6oP9f&C=4`c>20CxV93r`E z%jkkto2>XwPtdGSKPzU{@AGx}eR6UOg?A^^j5gXX>Zs~DU6u5DA(q$JWgM56NB5$zh4@o=DmhID{!D5uh_Ayya`}+v8nX1PN{3Hx+-; zYLuWOYFW3}B4od^oN;kbN#b!m&nI|wrNzW}6*X_O`sm>X>X4D?xm+r~ai`goYaJ+k z_c}^C0ElrqI=afjYL#PcChR=$j*=#I0rsi*172V!C0G2PY85_lA1qkKlgHf;?Qg@+ zr7AZ}4YaxH5~_DK>%zVwquAvfy)Ud3x`~CS^nFY!NNrk(i_ZIY5(y!LvHT7?pQgl2 za3r~dR(!tVnI{xl4j_M7U!!71Vvnq^FsSzbZcAn!3^^2ZnJAd;IZRbv%tj!%IlRAA zmrz>5&9OM1uG*-;9ja4zI7tgL7cx+pN5E6TI}5Dva7C#vOg6}7*u%lB@1)Z#HXCMt zSjjS$NCWt9iSphW~j7vjZ_E<<$4%C28qZ7S^;)02f?O8 zdwfS1S^8%@dYg&2~k~A1)<2QT`0UOBm2B z6tsW3wHa3>@fQ>Izse)V#<%VZMKAcrS-cS;M)mcdIL<%z`p>)?GQ`VXrf-VWbGH7+ zbdQwH^@iL)g!cTOhU_)yCGAp0mJJ|9vq{QF+^ zx{^Dw%`^3t$%Ek8J$z;=Uv|nPv8{{-vBY>6VC{Cyzq@4lsZ%T%YK+PpWGw#av(8bR zzPkv~nTMI8w`xicSe{$pat0txD0Ph2T42gJl~3@^hh_^#d?)59jIH_Gk-i4;(yCyE z7@A9*3I|Pmh+#s^FjN zQ6dbEBQYs{HebT!^JW%$hoH?(@_}D}hW@o-8@Bzlfm3&s{?(+4jz~$9hfqW>VqwDn zU{fzC5oAaTMu>}71~t{`X@HXV*WUDK~N9zB>B+G}-iv^4p-U_;q2)oVU%=TzV#T5u)O{r}c*<=YJv< z;0<*ze&t#bvwkPm3u|8TluI6^S|gIaSg$`7^h?Ue$j9dtbW!?$oAy7|-QVBB-$&k8 z_Z(!QvW0eO^Vab&oWCOtqMPXaS6Bpmnw3e35G?za>O`|WAUJ9oNo9MDG8saGant@j z-amivx_r+_ATpiw$BBFIvjy|Ubk`4NSdyL2&9xn9&GdsDq486%L0a1?K;Sp6DV7}t#5@>G@ml)r#N5RPGn97 zWKVvZWTCD4_jT26{Zpg>9&dHfO{~AxM2YLX(}7-Xs!X?ESd(P=2q^i{3lqyd$P>df zna&mIAd42TDz3d2I6&e-O#`CBz%Ksxvj+ME7m)2&0HxJ!4cuz5@^hu&wuxl{?5bt) znli{oYG_UsQDULh-Ev4(!133az)1zo;Tx^Pv$|HqoU1*t-Y&@@evGx;3P%Dhr{Hq0 z6fbvNo%hF0kheuT@A(C%)Q{eoX|X|CuJFUY~fuK3c#nPuUWk z#^#y24XTHh+n1A<{`lcy&g)n0M1(hw-R&b8AX9atOK32g?+C36HS>rpAw1q;YOBOZ zxuO~2-_)a{HQaHaKnPq~5$Xi12ww9GE@-?9BQ7M-vYJB4AALwVb?cpYm?AfKRI99^ zj3)Q<%-kt{pSK`27XC6UyzkcBx%Swa&H~Bk-Ph%&iMpyZ3a5iJM)7E`v`=;Uny$8A z19gHZv$c5S_m4O8Fih%MC$khlm9o=YHVfj}G~Zpx1dQf6lqJVwrY>W9%eih|^T}Ggud@qMA1W}WhR(Gxq%1>#nem==LH_Oi z)f}gWW|D70NF=hG_*#_&N$pjFk<)ZTR;NGOl#oe0%P$k?2&hiP=Gc$5{#`H?-qOST z|J(yaGAkez(!^`h_H0DT>MjNCOUNLJW?L4UxB)un#Gc}~xP-wK&%~Nqgk#|I`V_&) zVu_+}J-B{BG#4b-VRDyTDwC4fj>+8`|20?TGNuM;}|MT`EF^Om`)fd)Ybj~iaC5M_n2M+0s z8ry%zXrk4K(G+#Q;UJo8^%#+Satb)ral9CFtq)PZ+^pqa5CrI`BK$z?K;4$~DywZI zRYf44t1x}VwStI9RmNejeKBe^Xaos%+)!4MlsX*hPa-QA(jDGm-)&8;d><2MErP(* zud^4|{KTESRrq&=;c#E|%E|SnBk!2F%f{9<|IuQw`OAfLtg%RNI_coY#@o6o?y{)9 zlf1F{syLTB$gSXqaEOT}f&?=ryX4Q8*-OhyA-_Uo-;<&=ks&;v+ISn2Lnnl%nl9?e zoIE@FzGn>{Gvu_Tiy66$p!IGR9U-@-rI+ z)*qBNY)G;~EecCBYjaTsHqXBuuj1Bs!!z z^zL6ZC4V~dQAB_5vM=dwgi%YwQ`qxK`!k`t4k_!8-v6?-G)w(^shB`xb`Vl9)BjE( zp@V^!0x~vpV5U?M8BhMn2DLCh%d|8K;`X#KzaRtO5f!EcGh2A)UuB!(!zD_$8-^Ig*a8X)-aB~f~bvMXc-^gFYG@9lX&gpOJBdzP*EV8 z>3L?F8^G_T6%b5sUcH{;rRJIRA@` z>}0Z(ON%p^nSbvLU8iyo!(px72oH(6M)W&)%JjLq^DX7LBM5gR;?sW=V`48ItgBH| z+0HYTxQfX%`!OiPFPFz85(bOv*Hki=2qVNbh_f?p2}bo+9AVHz2x=HW?LS|Z&^ z#~c5>4UVHC&-f5Tsjl07HWClG{!tWWur^#)Za=N&=;SmHyG&>XDr3p^YP4?D)wcp4 z4)5KHR-J_#)AS@pF%fe5Jvk9%IECZ^aVO_cfa#-!++SRM{T00OdFlt8 zF9|EY5+%wKIYU)3Kgw*}MX>Fj%j{>`Ehe}AdSYMShzf1KaNsVoOi6eWcN@+YZUvw@ zJry*wn*E^uw-$icgmuQ_hW+Hgs(yQ&N29uecvNreR^d!dD-!lpQ+5jQdVm)s8+)1w zVEPv&)V@QdwBuY{q!?j=OHA2~=s6%1Kod_{Rx-R!IT(El!eMkgczMmv6jn$zO|g~& zrCb5Uftz#Eas)dmokHA z-&cp(Y1lvTGLOwoNGpUPpKf6QN*1QUZ~TVD(Ht*RbMRJx#shucM_4gTbf!;zXb#rD;WX_v&w4HXGn&qrxzw{=}B2p;mw!9WvH~ z9n*R%mK*#(3zEB62DkPfI7op;BMXm763+MYLOd+`L_`ZaCI}z4P?&U+mIaS2?=4&1 zA1SVamfVN~sIg2A7DK+SvU6G;Hl8Lrsq*uG`&s27KpU8gJumJ|xSlrzs#}B0q@JWFcwaMdq63v87?w~fq`*yk`Ac}@m+xQ)yN!R*tI9Hh@ zAn17-8T5yNV0Xh9Mdu83_RfrCTSuJP*@;eR3ivVl`D*VQUB0 zk*A<1H!3tJ+V_+hIH!4sBm>^Qjh8$1#pX)Bxh7pzz?$sEE%v73GdnSz5fq3-T!k3@ zI=!Npznz)??EmGlvHDfR{oRem)ugARX1KxNFO>a7M~pw@Lh?05yzKxrkJ~H8m5iRB z&YceQPhTdm)PU`^6xL5#a)7=&f-5K{<%9mN!eNE&AtaBcAznau&IbC8nXL`Oi6{g!WwRO>DxcHFt9+3Zn(j1U)Tk&y{WQN^PaOlDSl7>mU_% z!7@0{R7s$|47%}M>P})F{6>aV9^f#l_UByq@hyfO7SkV7V>s+eOpk1k)4kt+?_mYd zw`lLp&|X}td&b7nj5K6L2UVa|rH6K%aGsx&?Y~dc>8Za&_vRG}XUBRy_Jw4iQ??`m z=oZIXm=cxCl2bYPJDUAh^c$b$#Ll*Wh;%nxCl3M~J-}@G^SlJ%Srx}^PUg6}UPWN& zJ`Yv_6yNCfEqRLDsliCCxo7H3L?2g#(;(>bWlrjF3D)Xp5k!mddentCRwF=|KjobM zmAmbvbuU_)fRq>$cv|gADCDmej znFvWw==T7)<90Lpc8*X(${!b6Xbi@kDV(tbC`?(`AG|qumWC6W^Mw!UkDGb;_L zWkOuExvF3N?k;l3d_Dev&hE|E+&oDHyVcZmfmrQcoHeDGOADs-bDZp|9wG+-8d3AO zlN76-Iz@%lFE^Gq=Zp780p!U&UKL^5_LI*C{I)@3R#cMk+5YshH_y`=x8YfC&E`$C z>e4qhMr1Oy#(ZP!YPA6y&37@wQv{ml0bd^fD-Se?VgA39I&Wv4Lbp$`;(=!uRxbBQ zt50f^Zgs%NJ7PcW)%J@~k}Vjjr_YN5fYp$7(HA1YKED$J9P+lQiXbF#lwAnd>tdi) zgA{LF4=X6^jhi)2Cykm@+Hx0%9pSmT_Z7IwKPpX@DVE;7-5yZ);cNw zj^7%Ax>c_ZIzbJ|N&xaO{%K|E}eGwl}{vFvBfLXu#jqKC7y2))s5d{5pH z^LaK~?To+AZNi@B%F5ot+7D($J9wCP=6J8dxTZXEWOU#S_re51Hb+)x$YfEw@l3X| zthu+m;2vw82Tf{#yZZCGISdss4SMs=19{OGEXgs6nj|BzL~djz4Ds4B+q)>cwIUS( zp$`t&MImzn&qf*+heoW09<4dLU0H5~^^HC{BFV^bPT}n<789#v#3z43+&<}Cnw3Sk zN{-i!`i7jKEb^lI_<+yrnYD*tQg=~JemucMR0&Id0l0UE|3%ye;UNO%{CDc>unFzX^(!^bD205y z1DBSzc;(1Z0QV_g?cDTQZ=Tgkt4$|%JS;LIA#CcV^(R(9s+iXU4H|#w&JIVjw@2r4 zGgMTF0Z`GO-ao-(XX@OO(5y-P{z+(fHta7e=Wq2dR!;74J9`j48VHQsRMyfe&E*Fp z%ga+~610Cy3UTLyQ3k+_nCVe9iy1A?0yG~j=^638yU|iSzntz7(qt_5X(cRortp2x zXVxlG;=8%v(OpIPzF8kjr0t3ISz#1!kRO zo@fkR#0wYa`SJkP$>ZUL^GHk7>F#ciDgwjp<5*kKElIZM+=x(Z0(D6W=90vCK`eh6C81|Ch&|({UiBzD6fr8BVp9me*A4rnU za#;KV1dCVd4%12)pFn?k$M;5^0Au4IUJq}*De?8{w@ubj^>9)?kJ}HW$pSJHyo{B# zHVOqw#Js2CaA}tNOZ93_PZ%9x#4WL=ge`BJ$^@I3iG|cl#kiiqwWJr?sVf&vtiDNZ zUHY%SeV7&z^o&0pBj*NR6<}gl>qe&!ZWjC5K6i*>fbE>Ro-0)i2J^oo55YfExquAu z)E^B?e1&bsd0(zSCEh$fSBq=-!~}X_)bm3&$(4}`+4yylMaNF~XT>T|9*)q*uGnulC8BQik9j%pb0>UX91!Ln6kO%KMxk92`u`zPw(4gnuSl z9S~;20!FNR5~e(QDx))hyo-Q9G1Wkp`P$^Z4;$j1d4;jK_j^;F5jG7(_lm+F%UCc) zA5yTgk)8YH4acjDXIr7uaduhJ$m}ty`TW(wmUQF4FwYHM8cgM~IsJ<~?c53U7-Ldv z7Wm%R0`iCmOW@o+<(bWB_j#1i)Dgbh9ouz4R>8x4@p298+b_jW#d>(`wyB*s$t8k5 z>#h3KTZfE^YGnZRB1q9m=6|3N#e-+KcUe!2!po_+wv|vI}5&xm>;tMlLT)AI8fAjSyvj*q#_XU0>x{ z>iBhEx^Z$xjeMP#(@jAU?1a2E~Pggrf)t2!rEInR{ zL$9d4(cK?1$4T9`c%WA4DYtPu5Rz9%7acZTbHz8=S@$Z}l5O7c<>eX%Y3p-08(=)6c&i8@jpxc8{>|lko}rPRpbV%X?S~r3wvE>e z_FMZipufA%SI})}M~s9+Zw!uxTc?%v(ju7~>B#8YSv@Pr;fjar|4kXE|50`!m4%RU zAFX_N-$gP$#r5W+A3f!pn9=azHwRSgcttDiu0~V}H6ezI77{(;HtTXN!3u{x@}xp7 znqyq69ic1s(dQMCUSrpIJg+tn61C$c{fQT1q`HqNITR^RA?|8+=9tfj*=zDkkeC9T zQG)hv8w^)-EdM2OE!7hLLmnFehThqQAqYU6Z7K9)9>$(^Y1#G!$AwoA1N%^^?EO=m zi}nLmB6Ug0nNg#VIXTB>0#hCX(wIPYG=sY>Jq1s&Xwa$;;uF-9pCoN~`_RSxi!56r z)&fB8GmpGHaz55xRRs{>J;Ea=k}>sE{%o!N{6GWMR9EQm*)J`s8tAIf7!+KYiC-wQ-Vs*dMQg${>n`PO0&JW|FRC1LoLE9CoN%P}zA6Hb6dRia1EoK#+ocV8H$cY%oZ7z1 z18w>A-&Kx;B)t2BLL}I<#|IAdLoM>gDc&-*gh7g=JAd;eo^?s5C*Hh&0xoy2+9eKR zn(giOvP~<99IC(kPXKOaS-aEgPrB%oS1wo#UQ0cr9+LGJ3*_$jCXU)kNF)~916eA+O}v8{u`qg{zxo&fs~C zU-q;9LD~z|*b0X4oA7}H@%j!K+)?Ywc3Fobr(bKTh$HCzz%F6_0hYu*_vBx>|Eqx4 zc8In~b967o)>LIpz;&K0$2CN_I&et2eFp7E(59WS^CYo%(E1kWj!27SYAhbbBIkER zavug>$o%?g$M#M5d+*NdA(pcvpJa{ZGn*NCV5-Eaa(>1WlRzqpaJ10I`HOzQ>4}1e z&0Uz_<*Y8TI7PwDYh42@@FvIm`)`U3s(mVQa8)G6%zN9@mY_g8 zmaH#L-v;g}awJwJaU0&QVO78)53fIqT0lI zm0tj6E(9*FTMo|Wp42Wt3hF0OrKkFL1QQT4ZFuMW{Wy>it+a4$!eLE2`D3>T3a|^x z+$VfH`0mcOB#iNdsh6K8*)S|*vefQlRV~@!K&(+~O5>&QI;df@-sqYmb_kY8mK=`W zl>dNw`KIS%K7^6sq(dQzUu~2zV@Ur5@QUzZOvy5Q5P~OL4#hizvuqp`{3cPaapY}) zlxlwtIe;^v2!pLio1SdO`Wq|KygqIFIYvguJOIU$bLBc8Jd)~%y>YL%N%aMc3vB~S z3)x=8+4Wxu)rXI%j~ixejN;qdN$3TF3a#OB7eR!mUrZTxOI>rf=mRZA=`kM(CcADA zUZ)7!Qt1KWe?HQXWall8AtKbpA6O%fJoD0fS7N!G%3tA2m-cD6k#_~ihIR-<+3OG4 z&VFIr6I!?iWn23YZv1#48JzNcsj=BpO)&oZ-8I8VOVyha+E4~BCj#HX=Z~!1qbJYQ zRXMCxUifq%xDoy%a$XgPJ<6Y4^%|wy>D*^=f;!=N9K{tmoapue5?J&@n9VsuR_2n% zv2^<1D__R6USQ~5oW+93SRdLOwoS;rn{Xnu0Wo|yne(_lp|P8l6U8=PIau1{q{N=y&%26;oeZq2DnQ zTwZi|x!)+!Qh=I|BWW`w1Y7lObV1awPFs`vK*BvX3ave#E$5+k=%v7|!5u#KUgB~j zX1Jv{5b6zIX!Z2ke=pH2Z9lCyp#gyKP{XpOKriXqFWZRTl<`k*F3W<&lvzZR1j80f zL8&3{@a$D9_B#u_o8MBn{lwDsi+iewUyZ5*d0#*E-JRM!KufWrfj?*6#!y5>4o1Im zrP_gK9XA`$tl|kVlZYI;pe2;%?UfF$#J@=xiMSg=oyL?J-$l*te&){5>-FS;9Bq}P z(7u68`7J?@toD}hwzPb|Wgvo$4h?Sd6fQZNB3KWp<}R|g&>elqoKu`nA0wOWPP-GF zGPcJvSo9|d;(E7X=s=9U|5SnVj{iM2?!V#cw63-!+M(VhKTGw@Snow26fx(` zCpp+AXz^GpoR}08EYcHMfMWlbBz(8ehLxGD^dWJSC8vtu=EA-a$_$0l`jCiQ>}0)Gv5X;zJf8Wr)eUaarj!RK+LV{K;Til zzSz&rPe$jF@x*W82dBK5y`6)~;&Op<^uu0Q!K-YfTXm2du_D2UYG zRxi{uflJo^h|Jf+k7;f6nRhYI44+Mj3pKn_N_?8P8&9G7UUAhD#%GtVAge6AI+Whl zIcOEdtMqfTb8L73@HqdiyTEJ^G?55ayYICOw=~-0b0&=m$T2{8e(eo(_rjiBy?b^2 zTM7;}^ZrCfg){38LzsXqQwkzSxWID5+~WPKe{t~eFVV?Ot#rjBl%1Z*~WrP-P| z*nVhefP4_qagR?GL8LP8ry}kNYz&44)W;s(Ux;ertiQo` z#x8@iB)3LLOvFqU4}{zsq>ZGts)W{eZ%zVNKCcV_;+Dw#`j^=fQ(?l*x;PS=GEGxk zLx$7gE86>uZoN~`=tS@)Zo0kYn1|BWY9rRwsYJFTuwWSrkH;f}+t;|hNrt=L_W}-$ zfZg*Sc^+dV&F{sFK<%4=@gHwe;(YsKMe;VapZ#B)0Jz=RS_bO_5w`rvcZ$U;vSb`z zL&+TF^sQe{-|yZgfzbV ztwE)cssg$#+p3MvN>Zbdt&4h7@|?Jsg3gipVeYj zJGr2bjS^yKS;=Njy6wgzBK_aGuaL!+r-LCQd)-TLg209aZ5NI9Zt%y;nIEg)s_h zCY)Kg+zOE;Uq~|!L0;M});nY1Fa>s9({SB7w*6P}|8^^u8r?c#{f!@pP3;n4^9i1V z#dAbZZ}pCEzmi^-4DelqD9ZfIa1jbPsXt*;^GLbmGU`AnZV|$!f^0E+{X#Z7815i#SJZ39H2P_isqYjuhOb(k4W$Jq|_Hepwq=D&?0iF_vhVoLSib6 zD1@vkzA%61HC9qGxS0O-gWNL}n?005_pjJ`!+6{Kp+Unt58UBMuckCKu7gqYR1qEI zN1AJrE9!{cFQQ%&gQHWU^bnV3R~UfYen)InDAq;`HnoMgq^G7e#~^>iFf(tERqyp z40?`Y`Cox%(Y<5Tkl**2F|06FKh)FR?0&+5VJyLc=FhYQOVAf_?eX{R>aC%ClQRZo z#S&7)L$|%ZFJL(HsX_*CX5w{GY`g&@d&Lr?MCg()ja)j@zqCotraW~^)R{#;w970B za3olkCFS_jppi0EhprXs2_yurE`L_un3qj=0F-I+u)@aWcoBS{KeT;B_*X|#dzAU& zIFUoU{1@l8S2&ChwL;hZ+^tty0vouEh@gAcJ$X!PSq{qcrn9e?TRG0f)WQdE5NgiR zGx#EsTGZLC4m4)CbDh@HCX=}G(wn1LA`elSpOUKzIi5yW(t0ISm!Bv=%MDd#qsCa2 z2+xs_=5eKK(C9SdR3ENs4Qqn)GhKc(PWcqns4;2QHM%$y)qZ09F7u+=(qt9;t+DUX zp)7mSQ0vkv1?ua!k*IX_-suq%3PNbOx8grQc5g{ zA%jCBHEApZvP`3{?9KrR#-gOH=(KrQGZl{~=xR2T2x_GJHlYXJu&~zAsDx81WQ})( zE@@y-3Fq79fmW0pvI1C3QfE`Iv_)2weO4TUS>)oWBP$I@c-%BU`~V<2S29h>+=hfIHWndC$|t|T$N`?t;_G)04WZJ)xZ`qsK_Qd84pb(W**PL;d+ zbH>ZJebLoyRmOj2!81R}Zukjf$a-mOh-cixzEmY$9Ge~?WLC>8yegbyRQZXzerQ{* zx7BxFwsZ9b80XmaKx>#|o|Z0^*C5I9HUC;dl4Mh&pjz=bSlGV~uWTJ;HTberrx#xW zKSPisBdLMn%-aTQ5Wd4{g=n-?I;o0v&*`PNe^n2o>aBk6WyYeGe?YP10}_mJ&bUzP zepD-shBv{jJMRy48xtAHS6$6dv$L|jdw)mV-GWV!=4BWA3C?DSaQfJ64b=5dKTMtN zPi%W1@b106;xv{qd&k!A4=(-ba#;6e9R-bt%yF5-(6HjD1y$%McbP2o0KpO3O5nIT zf86YRUgqx5gr%XNXvA&y=taB>@e1GA_^1Lw(I>V?Fw0ZDH~}$W?cbfp_kL;amLz<2 z{GhXBA54i8(YP3wjMdA@SW^!fkbG&~i^W~DK%1piYvRIa10HK8UQ@HiNwE%Sx zFrZjt0veTJ(XF%DHGh-^lKfxU*Kg;S>n z_lA4RoJx;6I-GF1ieqBDF3PV)>7YwgL=X*#cpn-|zB7B39`D9U{5=$8&7P%}TA+h~9i?Sbskd~g@&XgC)?R19L{I$WmCoOUXkC=-Z!SjX4dF4By>5NaE z2fV4ui+p@q*^LaJAIDh3r`1v=Ac)TXGs6_h9q)T~k^~S3-^3>bvhJphGT&&A#3=AS5H{=LChn>Vvu_>_{J`tS=I* z4NeebmbPg2ef6CofkBVE8KUCHj>3g6Nzc9QRg28c{8{%sg~6>V;jo9XO~{Xn;aN~Z zIXmlQa9*kZ@-T4A_9OiL#@4`mZ79}*na-2k(9E4tfy@)vSSrW+LUfksJLe0$FhB9{ zn_Sc9l@3TwIxBm5N*s5*yT1HAb<`JS5*+y!ljU-SX0B$3B9k9Q1+1&G^0vwBCaR7L zggLvMPa+m2Q}A`}0(DI6l5r#$0FBaycWFsSg835di}@j*_u(pll@8qW7WQ-zoYYiL zd7N2obF;$@(iLqB-YfO%Y-=!?Ocjd;(df=^eDPGGHNapqy3}lyQOo+C-N4K{XHK!W z^n{c^$4SPJ`s(d6LHEuy+?xEY5${xhY=~=b+)6t0=kEq%`{AV{v7(5HPRH*)@I9=; zjGeN>oVW?y9S-Vo5moKxp1l6g=K^XD7-c8~0>BV@vWQ zO!v^g{Uh@AJoMs~iw;=cGstU5S~cY~us9w)8levoEu^5O33zeyv}A?Z6D{>q6OySG zwqcf35_dJj36+@tq+E;u&83fRj_O#DGqoIGI+|~Jnw`*3!xKOVz;gys`6vwDATya2 z#6>fcflP8eKWRE|yDc{NLm~rw2Ru#moam2~zYH13TAmJ^R#dDsfF5F8I8})(_AX|3 zPCf3gfxy0R4-g~rJsL8qZ5>;N@cOVLZ$KP)c_IQ(@-3#!JWF9#!t*mOOa#M8)-4R& zc?zoDrci9_Tey*XFKcdcMo3^$Qej=dzwk2WwZJVpRJn79K`&y^#o0kIwnw= zQyn;%CErZofM7kh~BVk50uBrU}DMR!Lf!o1I6wi#y24@iJK%PR5O6r z=QSH=2>uQ{(_eISIo4oQ&H1?^^#_M{Qluv z?>0?7q`8@AfoWRMhP?Y&jyv9zXVTcdd?~RL66RqoW%CP(k%L4zh)3;`!mp>@Z#Zp+ z__1Ii5oepMCAnA9C8Q@Yge)|?Yitfv%Hy7dV12>;v1+8fSj#H$ao4zZR>Ts#mq1~4 z=QU5Wz&A-Q;WIZ{&$!5XENdh>{OER9I8>dIn)(2;*{dx`%()>#JW5VX=3^MEz;cey5FIqPy_d)3s==!*Xz{WZX!vg?i&y$*8_) z$%Mn?Ii4#!qY+)v1P=QPqC^7Zx?r#sf%r!S6U0=vs5IpkwNL$Thyfw1JUEjEH{ja9 zi)?hF@F$vz`w7nvjcCn`$_1y>XTTpz`XEa> zD$W@j@6^n)303jzgs$+hLGZ+1%WKMILK&@OkhJ7sV9KUq}7wmh)}U&CVZ0O_4E3e7#69xRp3 zYN+qP|6JGPCN z#{Z0S?mZXp(|cp&Q?Ro4TD9v}v*xT>H~Qc7r#^2lDOf#Gn3tD_^?HD zT%1HE*=;|rJI}i|q%KYU7{KNqWNk>Zo3jE#S=I+ zO2!c6-%i+=IF0aAAZC386eeG*Wv+AN2@}OLKqI$s!iNFK=f=eGJ19UdG{sep9028^ zA+f4Jz?w-E_Z~c{&6$O6ZnWckUR;@u-k}Omu{*0iscm`@51k&(8=w+sc)?XFJrl!x9sNgxF4ioMYIkaTpaZT2FdyL{L%rPbr~dYNTT#lhg5*LRUa$Pra;e&X$m{ zc|Yf$Sep*lO{`tSG~hBx*4o~kBVV^!vD|ilv^d9Eo*m|zTc9G6dkCCLhsIpNwGJ*96q~* znm9V+yeTUCy>DZEIjByct>q|9UlXaUznkxWubI-?Il>%V4cRc)vD{6WwO>@4+&oXA z$blcDV2yh=qknJi#9+hUI7^^3G?}6jZ$HfMuc><9C7U*pYG`H_hwFq#fIXd7ta}dX z_#R64C(a40^{!8C^k{X3u`4d(7!s>dqBExaS5$58Pn@QUZN_D^n5!v&xZ+oMt~RE{9-f!cFG#j{JR9Mls`L~_4JwJ^wAWj$g0 z{V51I(~rR($&h8-u(I|qJ|*!;Q?6$>aQC53qi(-?ts}Z3cLybMRhw_;ZG4cgKHGfzy|*@^<9m<2Utz}><*Dsg0A1CIxvOH8dhG7X9Z7l4RrCSR`Kvj# z%5uB+a(Q(`lvGEIh+F5)1<45_>BGyYyKb`tbm_aN1-yu#5BOx^6At;)V8rkF%>aM| zq1-Z}`M5zHwxgrPloZmY>UIP?@C-rK)-qy?NgYfgTh)<=lW7uBBl zSgMV=Tf>!NwacVRWlJJM$>={VaEmVFd)HThBCA}A!s5L;d!HU6Yt72&%ZcQ86eS2b^j2ar2*aaG`^fX8 zT@zpBc%n=nSED(I+DZIiDP>w9P7{F{cCN*bgM70(CRS%>h2iZmi{;&jtdck%)&Cji z0afj{+ByLKA@_6IeOm&*oKGF>kGt5ytriAl;ft{$DB*`8`RV=U>)L7$8tUVrY%&+d%+I5tC zSp!vm-)x{@q%2DSAuUkTeI|m<&NtSJ%Gbx~+ATILo4$RY}>G?A$rj;s4NG5lVP{`e3a= z$rEpnG{1TSYo6oCboO{>AZeBOG7`KJQ5(d^z`mtHuJJnwJrWk1q$HM&gft6NqFRPu zTHWWW!Vok_u2Kom0LRCteCOv$hmJ!@V_k8IadqpO4b#iMa1RExVV`&CX?3qxaQTvCCFiT_k5t^aNbEZ_avdWUNU*$wTWtY)(^1Zh# zAkZ@OYN#zCO`P$f!{>?&3>qM0DF)6;B17m2!ly3|yhP>WNj-eg1R^?vml>H@5}Vj2 zW8FgvW9zo)p3O~BJ8O>?wg$GM^>=A#?ts-N$2Tq`OJNTF-nwMP6BledUO)D=i5Lsly)yGknT-caePActqyo-nNl}guHuyf#0ZIy#-_1~a5gngX@6yw_6 z39rHGGc~@bwnkeUqnB9imfI^KoCf`s` zb$TS8l7WTJD}I{z`CXd1jXdf3+Q1UciKY@M8Ocd7>MGi&7nGJ_W@Ae`=VFpP|^sdx})An_mV1o!s|5+z*Rw9Ng z{)JbrN*ii|QY>@(0b$PU5bQ&l8_CjFpkU&89yE})5`|m3qHgxjy%>EnYRwul7IDf4 zr>}RK)!>AtkRyQ=y^aPSz~_`Ib@JV-!rsj0r(e`i*<#%BHtEq+A>hAEQA=a?`h13{ z^d8UPpleaz=|)x(_&jehR)Dwmv|u@Kd$0w;h|ki2d`G#PI==i7bM!MgZyu(@vv=Bu zAbjv6uI1n8Zr;jB`Ad13IlFE`=IjzGkZUQU3%&HH){59o%{|Ll7w5Y{U_@QUU$;6J zbKrNgCpcss&QO|6nd<}qyx_#=^M;jA)RF2F*u}*@-1U(SKCLiQU;yjJ3jwEjNt0^X zs~SgydWJ>Cq*c-A&Q2>G=y`_SO8nYDxRMbQQT#Q!|WZ?&1r zdD>%OT5q(TMObbtFmePHdJ!^hr*teQg(( z$pkm|ag}JDl;z+^+WX#_G11c5M=F7@d3I^-o`IKWANSa3;l!q(4)$8)5LXhKKeXD- zM!^T?eMsZCbE$&YH+Wk_nuF1r1C|kDa4NjN4j*Yf5+mXH07cepiWJ9k zy7$PErd{{-oUZx`FgEUASGC{dU$JHn1=GTc`~~)QX|c8LlYac;mDv++yBmHwXt_%W z@~&6&G25xi1BJ@_dalZI?RPWp&3Fa&uFn?`_h^fkx7@FlH6g%O2Wt~QGAO|-`7ziV z57d9<`z>BcAh&c7Dtbede2trF9p%NoP;`m?FHY*A4+=>1dN8zuXsOD-NG5W*MrxVPZCC>dmm=1w9cY~}*s zIVt7N*|Pi&I2QR_sw3m<0#G-$R;s&Z+OfQ4uyCzn{#il{PPTQF`DI$)8*f9u_x$OWedO%a~g8y8tsQAfxO5L(Pt%oLRq7jEIHxCAi6f#@ z)yh!Ya&_*pdE5LXqkjVnE^olWVF~Qn39LWiyqoHR5ZNwVC3gFx$Mg?p3Psu6f8;}* z@syyceG!7nyO3TCCt9OR+foB8s?&SzC7WI!r0frFVRj^`5z>&>xVst=rQ$b>?=Yxi z`f<{e+J)|Q>yhS_4U6zwnQl1LPSI{j7;hjmFjl5UXv~J!y08rbUsfny4!rT(apIrk z!(4UYB2UgQG)wrAtm~f67>Xv}fT_@x&JVYXAjqISxQ6uHok@6!mi|H&0cRC}l^7{W z9q9vxdpr>R{;cemjJhh2BEM?wFF(s*AAKPYU&KisM^{V#c~)5?q$G8n-GkIK6+gYxye11lTX95}PfZa{ zTo<=_(-Q}U2IXy}KE*-*cL>6ct(lDzrgCiQ60_!4Uyr!-{{aFS*+IW7-+Q?;$E&|m zbaOjl+%2)QElgn_aoN8cNoEXL!2>oBw{txwvtNHwsH?HXP;=c?TDcrJ8DS=mNBK6R zKDsBN+6!ea3mcL=Kx&+}M~j%@QBVI?V%?jpNacof#zZU1W419)sW!ZifV+`-dBxyx zT}G(12+ItuAT$1yAB;VA?2NVjNX#QNg@His?B|T_gD;}e}xP75F0_Nlu5TQ*)GzyTam!oOz7#ZqajA5p&%A=+F znS))7h2eu@XN|~#uDj_?XuWU(^XFDcWVW4 zq5VKTI_*|sRQEBf-SV!YmbF$BTE#Z|p?CG}T-l0cPpvtI89#n;yk!7NsaVnGiU;B7 z3#0pMDdd9lWf5`8)dD)J-K7F+r3L-bYGaD~(F^MZH#+__k_?6i=R>h7)6IGU0u^*a z)LuHq>dp$g)e9E0hr~ZHi8GD$mk&q)HurlSpDo>IaeGe&$(i9sgMR2DaM5CkN!%v8 z%OXbGx45_(ys=3)dlf^M>PucpCUp2y(=u_fvF?g5F>q&5+;8kW$|PW!;ltSf6+^44 z9jG~DJ15BNKVF>i(TE=%zQ3bR;KzeOX^@{^G3Sog^BCHofzBl(W;(@yu5BZbVu9r+ z)Rufw~ve*3Nis! zz?VA4r^?ITqlCmecFIDU1{YoQGj%r>$`V7+wk(o8?L4(9N44wL2=sBYz1(2;-r!}| z4yPcrYNo68X~yz(YXoG_iRaPd#n}ti@6lu88Ara^N11Lg5TtQ6Zrl3Gmh+63^iMm> ze^cEp9kWW^Rqvj2fY=Cu`+%T03sXnF3L3PD3uc_>FiF3q(q8f7g4J$b!}*6e0|rj; z^T5(TmEtEVoVHwrWwU|*ks@VU!IMbaQbaSzaF6R7IwX>gr5L#Hx1*t}zp~{c313a| z!3FX&fgwgwY85%5-$1Qq%PHcTN+;9m;@TWTD*xE;{Fwi3bjPlSn7F5aGs6=G>j@sY z{T>$El|2|{{guVMr7ec8b`nJXv-R4;iq-gyC~CAo)mUgZc6b(IS_b?}#|zCJn=i)D zJ-|+3@7188t~@KonhAe?#CV9PYO#B3>h!F>>Ka{ugD&|QUnRl01CF6l$m!cew=bgU zi=9ubXQDi-E&j3DEv~)wZwF8y5oG0s;Nsr*FHc;A{_U^8f{SZ{rm}(fJwYLutmd@V zj;8E7P-Y~}qP$34ofEboL}FZgxGo#1Kn`NIEhZS9s__hug)^e;V~!bN7p8&FN0X37 zOSC4@hly;N{x2tD){@iz#!ss3^&@^pK;RZoO%2?!*Q=Vg-FUm9cLRp+Bc8-K0wZb~ ztLL{UQ|rOce@jjmZ4U@`yCr?Kx^aydUBn)xl@Hqq;m2Tqw2IrDt9RH`?!9tRG_+ z9HymGHMJCoi#41>G{zD-5Y0&fnyMlG(E_B@Zy5P0-D0n25PE0}bvaG^3*`kPUybdl zEU4EcLa``Ary|*#x1ncgdAP zLsGcxbflOzTxdvsOhKM&v%Zdn)*4w}=!Uap+`9=31~4niY-&n6JTw{_9ww$N&Lb!K zV-;Wsbcn%&Wb@T|xgy~16?DRmdd0z6k0H>d&m4*KldW~U0$Znm|be=)hy~=ZP097YT7y; zY4!UE{&Lf-RGJgZ8UL4%<|?S^FRC@j3@?$^+Xbb^q``&D=v400c}_z z+2ron?ug07h-S$w;lV2!Uj>8nT^5^7jt55LS7p$1soY?Z?(Et)V79n5#Z94w}u@=N)Xu}4p0cP)?8p0}7U}eHDSb6^niqvY# zs2?J>JP$UEY0ccosQ9*tJmV`DVu^Y^PT7$Kqy-bU#ND={9(rc56!fdvL10!iwrSPw zO(=@>8Y3sn%>&(DB-AbHqb!11|8qt%%Z5fIYHRaM$ZVIEZ&6}{;i|LS5T)Ff>dFn2 z|J#;=AqnkfXhk`Ph|J5gL0a%9Z|*A)^m5i%kJe#Y1J5YkHKoJ7u7ev@N1XfOEu|{@ zG!lE5_B+r}mq!bvxnwk^r#ZVBk2HS53|rPMzlyZd;K#09G0`;j@c_k+^88C&+#`9^ zyPFvd+lQwp8AS8-Hvw^XD=ZieYt%Ki;RgE~={hDS(Q1@Y;6%qeGP8;g4u#9t?02h| z`a?}VLT7axmq!Yhj^{)D4q6lq!)t)H*t4oyGt%HPXRssJ`SXrp>&g#W<*BR2A{KV3 zdK8jl=rC;~;qLZ`;p}%`SexT5*Y(e&wjl)SpACG`73(&BY@N9#Xs|zGTp48Uuftd@ zdY?_hf*5EnnpRh=SaQs-Um#S6dXy)oVxRS(0(Jeb2{H|qy2o0Z)(^LSaUWfU0_e8R z2gUAwJwrz77>{;bh!8Qfz5|7q>je2aOF$od6V2%8==$jr{X@d7D!wkB43R1D=*>bc?4UJL&&^2L5hQua(vJO8EuP9_p7fgogCRO&eJk>NQM&Y zhYQ_t`%MN3YJSx~R!d;lQDJlzg@wWy-L-SjONSOQeK$YsoMO-Mh@#Ehs<1mj2adL$U<*si;qoiO4huwCA zpoyeYKO0DfVBq|&-*MbJ!pz@Opf);d3I-3R3jOi>l%xP_0r*3TQ&b|`QBcM370;i` zMZ63C3~hoNSy<)Rr()`p?63g7N|X_rO2_MrWh)~a{F&OBwD7qKX2b< z&m}l-U79NY4u26=;L_&{%8Kn|_?S-DZLEv@ZdlPgA9D1d#|R3-Hv((eZklEa+hM7H z?wp9Z;k_|K#Zu-ec3W<}X$@z!%FGt3=A350G(tPpPkVL*m`?7?t404T+ zGZ)ak7oYuSn^KQ`2;BJ-tw*I$H{(lDI@a_Mz1fNbw|(9d7Q$y{^Tzmp9Q@l<+&;h% zMLx;>^ML*u2EuC4yxbY;>kiCEDwWC?a{PW37pdRb{w@Z1M{Qfl8JdE}!y85n8~4^d!=?f5R`B@wP)-^i;%54+!M*M555(i3oqnYXQ)g zBHx9EgfQFR6&lzDxrNuM)-RIu69-lzZ|~vkvC-M3q@XJ^z@0fRrYv;#Hnrrj#^;tO z9kWmZYfOUwaN%(gDJ2k>Nyi~TEFEzQE)JOD&s+Hv*Dd`YU5E+$0ub3ziP=2cd;fH9n>#-%|L2;B@H#)~It&rKV;S z76MITw?ytYe9qoFC=;R*f&}S~LPC9Q`46d{_c6SXVQMBz6=`C8w!G4yG*+5GBp%uX zI`@SLIUt1;D;IJMyxGmzs+E0)mH5k{2p+ zQ*IkxL$G4KYnO{;D+%%=4PsOhe?O$2`sw;pCbFO+LX;q#g~Vu7@r2t)xH>c9&?5hD zaF+lE6e?2o!xXIN94+~l8Ai5yp2-_3gRj_Sbx5qGTvlSHj3?@7tuF%=hf*&}*Ajt} z?OLQex3HT1s5Mr7`);}_N5ogQCAj-lI`z$g8+fqsV+}L1B~9`xaiWj;2DBz?!iGAq z6Ppr{KN#C+*!nOWUz%e@9|`;llr#p+1i%bBbq;v+#yp=kN=fsp#>9LGQn*Mtm~tr- zsb^>SpdtSg$Qk`MOnc8}PH=W6KX3e1xTs;Hr{bgeVRi&`TwE^Y5Zj1;_>ZM{FinX& zzt1C!c3_zG@0`6@5J8!~xf^<9WmMy7b&4gD)||QGD8QfOL>tU{o<)H9u48(L;uZll zCE%6RR5#Pjywu%QxW(d)G+5U7XRU=xHUl##;VH=;u7LXe8)yRV`{!e%j_>#FG|#FI zA(zHcSHr~5$S7=KI1ATuATeb0pdnx9I>-8!oN1>7@>$OK!9{>nYTdbf@~dpqbaJE- zrXlEONoIi!KBpj1VHlhuh8_Dh1)1CU!r(z&PCZBn*l4DJ%|tbhjkw}Ji9%2_u&opO z1Rb|wh`x$VkIcJ^MM+~y{5e7f6@^HfM+rUCgYvP0J7MmmSP48s@h*PDu#*R?(9-Gf z8M76`@19osqN0ELDrHzp1Kq8vqW7@S9%D&lYWfkkW+M~(0G$629au^(6esiQ>hxt9 z`Iks?2HVCR5!;K-O1GXunBx#FklTRV++m{_{Czi&}R!p0w|2XhX@5 z)Gqg6ti7>}vAkBGx!JU)*?sT_mJr^8&g8Qvj@vNUVfG486eT(OidpLJKCQz7QWeH9 zp=n^1mVP`u!YNS6qakBS{A(FD2FLd;P4xx;?X*z+Ys%}7sd!ztnLaY z34rGp z_nHkLfBQcjT8)hlEb=cTfrKwUmEb$ickZzc?VFK`^2N2yG9Imf)4xk>xLua_b0Na? zS!ttY2r;Y6G0kBiFO(oheoUzw^}BbOq5tcc`-C)!st6~2wV$rd1!KU)a2qsgQf>hs z`PbC=y;=fCG}IsOd#l>}ghFCfCYYI`@he8}^$v0%{(LsxKdkRl3{ArvmLrHO zjTR(KAe>^G*NyGFyVX-t;d-Xjt|&iDJ`D2n75!O-qu4h7f59Cr7SV5Oj0^PkA|NBn zsJ5iW6ZYH~J=~p(cGI6qmnAs;04LEL*ceHFOSuB+$67`9{`b1heWYa3iCoKB!W`dVkCTps_M zLJt6(F|ON`zl)Ei%+G}&$HMpooEgliBiT(@vuV6%P8Ub(tdOzdNsE+fY?3^WEqq{T z?9K_Z!$dV87#N_pN6v^73tiC-I~wF8GZys zY{r0%_a&Wr+WB)3K4B>$ATDogZlf42RB=gk?$7W5g)$lA;mRZ{HaoH0c1(Wq0~6zC z@ZAOT-L*>s5_(>Z6)hVT`zf0aQ!xqKPkzhDE^OYtybN)ouYdXieF;a$>F+A@eK@VI za<$9@Z94}2D1miMAnP;O{$lk|-;@G;!4(j-S=p-!6tLU}j;nP$yRz9XmH54iK~z4( z{(BU6FO)ECZ#@p8=ml-V+h*lGVnn3pt1c>l;`-4COKWiV+wr_OIfadlxn8RM+MDp-xF zO8Gl*z&=aG56^+c4V$45UY78VKS!@p@_-P|=XTR=%N*dp^o?(^`TH3TKs`U?8l$Fa ze`1w&dj$z!yTKzx=U%@*Fhy;QP)Kj|k|KV0bYi^D$g%rLfpwPt{CSFez;%q)Jcn7U$4h}(f@kv=P3|Pg>ece}5L>_yT%b4eT zmhYAepgw%XB%idAFTmknl^?wZq9H}rmpPmmNSf-1iF7M*vVhfI7?pcAiSUI<8_}v~ z7zjvbpgO{e^-DIH!PI%c3t%!-{#7kLdO=D#J2gb}QrtYm@yi|wGz^ebhBN|?I$2SA&!%}^Z7OES4Nu`4pu74t?%Z>wD+AI@}^ek2- zyjt9EfYM&f(a|(2dKbfEDb@Q&TJ9X{b_Z@`;@DD+#{-T#< zDtAW2EH^)rNtp}&hYk$%f6{@uEC>O!_EyqPaK4d+#?DIRkf=pmgrDdcne80~$znA# zfeU0}krTqS69_adwdEMH|07nU@2b4de;J?r!vf9?ZaVedQ`{mr2O^|NwI&n zXBF=@Xr@O+(hoVC3EVaGZs?lU1ZT(a6xrPRtBknt1|v&C;_CJgYH#1fxOD`J@>tB^ zl=b{Suo9d)YMsVKfS&-c-KLgFiCn!)%Q0Zv5Oa}jjc`55={&7u+41A|c|CjcBS5s}B-*N)r1<^LFG;_Qhu zm-`h#E~Ra9<64u?6ieMCfrZqm=y@68q5U}z77y8`GsX*{SawOt52pO^adWRDrzug4 zIgggw+KLwL?*2?DA_O=_v)+AF#P358%0lL1+3qoXq;nr$rVxbJ1hq~GXy|?--5$$_ zqX>vLVogy=DwQ7_2l%@}1TlpaHk+Y}bt)O<>WcJhC>6SCaDvk(Tfk{*ir)b$y=>)= zKkcWNWETzz^2E2(b4IQ}FTb1Q`pF5hJosEf)mr<7&Q;~dB`5kdLOs8!B9oRtD zS2Xwahd+gD22@9&xwF1V2;;9*gym%?P?wBKk52DOt*q(l7~0W@fq)K&GO4a7^vBH* z2v_{5rjB*cp?jk?fMq?u5;ul=lQkU)wDKYz)yZk%(;4Z7<`>X5F!9f6ImZcAU*=`e zUjh`sJfYhEM9)h#G$~koqtJ*=w2O|eek+GsrAM^p2Ybo~m%TX$*cSZoq;pngwC7?A zd#|Syo*`LqJ-7wzMH_D4>h1S7rR44a{pM8(o zcmMXYhBOV<7d*P~_EGUwi?L=#=k@!krM7hYhwjT{hr>eTha32}{>!2dj@bYhM`1Bh~|FOuxZ{myc3RClse`x#|jAfF#{@cJgqinC_3x2zghdAr*iYj_RwNba2-^Q%K)Eg9#X} zu98gLwoL)`ddQSNWntG7Mk$SD0>AUB*|6C|mFB7*09>RjFYb5=8E6F>#5Y2>0KSC@ zZcBYTSIbl%amv$nrD;xKpXRD%TjObVmjW3`YDy$_WB0ZU*)|F*+b;25D|?1h7NMRU zpdE?<4(4JQv*MxaPcH=Q8VQ~|dtxch`M|B?oHB$NUPVA$z{%-jp2kT`=61jUoe$-n zY{Q}@YGzCI(li@q>+wu-S98yMiI*d)NEA&-cc;0m4cg!;OSIKWqEfgG&+`h_DzqNS zk5Jg>6PWH@cAP&B)-GA^+NC?XIowi^%|GRzxMDpXtI^M!?;a#$cV142k=+AAd4aj? zNt@?lrX4qA99?5uF3z!;jslMyO)lQHmTF`C+Z@t=I8#+!dP2}w*{s#}ur)-av(+Uu z*2vtJe^z}u2c-p>6jeNzJ9lST=YKXo-J8ot(z&MBH2%!pnf5xnz#dB0dSsO4PM5CY zeuKe5^)U^p&b=yi>;os^^1R7jmi3wb#lvdgvLAl?ZqhngE;U%|ob4?E`2$l=e}ci) zz+XOv86my?$+5FH5RhQ?GQwqAl9RKoVk#;kGJJt)TJ5hCd`EQ%&|-aw3(S7g3x;j1 zKhZu7z)Ne$e(H0v{1K=()iv$_h(TsNyX25@jRB46otn=zSiNibP}TLT{V6EVUQY8gB97SQxFX z_Ktbzh2$5)i}2y&6-LG@Zb-G3xX}TT^$)}p`QdPu-mgt3fbrskA8AQbwpUlEr06M` zA4;jw82V7Y1l{%`{Hs&Hm18Nb2A5|m6r@`9rv=^<$VZ6trzgiP*k#2^JD0?_+29f- z8g$+A=i5;g82Zs4}tI10uodYfoPkO=KXd8ZGlS zlfu7#UG@r*Z7@4%fPSvZu+?)iTG}bT_#+19lZJm;^|n-kVUFV!fzirk8|d$jJr150 zQ_{=_G5qwYPy1VaRLmw;I@$vTk$8>v7mlU+9_9JdIzqyI+Xk84gy!N1e{eFd^~$?w zpI4uXL`GsdOl<))#&|zad^G!;Gtr+l|~P&(5;^R!q7&I22&> zrR>qluGS&)%h0c*=ADSUKnWXGJ|N4{@7*w6;O+l_1({c!7oBd#_p#&vmspsiVurZ& zZ_6H!3^+f*Kf(-ZLV2l|GYtyq(q>{;hyb4?pt{l1&iw8%XnYTNRw5Is^5GvXK)lA> z?=$V!)6Xr}?a{=UGvdWI=Fdk72nr@t-|PNqU&RnU(Vq(!oH|tYk$s5qzhtnS{@=vf z`z7#4kO}_eFtPK-d~uw3`ni`U(nHq|%voDx`_GsSK;DYri^(w%LStiMT#7>voImqcQ}@cv;_ zEPYVL^ZK6aH7N&oq|kYbPJ#Nr$oME_2-t~A~s^)okI+}lz{5&$JC zigVr3Gb~{w+n5&p-(KLQ9!%uTjgk~$~36xeL6Bnj=_%WB)qI(Tiu$NE(6Nv0ScKfHaB&*S;?F21Bx``O-djh>4!>$@qxod3s4pLlFUiklNZFBsVoVU z!9sW|K`P?=rX&NXp6EE;9+~#gs48Yv98PSW#{h1KAMk;5{^vFGlInHQPVpr(zj6;Z zn2;if0Mvx+C9#+Xg&AZv3tfpG3*x{XY!>z08W#g%P4YlG!d%~ zWK(G|QFTAH-X+RRY4O6+vED>588dFBkmbH|y_EC`Z)HvtgArtYvbRfZC6;+bYL&VC z*Jw+K=qikuvhoa4FxVb|zhs7ARC)3QY80vp>*a*Y7=}d46!+p1T2{a4cZt%B9NtXL zE(87P*GgAvM9K@wBjzfy;*EB@o^>rJgslXwN8ybTh(UqH3 ziVM`P+$rX;c(D3x1_nt0B#YpdpRlR;haTkSW?-#dQvN&?!~gQ!{0`B(zZ5_ZI_q-^0!~PPq>( zEc0fWz3!S^VC^hEYb)^J#>@`~@(3MC>`__Qz;C58{D1iJ_ZOfEF2Y*LOzEuZnHK#3 zn^s59x~)k~0!yz2{$7(-%qouzY}n1kvILN_rhaYvF}K_VcF($WS5fe>#f_>zY4YnL z8>Qa@j-sW^$=X{vPbcht=zi>Lb)=?Xr|v{H>^`m~_*A9s=k$+6?_TD%wSe#8yw%}F zcI!Cl%TJU%Y0yiogE_pPE$JC1)~dU{>9mRd zI1G$35Teo0?3RjE9}>5D$k57@Zq8wVqgoeIKcODnnaHn1>HvkgPNx3d4k*@RI!q#+ z>-8Mcrt~8u5^kBFGV@(o&?hyUrp#}Y;USvnIMrYEdB`bB4;zgt>7W2HS<}Q-$9b8< zz`nBe=L1>{29oe)Kl=yt{FxyotHZXyP3uU z<<9)mL5-gr|;3CIf6(dtUPp1Cir`+v+V zsI`wRka(Fs_d>CV`G^!9sHZe%{K|lyEpQZDU{Ve{?SOV`a(&ht*O5oh zn7dxy>$}&^?fNxbmT?z{lW?lGm%DLEILZec9xEM2YP*A%9))zl6}e!PxA`Aq&wJ1W zZx6uy8cZNB)P>P@Z%}iU$=JZC?cSwtli}-=X6qZb?u3?4;mt31_1JGT>B_@%_3aXU z?*`%2xdCV5>6}$E3ZWDj>&ef z*s>c|wfZo$9=j4^F2KghXA-|SUQCh>P~WV!G1v6d_vbL) zdC9Q}+e-D&O{4fo7=X*Ck9>4d$Y51A`|sv1$&9^`W8+7CG;YQcKdJL$}-%@{v`VOU$ z>w}f-N#4gJ3r+xs=&h)%A3cnKkhs~U>H#4)*s5YV7ni4{BPtK@GzTYaor^GTzxRMg?sF6#r>)Wd*oU0LdCZ*>N(yzT3QQT>Reer! z87!E2_W4&w6Q0U&>AC#dpW&HR^CMW2R$(4QK=kzKQ(6C-E4qIM(jEq~v&c|kk$Ivv0qa4Ycc`FQWM z+-?-QE-qL7Mhn1}zkk3Um`Q6_?vL*lR6ubZq=hqe*LE}=zYk^)U3Ym^;AeM*R%lg{ zfW>{NC)@EpbMK7Z;}ACd7R(gR)_+0+Ayj|Zp&~ID#Zj?w;a;&?$bHPzQuX+G>@@H! z8U3!`el1bq%5sX_<-GG``?kh>M}pA0JLu&kIL(5goT4c#kjJLR?7=5COs3&{g!gdG z-6#3f*`EZPX!7$&(j6>EdsV^+5jND(+ScGxnx>%~UOQwj)z6FhXUj*fi**-lnb$o` zX1{f`IyV&BCCc}--5-ILQMfIW^g(R}g&#X=Jb?hws3^&Y)dI z9lX!7v48xj(5$YIyru>wlX0Sl1IktG{#)+F=<$Id;Cp%+oZ9{6tW;#`49L){;Leno zPt+KW^J#0y;YvqeJpEUj^2|$Q>j3sWR0zriq2A|p!1YHQWOjduBK}64kH(Y#Pg`gH z4F&tZacy=Esh!UU;g=qcDPu-*KCtKC;tAk*Ye7H2Lr*WR0Fszox=-t!~E^s8P zdUpZG1AZ;t>U>}Bf5I%2nx!il1mls8*^`nT5;Ar}|FJ&fk_D#_mh8xXPBM-Nd@#N! z+r-}zoHR%m=;WWWVeSfD56FjO7(P;DAv=&$!3a0_Ltlc=GpY$GciP8UL2IOM#*6UA&@<63aeeplO z5`QDjd#c0Kcf878>oG)PjE<^`D!5;YdQAdk8-3IET!3CJDRi3IhVMPEKeXPUNRi1W zLu0(3f`ZQyFe7bcJq&yW?hiizWa10;Q_I>-1713dPOb8aiCrkN*b!b=Ux`z32EoL0 z!I)?_I*3!`mv*z@mBsu=VViriH~%`5I5s|odWs-JCf*?3daZfEzj>NzVn(K2V-w?x zGCPd4WOZU`RsD&3AWs{T{e?F$H$sUI5!}!NIldW@--}x`Z)Ahnv$RHgyq} zTc670j>qXQZkx}Y$Z0%E7{i`vn7(7Wocq;IB290 zH;Ck!^wr^#V~vq)>VS8=JMAX9rv#5)hA+O6PW{AW_5i=K$T6%7d&qg42XSpdXS2jv zFJFHGR@RJPztCN1GA!mnZi|wC1Y7*t0q2#c2YyjFc=F&{M*b_6A4T6{G43OyZnAIdA@Q`0^vc%{3`s~K@7uGE4s>^p1o$yH78Iu z-z^jD?DU%t-ifjEePCS#-S4#DVXR5-2~dR$&Yxg39nLqKB{MNZmk-I7b(I-zynPy3 zWD>aM?u?1fCkf26qc*Ch#?cI;Io-)lDfS#4grGLnl!jz*bjh9)a6|lCDT~2$)F>&k z_{G{^-$u0)Ah;=pfCMtOhjq^*=5n6M6b?u81>EQyVe_s-*o1jNfaTzUM9{N8vWv_S zSq5Ai*An_^tw2+Y;XC!EQaQm|V&Us58bC2D%WBynT@reB7p98|+jNCv_8C=kv)rF0 zXN;Id9uugxU}X%jF=*kXnikY$s9ZA$eeI%n(2)Fh&K_wtW+%6`wE+YBmalfOiF+L2 zw&)(}{rJjx=MXU>*Dfb**YEV<2lI#5Al=Mb5IVOfFwL5lioB>aRvB@o)X9G;bbNNj zghNAK$ioDjEG}y^C+zZy8z8Ksq;Q6h@sQ%5)b1zMZn@*kv|h8Z^Ww7}$%v=D(Sy=I zJM9;adX>EcUCsdVip-GtR6dC2ikLjLl&h}A8vjYixJI_N#~*It@U-RAI+)rr9oOE) zIA%#Xo!0$$X*uba;<|?q>t$mkxNG%r(EYt)d8pSkpXie7-gGlMedgVrx0!XnY^}T9 zpOrE{?ig54?fx!z>oE-}i)ME$HJ$@XoGOqFX@8XR_Wk?!T<7nKjVkgKIy~tHCm3Y^ zbdvQ*UJv;u&gNlb!KPxtk`kFg`0BqiB$Mt0tn7CmDPtD4(#X^GUnkBVONVTY_;$m6 z*l$gZe$E3tq4XjcOHS(xT?)`L*zd5L=TJOr%-tr6{&oG>54`u%GL^lIVBZ)SaTTgY zW@k~_22wtMdYeTqwW|L?8&K1`aZRv==}57bGw9&muVo@ek~cs%nZs-kP3({$?iVy^ zD!T7WRmV{63k1?;I5-t9)sOeG-Ck69rdI(A6csLk z?N$ytbM`Z09Sv9wxp-NJ z-{n&BqlqwW^)iGN__&>#=dxi_+^(xgfzHYAaeu2`o*3>iFmUI0Fz+0xijl=s+^bPM zb-bu1L-c61-SeBs^r;}oKO-GLn?sE<5KDp&U-Q>01FZIVSh?OHN@x{1X^gc~UwajN zpBoD?=pyN+2X@Ea;=P9;7TjIst;g9z?@gS##LaXgwr6jSnAm!ituM)D%01>iq+3*zXc7hC>xye5C zfpLuhAc-ZGi_|yJu9v9K8DI8s?=#2jgjNF3+xaNT ztf!?x)5X^;DtOL8pyq{=Unu^=3M#Tw%=K49eIjqS`ac9hI+cy@rovD32b|+5$ zQB^O`os?g@#}v2Pdewhg$>%!~h3H`wRj7EXu&md*41VS?({LvQbbhU!&J{xL8g5M} z6u9XAi=g{@mm;ZFpVxR*iO!I3!0p%!+=mLv8O*;A5Zo2r*%)&giYB6j%b7foCIO^f z$Ln12<@Wp6(m87^?gdXqXb?nw=3)ncuS-#8yJ)5>(^2otOAai7(d8byzT=N##_{L@ zsU}{iwalxBt(;mqmYdTV5W+3U>y*QxMU`+QKf+zo(zz;Q7+75Pq*I}=5it|i0Ejs% z-pD?bcmU-#09`=9aAcW2nzkp)ls)jz?{_lQOTb~M@cUo0sh*Z#&%F~ zQ#8;8Lixec1Vl5_|MwN!$Chz>wWCwwdKXC3sgP1K9}YGtg`C@)Ht^ZUu}=co!Y~#! z8al?({{dC`_G}F=tn_=Y(p3Txnm94`Q)P{_58K6Vh&Ae*I!3gP1%~Ll$ST6KE97njfREdf1cb+Wk26q>L{|eCPuV> zJz`>xZw_M#wy<_Aij@L(^_w&{Bx;za{?%8G@UHmPlzsS+l%FqkSxKp~esc6*8W#|# zv!-+<^?#7KuG-6IKLvC>@G!sG|M%6aVs=4_N@3a;t_Rrl`OClb@mupneO!Na?Vrid zw#Xrk@|1P=maLcW7SAdi-%AhhRIBZ5&wVoaX^h0|C}DGwX~uOeg1Cs2v-U1Y&nzSk z-}Q$Zz@*`JLSXE^qTc$TJSs$T_{Yuh7(Ibbs+o7qUI>`qe?i%S3ccYKqFxnomfX40 zK6`sRRu1(lRIGD-F+GvO_be}D)E1Xnv67bZhnAjGg;jaKfzzvBm&p$WTT@#vlCg(c zR*$at+o6OPp4Up5l^9aRg3JSI4J}hUncWzXMvx#(h_oTq*Wzt}UL6^|FFe*s5Z31v z1{FLf|Nf;`o<+txT* zpQ(keWL=mU6~In40>2531%m4l?OzyH-g!0LG zp9S5!wJmX(Va)9K^xP*6nsM@3mk5qh2BV^cHE5@fO7s0g}K}-7q?ho z^>lHmEfP}eu>%C!?2gj!#NV1qS)E`O!q)15TUq; zr+dl1b4N_*`%c2achst64k<4FD=nc1X}C#5bMh9Fx(RXzi~6YK*=^n}(i{j!Y*cf6 zzwSRjlJ1Rjvms{}1u+6lYS&9VGUf+*Y<)Xv+Hkd={Uj_l&<= z@rJXEvWDM7bCVD{D@B&-U9zrWcBbZ%E`n$Ch?ubN;N@xEm76d2Q1h-oUL}2YHcalR z2xS%C=}1$3cr^9~A2_D;_yDrEu{3rW1@PKE$EjK#snOh8@#pT$o!{4Lcv+9mbysU4 ze}WZ19bs0}`RpT)r9L^X2z0T`LDO^p-l7UuKzFR0PkP7Bp)-elKx5x-5lK7^w~;r- z!{DM0?7xPwn*;&-&Dyu2%TLe7#DE@zshE;Ae{2#Ts&4Gr+12GIb&rU`_MLaOFgZ30 zwtgEq#@|^ibU0EPfFqJHldJh82@?A%u5%Jo*%>v!m@k!IwW*HIQXaR6rdTgf6y z|42ET)*OJ1P%e|9^yO*h#s^jZ^YWib9^ym#)pNt9j!3L{r=>tYHd>W?E&z&+{UQNs zm-zb&aLl(GL_`~ErF8#xy?N2AWBwi7ydGaiX8*w1v#-yhq*M5i8rA(FAmNN2r`tq5V zjNH#`Yb`s30ucjG7lN)h)9Vibqyw=~Mwn0_<9b5uEm!=2Mnj=>%f`sWRN}Qh z?Ma_z(LwQtW`PwO5O%31o0&NTt|rT{xR4#Y7H~ZIAfXMCyd?>8DsD?mG{-GdPo$xx z+9$gjt())>?F@b?esp9@-0Q)PbhS2t?=`#gZt_qoS>jC+k+rJuBPziZBC=aV!W<%0&rgY^TtV+Ws zwpQ?^n0UZAhxT_JflCi&J@yEInPd+|&{hvUSB48xD$CB*9uqu3_2p$IZ|r4jCcLHXklu+?(i*yo>Gp-j92W>QWBcAlI~mLq{)5ZFbtiOsl(oS~C^ z@KY;&I+ZGXc*oP(^8Ycja#Frmbok=_BisG^N)X f$@Tu53}yo=*NS|(q0*I{lX01wSQ*zCy2k$>5ue^S literal 0 HcmV?d00001 diff --git a/sources_non_forked/tagbar/.gitattributes b/sources_non_forked/tagbar/.gitattributes new file mode 100644 index 0000000000..3b1db11a4f --- /dev/null +++ b/sources_non_forked/tagbar/.gitattributes @@ -0,0 +1,4 @@ +.gitignore export-ignore +.gitattributes export-ignore +README export-ignore +.info export-ignore diff --git a/sources_non_forked/tagbar/.gitignore b/sources_non_forked/tagbar/.gitignore new file mode 100644 index 0000000000..0a56e3fc5d --- /dev/null +++ b/sources_non_forked/tagbar/.gitignore @@ -0,0 +1 @@ +/doc/tags diff --git a/sources_non_forked/tagbar/.info b/sources_non_forked/tagbar/.info new file mode 100644 index 0000000000..f4d91373b7 --- /dev/null +++ b/sources_non_forked/tagbar/.info @@ -0,0 +1,2 @@ +tagbar +3465 diff --git a/sources_non_forked/tagbar/LICENSE b/sources_non_forked/tagbar/LICENSE new file mode 100644 index 0000000000..5ae1a752ad --- /dev/null +++ b/sources_non_forked/tagbar/LICENSE @@ -0,0 +1,82 @@ +TAGBAR LICENSE + +This is the normal Vim license (see ':h license' in Vim) with the necessary +replacements for the project and maintainer information. + +I) There are no restrictions on distributing unmodified copies of Tagbar + except that they must include this license text. You can also distribute + unmodified parts of Tagbar, likewise unrestricted except that they must + include this license text. You are also allowed to include executables + that you made from the unmodified Tagbar sources, plus your own usage + examples and scripts. + +II) It is allowed to distribute a modified (or extended) version of Tagbar, + including executables and/or source code, when the following four + conditions are met: + 1) This license text must be included unmodified. + 2) The modified Tagbar must be distributed in one of the following five ways: + a) If you make changes to Tagbar yourself, you must clearly describe in + the distribution how to contact you. When the maintainer asks you + (in any way) for a copy of the modified Tagbar you distributed, you + must make your changes, including source code, available to the + maintainer without fee. The maintainer reserves the right to + include your changes in the official version of Tagbar. What the + maintainer will do with your changes and under what license they + will be distributed is negotiable. If there has been no negotiation + then this license, or a later version, also applies to your changes. + The current maintainer is Jan Larres . If this + changes it will be announced in appropriate places (most likely + majutsushi.github.io/tagbar and/or github.com/majutsushi/tagbar). + When it is completely impossible to contact the maintainer, the + obligation to send him your changes ceases. Once the maintainer has + confirmed that he has received your changes they will not have to be + sent again. + b) If you have received a modified Tagbar that was distributed as + mentioned under a) you are allowed to further distribute it + unmodified, as mentioned at I). If you make additional changes the + text under a) applies to those changes. + c) Provide all the changes, including source code, with every copy of + the modified Tagbar you distribute. This may be done in the form of + a context diff. You can choose what license to use for new code you + add. The changes and their license must not restrict others from + making their own changes to the official version of Tagbar. + d) When you have a modified Tagbar which includes changes as mentioned + under c), you can distribute it without the source code for the + changes if the following three conditions are met: + - The license that applies to the changes permits you to distribute + the changes to the Tagbar maintainer without fee or restriction, and + permits the Tagbar maintainer to include the changes in the official + version of Tagbar without fee or restriction. + - You keep the changes for at least three years after last + distributing the corresponding modified Tagbar. When the + maintainer or someone who you distributed the modified Tagbar to + asks you (in any way) for the changes within this period, you must + make them available to him. + - You clearly describe in the distribution how to contact you. This + contact information must remain valid for at least three years + after last distributing the corresponding modified Tagbar, or as + long as possible. + e) When the GNU General Public License (GPL) applies to the changes, + you can distribute the modified Tagbar under the GNU GPL version 2 + or any later version. + 3) A message must be added, at least in the documentation, such that the + user of the modified Tagbar is able to see that it was modified. When + distributing as mentioned under 2)e) adding the message is only + required for as far as this does not conflict with the license used for + the changes. + 4) The contact information as required under 2)a) and 2)d) must not be + removed or changed, except that the person himself can make + corrections. + +III) If you distribute a modified version of Tagbar, you are encouraged to use + the Tagbar license for your changes and make them available to the + maintainer, including the source code. The preferred way to do this is + by e-mail or by uploading the files to a server and e-mailing the URL. If + the number of changes is small (e.g., a modified Makefile) e-mailing a + context diff will do. The e-mail address to be used is + + +IV) It is not allowed to remove this license from the distribution of the + Tagbar sources, parts of it or from a modified version. You may use this + license for previous Tagbar releases instead of the license that they + came with, at your option. diff --git a/sources_non_forked/tagbar/README.md b/sources_non_forked/tagbar/README.md new file mode 100644 index 0000000000..eceddbe395 --- /dev/null +++ b/sources_non_forked/tagbar/README.md @@ -0,0 +1,89 @@ +# Tagbar: a class outline viewer for Vim + +## What Tagbar is + +Tagbar is a Vim plugin that provides an easy way to browse the tags of the +current file and get an overview of its structure. It does this by creating a +sidebar that displays the ctags-generated tags of the current file, ordered by +their scope. This means that for example methods in C++ are displayed under +the class they are defined in. + +## What Tagbar is not + +Tagbar is not a general-purpose tool for managing `tags` files. It only +creates the tags it needs on-the-fly in-memory without creating any files. +`tags` file management is provided by other plugins, like for example +[easytags](https://github.com/xolox/vim-easytags). + +## Dependencies + +[Vim 7.0](http://www.vim.org/) (But see note below) +[Exuberant ctags 5.5](http://ctags.sourceforge.net/) + +## Installation + +Extract the archive or clone the repository into a directory in your +`'runtimepath'`, or use a plugin manager of your choice like +[pathogen](https://github.com/tpope/vim-pathogen). Don't forget to run +`:helptags` if your plugin manager doesn't do it for you so you can access the +documentation with `:help tagbar`. + +Note: Vim versions < 7.0.167 have a bug that prevents Tagbar from working. If +you are affected by this use this alternate Tagbar download instead: +[zip](https://github.com/majutsushi/tagbar/zipball/70fix). It is on par with +version 2.2 but probably won't be updated after that due to the amount of +changes required. + +If the ctags executable is not installed in one of the directories in your +`$PATH` environment variable you have to set the `g:tagbar_ctags_bin` +variable, see the documentation for more info. + +## Quickstart + +Put something like the following into your ~/.vimrc: + +```vim +nmap :TagbarToggle +``` + +If you do this the F8 key will toggle the Tagbar window. You can of course use +any shortcut you want. For more flexible ways to open and close the window +(and the rest of the functionality) see the documentation. + +## Support for additional filetypes + +For filetypes that are not supported by Exuberant Ctags check out [the +wiki](https://github.com/majutsushi/tagbar/wiki) to see whether other projects +offer support for them and how to use them. Please add any other +projects/configurations that you find or create yourself so that others can +benefit from them, too. + +## Note: If the file structure display is wrong + +If you notice that there are some errors in the way your file's structure is +displayed in Tagbar, please make sure that the bug is actually in Tagbar +before you report an issue. Since Tagbar uses +[exuberant-ctags](http://ctags.sourceforge.net/) and compatible programs to do +the actual file parsing, it is likely that the bug is actually in the program +responsible for that filetype instead. + +There is an example in `:h tagbar-issues` about how to run ctags manually so +you can determine where the bug actually is. If the bug is actually in ctags, +please report it on their website instead, as there is nothing I can do about +it in Tagbar. Thank you! + +You can also have a look at [ctags bugs that have previously been filed +against Tagbar](https://github.com/majutsushi/tagbar/issues?labels=ctags-bug&page=1&state=closed). + +## Screenshots + +![screenshot1](https://i.imgur.com/Sf9Ls2r.png) +![screenshot2](https://i.imgur.com/n4bpPv3.png) + +## License + +Vim license, see LICENSE + +## Maintainer + +Jan Larres <[jan@majutsushi.net](mailto:jan@majutsushi.net)> diff --git a/sources_non_forked/tagbar/autoload/tagbar.vim b/sources_non_forked/tagbar/autoload/tagbar.vim new file mode 100644 index 0000000000..6063e91b76 --- /dev/null +++ b/sources_non_forked/tagbar/autoload/tagbar.vim @@ -0,0 +1,4263 @@ +" ============================================================================ +" File: tagbar.vim +" Description: List the current file's tags in a sidebar, ordered by class etc +" Author: Jan Larres +" Licence: Vim licence +" Website: http://majutsushi.github.com/tagbar/ +" Version: 2.6.1 +" Note: This plugin was heavily inspired by the 'Taglist' plugin by +" Yegappan Lakshmanan and uses a small amount of code from it. +" +" Original taglist copyright notice: +" Permission is hereby granted to use and distribute this code, +" with or without modifications, provided that this copyright +" notice is copied with it. Like anything else that's free, +" taglist.vim is provided *as is* and comes with no warranty of +" any kind, either expressed or implied. In no event will the +" copyright holder be liable for any damamges resulting from the +" use of this software. +" ============================================================================ + +scriptencoding utf-8 + +" Initialization {{{1 + +" If another plugin calls an autoloaded Tagbar function on startup before the +" plugin/tagbar.vim file got loaded, load it explicitly +if exists(':Tagbar') == 0 + runtime plugin/tagbar.vim +endif + +if exists(':Tagbar') == 0 + echomsg 'Tagbar: Could not load plugin code, check your runtimepath!' + finish +endif + +" Basic init {{{2 + +redir => s:ftype_out +silent filetype +redir END +if s:ftype_out !~# 'detection:ON' + echomsg 'Tagbar: Filetype detection is turned off, skipping plugin' + unlet s:ftype_out + finish +endif +unlet s:ftype_out + +let s:icon_closed = g:tagbar_iconchars[0] +let s:icon_open = g:tagbar_iconchars[1] + +let s:type_init_done = 0 +let s:autocommands_done = 0 +let s:statusline_in_use = 0 + +" 0: not checked yet; 1: checked and found; 2: checked and not found +let s:checked_ctags = 0 +let s:checked_ctags_types = 0 +let s:ctags_types = {} + +let s:new_window = 1 +let s:is_maximized = 0 +let s:winrestcmd = '' +let s:short_help = 1 +let s:nearby_disabled = 0 +let s:paused = 0 +let s:pwin_by_tagbar = 0 + +let s:window_expanded = 0 +let s:expand_bufnr = -1 +let s:window_pos = { + \ 'pre' : { 'x' : 0, 'y' : 0 }, + \ 'post' : { 'x' : 0, 'y' : 0 } +\} + +" Script-local variable needed since compare functions can't +" take extra arguments +let s:compare_typeinfo = {} + +let s:visibility_symbols = { + \ 'public' : '+', + \ 'protected' : '#', + \ 'private' : '-' +\ } + +let g:loaded_tagbar = 1 + +let s:last_highlight_tline = 0 +let s:debug = 0 +let s:debug_file = '' + +let s:warnings = { + \ 'type': [], + \ 'encoding': 0 +\ } + +" s:Init() {{{2 +function! s:Init(silent) abort + if s:checked_ctags == 2 && a:silent + return 0 + elseif s:checked_ctags != 1 + if !s:CheckForExCtags(a:silent) + return 0 + endif + endif + + if !s:checked_ctags_types + call s:GetSupportedFiletypes() + endif + + if !s:type_init_done + call s:InitTypes() + endif + + if !s:autocommands_done + call s:CreateAutocommands() + call s:AutoUpdate(fnamemodify(expand('%'), ':p'), 0) + endif + + return 1 +endfunction + +" s:InitTypes() {{{2 +function! s:InitTypes() abort + call s:debug('Initializing types') + + let s:known_types = {} + + " Ant {{{3 + let type_ant = s:TypeInfo.New() + let type_ant.ctagstype = 'ant' + let type_ant.kinds = [ + \ {'short' : 'p', 'long' : 'projects', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'targets', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.ant = type_ant + " Asm {{{3 + let type_asm = s:TypeInfo.New() + let type_asm.ctagstype = 'asm' + let type_asm.kinds = [ + \ {'short' : 'm', 'long' : 'macros', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'types', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'd', 'long' : 'defines', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.asm = type_asm + " ASP {{{3 + let type_aspvbs = s:TypeInfo.New() + let type_aspvbs.ctagstype = 'asp' + let type_aspvbs.kinds = [ + \ {'short' : 'd', 'long' : 'constants', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'subroutines', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.aspvbs = type_aspvbs + " Awk {{{3 + let type_awk = s:TypeInfo.New() + let type_awk.ctagstype = 'awk' + let type_awk.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.awk = type_awk + " Basic {{{3 + let type_basic = s:TypeInfo.New() + let type_basic.ctagstype = 'basic' + let type_basic.kinds = [ + \ {'short' : 'c', 'long' : 'constants', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'g', 'long' : 'enumerations', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'types', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.basic = type_basic + " BETA {{{3 + let type_beta = s:TypeInfo.New() + let type_beta.ctagstype = 'beta' + let type_beta.kinds = [ + \ {'short' : 'f', 'long' : 'fragments', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'slots', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'patterns', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.beta = type_beta + " C {{{3 + let type_c = s:TypeInfo.New() + let type_c.ctagstype = 'c' + let type_c.kinds = [ + \ {'short' : 'd', 'long' : 'macros', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'p', 'long' : 'prototypes', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'g', 'long' : 'enums', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'enumerators', 'fold' : 0, 'stl' : 0}, + \ {'short' : 't', 'long' : 'typedefs', 'fold' : 0, 'stl' : 0}, + \ {'short' : 's', 'long' : 'structs', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'u', 'long' : 'unions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'members', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let type_c.sro = '::' + let type_c.kind2scope = { + \ 'g' : 'enum', + \ 's' : 'struct', + \ 'u' : 'union' + \ } + let type_c.scope2kind = { + \ 'enum' : 'g', + \ 'struct' : 's', + \ 'union' : 'u' + \ } + let s:known_types.c = type_c + " C++ {{{3 + let type_cpp = s:TypeInfo.New() + let type_cpp.ctagstype = 'c++' + let type_cpp.kinds = [ + \ {'short' : 'd', 'long' : 'macros', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'p', 'long' : 'prototypes', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'g', 'long' : 'enums', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'enumerators', 'fold' : 0, 'stl' : 0}, + \ {'short' : 't', 'long' : 'typedefs', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'n', 'long' : 'namespaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'structs', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'u', 'long' : 'unions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'members', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0} + \ ] + let type_cpp.sro = '::' + let type_cpp.kind2scope = { + \ 'g' : 'enum', + \ 'n' : 'namespace', + \ 'c' : 'class', + \ 's' : 'struct', + \ 'u' : 'union' + \ } + let type_cpp.scope2kind = { + \ 'enum' : 'g', + \ 'namespace' : 'n', + \ 'class' : 'c', + \ 'struct' : 's', + \ 'union' : 'u' + \ } + let s:known_types.cpp = type_cpp + let s:known_types.cuda = type_cpp + " C# {{{3 + let type_cs = s:TypeInfo.New() + let type_cs.ctagstype = 'c#' + let type_cs.kinds = [ + \ {'short' : 'd', 'long' : 'macros', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'fields', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'g', 'long' : 'enums', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'enumerators', 'fold' : 0, 'stl' : 0}, + \ {'short' : 't', 'long' : 'typedefs', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'n', 'long' : 'namespaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'i', 'long' : 'interfaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'structs', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'E', 'long' : 'events', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'methods', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'properties', 'fold' : 0, 'stl' : 1} + \ ] + let type_cs.sro = '.' + let type_cs.kind2scope = { + \ 'n' : 'namespace', + \ 'i' : 'interface', + \ 'c' : 'class', + \ 's' : 'struct', + \ 'g' : 'enum' + \ } + let type_cs.scope2kind = { + \ 'namespace' : 'n', + \ 'interface' : 'i', + \ 'class' : 'c', + \ 'struct' : 's', + \ 'enum' : 'g' + \ } + let s:known_types.cs = type_cs + " COBOL {{{3 + let type_cobol = s:TypeInfo.New() + let type_cobol.ctagstype = 'cobol' + let type_cobol.kinds = [ + \ {'short' : 'd', 'long' : 'data items', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'file descriptions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'g', 'long' : 'group items', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'paragraphs', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'P', 'long' : 'program ids', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'sections', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.cobol = type_cobol + " DOS Batch {{{3 + let type_dosbatch = s:TypeInfo.New() + let type_dosbatch.ctagstype = 'dosbatch' + let type_dosbatch.kinds = [ + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.dosbatch = type_dosbatch + " Eiffel {{{3 + let type_eiffel = s:TypeInfo.New() + let type_eiffel.ctagstype = 'eiffel' + let type_eiffel.kinds = [ + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'features', 'fold' : 0, 'stl' : 1} + \ ] + let type_eiffel.sro = '.' " Not sure, is nesting even possible? + let type_eiffel.kind2scope = { + \ 'c' : 'class', + \ 'f' : 'feature' + \ } + let type_eiffel.scope2kind = { + \ 'class' : 'c', + \ 'feature' : 'f' + \ } + let s:known_types.eiffel = type_eiffel + " Erlang {{{3 + let type_erlang = s:TypeInfo.New() + let type_erlang.ctagstype = 'erlang' + let type_erlang.kinds = [ + \ {'short' : 'm', 'long' : 'modules', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'd', 'long' : 'macro definitions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'r', 'long' : 'record definitions', 'fold' : 0, 'stl' : 1} + \ ] + let type_erlang.sro = '.' " Not sure, is nesting even possible? + let type_erlang.kind2scope = { + \ 'm' : 'module' + \ } + let type_erlang.scope2kind = { + \ 'module' : 'm' + \ } + let s:known_types.erlang = type_erlang + " Flex {{{3 + " Vim doesn't support Flex out of the box, this is based on rough + " guesses and probably requires + " http://www.vim.org/scripts/script.php?script_id=2909 + " Improvements welcome! + let type_as = s:TypeInfo.New() + let type_as.ctagstype = 'flex' + let type_as.kinds = [ + \ {'short' : 'v', 'long' : 'global variables', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'methods', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'properties', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'x', 'long' : 'mxtags', 'fold' : 0, 'stl' : 0} + \ ] + let type_as.sro = '.' + let type_as.kind2scope = { + \ 'c' : 'class' + \ } + let type_as.scope2kind = { + \ 'class' : 'c' + \ } + let s:known_types.mxml = type_as + let s:known_types.actionscript = type_as + " Fortran {{{3 + let type_fortran = s:TypeInfo.New() + let type_fortran.ctagstype = 'fortran' + let type_fortran.kinds = [ + \ {'short' : 'm', 'long' : 'modules', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'programs', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'k', 'long' : 'components', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'derived types and structures', 'fold' : 0, + \ 'stl' : 1}, + \ {'short' : 'c', 'long' : 'common blocks', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'b', 'long' : 'block data', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'e', 'long' : 'entry points', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'subroutines', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'n', 'long' : 'namelists', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0} + \ ] + let type_fortran.sro = '.' " Not sure, is nesting even possible? + let type_fortran.kind2scope = { + \ 'm' : 'module', + \ 'p' : 'program', + \ 'f' : 'function', + \ 's' : 'subroutine' + \ } + let type_fortran.scope2kind = { + \ 'module' : 'm', + \ 'program' : 'p', + \ 'function' : 'f', + \ 'subroutine' : 's' + \ } + let s:known_types.fortran = type_fortran + " HTML {{{3 + let type_html = s:TypeInfo.New() + let type_html.ctagstype = 'html' + let type_html.kinds = [ + \ {'short' : 'f', 'long' : 'JavaScript funtions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'a', 'long' : 'named anchors', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.html = type_html + " Java {{{3 + let type_java = s:TypeInfo.New() + let type_java.ctagstype = 'java' + let type_java.kinds = [ + \ {'short' : 'p', 'long' : 'packages', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'fields', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'g', 'long' : 'enum types', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'enum constants', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'i', 'long' : 'interfaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'methods', 'fold' : 0, 'stl' : 1} + \ ] + let type_java.sro = '.' + let type_java.kind2scope = { + \ 'g' : 'enum', + \ 'i' : 'interface', + \ 'c' : 'class' + \ } + let type_java.scope2kind = { + \ 'enum' : 'g', + \ 'interface' : 'i', + \ 'class' : 'c' + \ } + let s:known_types.java = type_java + " JavaScript {{{3 + " jsctags/doctorjs will be used if available. + let type_javascript = s:TypeInfo.New() + let type_javascript.ctagstype = 'javascript' + let jsctags = s:CheckFTCtags('jsctags', 'javascript') + if jsctags != '' + let type_javascript.kinds = [ + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let type_javascript.sro = '.' + let type_javascript.kind2scope = { + \ 'v' : 'namespace', + \ 'f' : 'namespace' + \ } + let type_javascript.scope2kind = { + \ 'namespace' : 'v' + \ } + let type_javascript.ctagsbin = jsctags + let type_javascript.ctagsargs = '-f -' + else + let type_javascript.kinds = [ + \ {'short': 'v', 'long': 'global variables', 'fold': 0, 'stl': 0}, + \ {'short': 'c', 'long': 'classes', 'fold': 0, 'stl': 1}, + \ {'short': 'p', 'long': 'properties', 'fold': 0, 'stl': 0}, + \ {'short': 'm', 'long': 'methods', 'fold': 0, 'stl': 1}, + \ {'short': 'f', 'long': 'functions', 'fold': 0, 'stl': 1}, + \ ] + let type_javascript.sro = '.' + let type_javascript.kind2scope = { + \ 'c' : 'class', + \ 'f' : 'function', + \ 'm' : 'method', + \ 'p' : 'property', + \ } + let type_javascript.scope2kind = { + \ 'class' : 'c', + \ 'function' : 'f', + \ } + endif + let s:known_types.javascript = type_javascript + " Lisp {{{3 + let type_lisp = s:TypeInfo.New() + let type_lisp.ctagstype = 'lisp' + let type_lisp.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.lisp = type_lisp + let s:known_types.clojure = type_lisp + " Lua {{{3 + let type_lua = s:TypeInfo.New() + let type_lua.ctagstype = 'lua' + let type_lua.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.lua = type_lua + " Make {{{3 + let type_make = s:TypeInfo.New() + let type_make.ctagstype = 'make' + let type_make.kinds = [ + \ {'short' : 'm', 'long' : 'macros', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.make = type_make + " Matlab {{{3 + let type_matlab = s:TypeInfo.New() + let type_matlab.ctagstype = 'matlab' + let type_matlab.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.matlab = type_matlab + " Ocaml {{{3 + let type_ocaml = s:TypeInfo.New() + let type_ocaml.ctagstype = 'ocaml' + let type_ocaml.kinds = [ + \ {'short' : 'M', 'long' : 'modules or functors', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'global variables', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'C', 'long' : 'constructors', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'methods', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'exceptions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'type names', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'r', 'long' : 'structure fields', 'fold' : 0, 'stl' : 0} + \ ] + let type_ocaml.sro = '.' " Not sure, is nesting even possible? + let type_ocaml.kind2scope = { + \ 'M' : 'Module', + \ 'c' : 'class', + \ 't' : 'type' + \ } + let type_ocaml.scope2kind = { + \ 'Module' : 'M', + \ 'class' : 'c', + \ 'type' : 't' + \ } + let s:known_types.ocaml = type_ocaml + " Pascal {{{3 + let type_pascal = s:TypeInfo.New() + let type_pascal.ctagstype = 'pascal' + let type_pascal.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'procedures', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.pascal = type_pascal + " Perl {{{3 + let type_perl = s:TypeInfo.New() + let type_perl.ctagstype = 'perl' + let type_perl.kinds = [ + \ {'short' : 'p', 'long' : 'packages', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'c', 'long' : 'constants', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'formats', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'subroutines', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.perl = type_perl + " PHP {{{3 + let type_php = s:TypeInfo.New() + let type_php.ctagstype = 'php' + let type_php.kinds = [ + \ {'short' : 'i', 'long' : 'interfaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'd', 'long' : 'constant definitions', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'j', 'long' : 'javascript functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.php = type_php + " Python {{{3 + let type_python = s:TypeInfo.New() + let type_python.ctagstype = 'python' + let type_python.kinds = [ + \ {'short' : 'i', 'long' : 'imports', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'members', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0} + \ ] + let type_python.sro = '.' + let type_python.kind2scope = { + \ 'c' : 'class', + \ 'f' : 'function', + \ 'm' : 'function' + \ } + let type_python.scope2kind = { + \ 'class' : 'c', + \ 'function' : 'f' + \ } + let s:known_types.python = type_python + let s:known_types.pyrex = type_python + let s:known_types.cython = type_python + " REXX {{{3 + let type_rexx = s:TypeInfo.New() + let type_rexx.ctagstype = 'rexx' + let type_rexx.kinds = [ + \ {'short' : 's', 'long' : 'subroutines', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.rexx = type_rexx + " Ruby {{{3 + let type_ruby = s:TypeInfo.New() + let type_ruby.ctagstype = 'ruby' + let type_ruby.kinds = [ + \ {'short' : 'm', 'long' : 'modules', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'methods', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'F', 'long' : 'singleton methods', 'fold' : 0, 'stl' : 1} + \ ] + let type_ruby.sro = '.' + let type_ruby.kind2scope = { + \ 'c' : 'class', + \ 'm' : 'class' + \ } + let type_ruby.scope2kind = { + \ 'class' : 'c' + \ } + let s:known_types.ruby = type_ruby + " Scheme {{{3 + let type_scheme = s:TypeInfo.New() + let type_scheme.ctagstype = 'scheme' + let type_scheme.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'sets', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.scheme = type_scheme + let s:known_types.racket = type_scheme + " Shell script {{{3 + let type_sh = s:TypeInfo.New() + let type_sh.ctagstype = 'sh' + let type_sh.kinds = [ + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.sh = type_sh + let s:known_types.csh = type_sh + let s:known_types.zsh = type_sh + " SLang {{{3 + let type_slang = s:TypeInfo.New() + let type_slang.ctagstype = 'slang' + let type_slang.kinds = [ + \ {'short' : 'n', 'long' : 'namespaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.slang = type_slang + " SML {{{3 + let type_sml = s:TypeInfo.New() + let type_sml.ctagstype = 'sml' + let type_sml.kinds = [ + \ {'short' : 'e', 'long' : 'exception declarations', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'function definitions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'functor definitions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'signature declarations', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'r', 'long' : 'structure declarations', 'fold' : 0, 'stl' : 0}, + \ {'short' : 't', 'long' : 'type definitions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'value bindings', 'fold' : 0, 'stl' : 0} + \ ] + let s:known_types.sml = type_sml + " SQL {{{3 + " The SQL ctags parser seems to be buggy for me, so this just uses the + " normal kinds even though scopes should be available. Improvements + " welcome! + let type_sql = s:TypeInfo.New() + let type_sql.ctagstype = 'sql' + let type_sql.kinds = [ + \ {'short' : 'P', 'long' : 'packages', 'fold' : 1, 'stl' : 1}, + \ {'short' : 'd', 'long' : 'prototypes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'cursors', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'F', 'long' : 'record fields', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'L', 'long' : 'block label', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'procedures', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'subtypes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'tables', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'T', 'long' : 'triggers', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'i', 'long' : 'indexes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'events', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'U', 'long' : 'publications', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'R', 'long' : 'services', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'D', 'long' : 'domains', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'V', 'long' : 'views', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'n', 'long' : 'synonyms', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'x', 'long' : 'MobiLink Table Scripts', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'y', 'long' : 'MobiLink Conn Scripts', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'z', 'long' : 'MobiLink Properties', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.sql = type_sql + " Tcl {{{3 + let type_tcl = s:TypeInfo.New() + let type_tcl.ctagstype = 'tcl' + let type_tcl.kinds = [ + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'methods', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'procedures', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.tcl = type_tcl + " LaTeX {{{3 + let type_tex = s:TypeInfo.New() + let type_tex.ctagstype = 'tex' + let type_tex.kinds = [ + \ {'short' : 'i', 'long' : 'includes', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'p', 'long' : 'parts', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'chapters', 'fold' : 0, 'stl' : 1}, + \ {'short' : 's', 'long' : 'sections', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'u', 'long' : 'subsections', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'b', 'long' : 'subsubsections', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'P', 'long' : 'paragraphs', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'G', 'long' : 'subparagraphs', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 0} + \ ] + let type_tex.sro = '""' + let type_tex.kind2scope = { + \ 'p' : 'part', + \ 'c' : 'chapter', + \ 's' : 'section', + \ 'u' : 'subsection', + \ 'b' : 'subsubsection' + \ } + let type_tex.scope2kind = { + \ 'part' : 'p', + \ 'chapter' : 'c', + \ 'section' : 's', + \ 'subsection' : 'u', + \ 'subsubsection' : 'b' + \ } + let type_tex.sort = 0 + let s:known_types.tex = type_tex + " Vala {{{3 + " Vala is supported by the ctags fork provided by Anjuta, so only add the + " type if the fork is used to prevent error messages otherwise + if has_key(s:ctags_types, 'vala') || executable('anjuta-tags') + let type_vala = s:TypeInfo.New() + let type_vala.ctagstype = 'vala' + let type_vala.kinds = [ + \ {'short' : 'e', 'long' : 'Enumerations', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'Enumeration values', 'fold' : 0, 'stl' : 0}, + \ {'short' : 's', 'long' : 'Structures', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'i', 'long' : 'Interfaces', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'd', 'long' : 'Delegates', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'Classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'Properties', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'Fields', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'm', 'long' : 'Methods', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'E', 'long' : 'Error domains', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'r', 'long' : 'Error codes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'S', 'long' : 'Signals', 'fold' : 0, 'stl' : 1} + \ ] + let type_vala.sro = '.' + " 'enum' doesn't seem to be used as a scope, but it can't hurt to have + " it here + let type_vala.kind2scope = { + \ 's' : 'struct', + \ 'i' : 'interface', + \ 'c' : 'class', + \ 'e' : 'enum' + \ } + let type_vala.scope2kind = { + \ 'struct' : 's', + \ 'interface' : 'i', + \ 'class' : 'c', + \ 'enum' : 'e' + \ } + let s:known_types.vala = type_vala + endif + if !has_key(s:ctags_types, 'vala') && executable('anjuta-tags') + let s:known_types.vala.ctagsbin = 'anjuta-tags' + endif + " Vera {{{3 + " Why are variables 'virtual'? + let type_vera = s:TypeInfo.New() + let type_vera.ctagstype = 'vera' + let type_vera.kinds = [ + \ {'short' : 'd', 'long' : 'macros', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'g', 'long' : 'enums', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'T', 'long' : 'typedefs', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'c', 'long' : 'classes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'enumerators', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'm', 'long' : 'members', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'tasks', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'p', 'long' : 'programs', 'fold' : 0, 'stl' : 1} + \ ] + let type_vera.sro = '.' " Nesting doesn't seem to be possible + let type_vera.kind2scope = { + \ 'g' : 'enum', + \ 'c' : 'class', + \ 'v' : 'virtual' + \ } + let type_vera.scope2kind = { + \ 'enum' : 'g', + \ 'class' : 'c', + \ 'virtual' : 'v' + \ } + let s:known_types.vera = type_vera + " Verilog {{{3 + let type_verilog = s:TypeInfo.New() + let type_verilog.ctagstype = 'verilog' + let type_verilog.kinds = [ + \ {'short' : 'c', 'long' : 'constants', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'e', 'long' : 'events', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'm', 'long' : 'modules', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'n', 'long' : 'net data types', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'ports', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'r', 'long' : 'register data types', 'fold' : 0, 'stl' : 1}, + \ {'short' : 't', 'long' : 'tasks', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.verilog = type_verilog + " VHDL {{{3 + " The VHDL ctags parser unfortunately doesn't generate proper scopes + let type_vhdl = s:TypeInfo.New() + let type_vhdl.ctagstype = 'vhdl' + let type_vhdl.kinds = [ + \ {'short' : 'P', 'long' : 'packages', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'c', 'long' : 'constants', 'fold' : 0, 'stl' : 0}, + \ {'short' : 't', 'long' : 'types', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'T', 'long' : 'subtypes', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'r', 'long' : 'records', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'e', 'long' : 'entities', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'p', 'long' : 'procedures', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.vhdl = type_vhdl + " Vim {{{3 + let type_vim = s:TypeInfo.New() + let type_vim.ctagstype = 'vim' + let type_vim.kinds = [ + \ {'short' : 'n', 'long' : 'vimball filenames', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'v', 'long' : 'variables', 'fold' : 1, 'stl' : 0}, + \ {'short' : 'f', 'long' : 'functions', 'fold' : 0, 'stl' : 1}, + \ {'short' : 'a', 'long' : 'autocommand groups', 'fold' : 1, 'stl' : 1}, + \ {'short' : 'c', 'long' : 'commands', 'fold' : 0, 'stl' : 0}, + \ {'short' : 'm', 'long' : 'maps', 'fold' : 1, 'stl' : 0} + \ ] + let s:known_types.vim = type_vim + " YACC {{{3 + let type_yacc = s:TypeInfo.New() + let type_yacc.ctagstype = 'yacc' + let type_yacc.kinds = [ + \ {'short' : 'l', 'long' : 'labels', 'fold' : 0, 'stl' : 1} + \ ] + let s:known_types.yacc = type_yacc + " }}}3 + + for [type, typeinfo] in items(s:known_types) + let typeinfo.ftype = type + endfor + + call s:LoadUserTypeDefs() + + for typeinfo in values(s:known_types) + call typeinfo.createKinddict() + endfor + + let s:type_init_done = 1 +endfunction + +" s:LoadUserTypeDefs() {{{2 +function! s:LoadUserTypeDefs(...) abort + if a:0 > 0 + let type = a:1 + + call s:debug("Initializing user type '" . type . "'") + + let defdict = {} + let defdict[type] = g:tagbar_type_{type} + else + call s:debug('Initializing user types') + + let defdict = tagbar#getusertypes() + endif + + let transformed = {} + for [type, def] in items(defdict) + let transformed[type] = s:TransformUserTypeDef(def) + let transformed[type].ftype = type + endfor + + for [key, value] in items(transformed) + if !has_key(s:known_types, key) || get(value, 'replace', 0) + let s:known_types[key] = s:TypeInfo.New(value) + else + call extend(s:known_types[key], value) + endif + endfor + + if a:0 > 0 + call s:known_types[type].createKinddict() + endif +endfunction + +" s:TransformUserTypeDef() {{{2 +" Transform the user definitions into the internal format +function! s:TransformUserTypeDef(def) abort + let newdef = copy(a:def) + + if has_key(a:def, 'kinds') + let newdef.kinds = [] + let kinds = a:def.kinds + for kind in kinds + let kindlist = split(kind, ':') + let kinddict = {'short' : kindlist[0], 'long' : kindlist[1]} + let kinddict.fold = get(kindlist, 2, 0) + let kinddict.stl = get(kindlist, 3, 1) + call add(newdef.kinds, kinddict) + endfor + endif + + " If the user only specified one of kind2scope and scope2kind then use it + " to generate the respective other + if has_key(a:def, 'kind2scope') && !has_key(a:def, 'scope2kind') + let newdef.scope2kind = {} + for [key, value] in items(a:def.kind2scope) + let newdef.scope2kind[value] = key + endfor + elseif has_key(a:def, 'scope2kind') && !has_key(a:def, 'kind2scope') + let newdef.kind2scope = {} + for [key, value] in items(a:def.scope2kind) + let newdef.kind2scope[value] = key + endfor + endif + + return newdef +endfunction + +" s:RestoreSession() {{{2 +" Properly restore Tagbar after a session got loaded +function! s:RestoreSession() abort + call s:debug('Restoring session') + + let curfile = fnamemodify(bufname('%'), ':p') + + let tagbarwinnr = bufwinnr('__Tagbar__') + if tagbarwinnr == -1 + " Tagbar wasn't open in the saved session, nothing to do + return + else + let in_tagbar = 1 + if winnr() != tagbarwinnr + call s:goto_win(tagbarwinnr) + let in_tagbar = 0 + endif + endif + + let s:last_autofocus = 0 + + call s:Init(0) + + call s:InitWindow(g:tagbar_autoclose) + + call s:AutoUpdate(curfile, 0) + + if !in_tagbar + call s:goto_win('p') + endif +endfunction + +" s:MapKeys() {{{2 +function! s:MapKeys() abort + call s:debug('Mapping keys') + + nnoremap )', bygroups(using(XmlLexer), + Other, + using(XmlLexer))), + (r'(.+?)(?=<)', using(XmlLexer)), + (r'.+', using(XmlLexer)), + ], + } + + +# TODO support multiple languages within the same source file +class CSharpAspxLexer(DelegatingLexer): + """ + Lexer for highligting C# within ASP.NET pages. + """ + + name = 'aspx-cs' + aliases = ['aspx-cs'] + filenames = ['*.aspx', '*.asax', '*.ascx', '*.ashx', '*.asmx', '*.axd'] + mimetypes = [] + + def __init__(self, **options): + super(CSharpAspxLexer, self).__init__(CSharpLexer, GenericAspxLexer, + **options) + + def analyse_text(text): + if re.search(r'Page\s*Language="C#"', text, re.I) is not None: + return 0.2 + elif re.search(r'script[^>]+language=["\']C#', text, re.I) is not None: + return 0.15 + + +class VbNetAspxLexer(DelegatingLexer): + """ + Lexer for highligting Visual Basic.net within ASP.NET pages. + """ + + name = 'aspx-vb' + aliases = ['aspx-vb'] + filenames = ['*.aspx', '*.asax', '*.ascx', '*.ashx', '*.asmx', '*.axd'] + mimetypes = [] + + def __init__(self, **options): + super(VbNetAspxLexer, self).__init__(VbNetLexer, GenericAspxLexer, + **options) + + def analyse_text(text): + if re.search(r'Page\s*Language="Vb"', text, re.I) is not None: + return 0.2 + elif re.search(r'script[^>]+language=["\']vb', text, re.I) is not None: + return 0.15 + + +# Very close to functional.OcamlLexer +class FSharpLexer(RegexLexer): + """ + For the F# language (version 3.0). + + AAAAACK Strings + http://research.microsoft.com/en-us/um/cambridge/projects/fsharp/manual/spec.html#_Toc335818775 + + .. versionadded:: 1.5 + """ + + name = 'FSharp' + aliases = ['fsharp'] + filenames = ['*.fs', '*.fsi'] + mimetypes = ['text/x-fsharp'] + + keywords = [ + 'abstract', 'as', 'assert', 'base', 'begin', 'class', 'default', + 'delegate', 'do!', 'do', 'done', 'downcast', 'downto', 'elif', 'else', + 'end', 'exception', 'extern', 'false', 'finally', 'for', 'function', + 'fun', 'global', 'if', 'inherit', 'inline', 'interface', 'internal', + 'in', 'lazy', 'let!', 'let', 'match', 'member', 'module', 'mutable', + 'namespace', 'new', 'null', 'of', 'open', 'override', 'private', 'public', + 'rec', 'return!', 'return', 'select', 'static', 'struct', 'then', 'to', + 'true', 'try', 'type', 'upcast', 'use!', 'use', 'val', 'void', 'when', + 'while', 'with', 'yield!', 'yield', + ] + # Reserved words; cannot hurt to color them as keywords too. + keywords += [ + 'atomic', 'break', 'checked', 'component', 'const', 'constraint', + 'constructor', 'continue', 'eager', 'event', 'external', 'fixed', + 'functor', 'include', 'method', 'mixin', 'object', 'parallel', + 'process', 'protected', 'pure', 'sealed', 'tailcall', 'trait', + 'virtual', 'volatile', + ] + keyopts = [ + '!=', '#', '&&', '&', '\(', '\)', '\*', '\+', ',', '-\.', + '->', '-', '\.\.', '\.', '::', ':=', ':>', ':', ';;', ';', '<-', + '<\]', '<', '>\]', '>', '\?\?', '\?', '\[<', '\[\|', '\[', '\]', + '_', '`', '\{', '\|\]', '\|', '\}', '~', '<@@', '<@', '=', '@>', '@@>', + ] + + operators = r'[!$%&*+\./:<=>?@^|~-]' + word_operators = ['and', 'or', 'not'] + prefix_syms = r'[!?~]' + infix_syms = r'[=<>@^|&+\*/$%-]' + primitives = [ + 'sbyte', 'byte', 'char', 'nativeint', 'unativeint', 'float32', 'single', + 'float', 'double', 'int8', 'uint8', 'int16', 'uint16', 'int32', + 'uint32', 'int64', 'uint64', 'decimal', 'unit', 'bool', 'string', + 'list', 'exn', 'obj', 'enum', + ] + + # See http://msdn.microsoft.com/en-us/library/dd233181.aspx and/or + # http://fsharp.org/about/files/spec.pdf for reference. Good luck. + + tokens = { + 'escape-sequence': [ + (r'\\[\\"\'ntbrafv]', String.Escape), + (r'\\[0-9]{3}', String.Escape), + (r'\\u[0-9a-fA-F]{4}', String.Escape), + (r'\\U[0-9a-fA-F]{8}', String.Escape), + ], + 'root': [ + (r'\s+', Text), + (r'\(\)|\[\]', Name.Builtin.Pseudo), + (r'\b(?`_ + definition files. + + .. versionadded:: 1.4 + """ + + name = 'Protocol Buffer' + aliases = ['protobuf', 'proto'] + filenames = ['*.proto'] + + tokens = { + 'root': [ + (r'[ \t]+', Text), + (r'[,;{}\[\]()]', Punctuation), + (r'/(\\\n)?/(\n|(.|\n)*?[^\\]\n)', Comment.Single), + (r'/(\\\n)?\*(.|\n)*?\*(\\\n)?/', Comment.Multiline), + (words(( + 'import', 'option', 'optional', 'required', 'repeated', 'default', + 'packed', 'ctype', 'extensions', 'to', 'max', 'rpc', 'returns', + 'oneof'), prefix=r'\b', suffix=r'\b'), + Keyword), + (words(( + 'int32', 'int64', 'uint32', 'uint64', 'sint32', 'sint64', + 'fixed32', 'fixed64', 'sfixed32', 'sfixed64', + 'float', 'double', 'bool', 'string', 'bytes'), suffix=r'\b'), + Keyword.Type), + (r'(true|false)\b', Keyword.Constant), + (r'(package)(\s+)', bygroups(Keyword.Namespace, Text), 'package'), + (r'(message|extend)(\s+)', + bygroups(Keyword.Declaration, Text), 'message'), + (r'(enum|group|service)(\s+)', + bygroups(Keyword.Declaration, Text), 'type'), + (r'\".*?\"', String), + (r'\'.*?\'', String), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[LlUu]*', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'(\-?(inf|nan))\b', Number.Float), + (r'0x[0-9a-fA-F]+[LlUu]*', Number.Hex), + (r'0[0-7]+[LlUu]*', Number.Oct), + (r'\d+[LlUu]*', Number.Integer), + (r'[+-=]', Operator), + (r'([a-zA-Z_][\w.]*)([ \t]*)(=)', + bygroups(Name.Attribute, Text, Operator)), + ('[a-zA-Z_][\w.]*', Name), + ], + 'package': [ + (r'[a-zA-Z_]\w*', Name.Namespace, '#pop'), + default('#pop'), + ], + 'message': [ + (r'[a-zA-Z_]\w*', Name.Class, '#pop'), + default('#pop'), + ], + 'type': [ + (r'[a-zA-Z_]\w*', Name, '#pop'), + default('#pop'), + ], + } + + +class BroLexer(RegexLexer): + """ + For `Bro `_ scripts. + + .. versionadded:: 1.5 + """ + name = 'Bro' + aliases = ['bro'] + filenames = ['*.bro'] + + _hex = r'[0-9a-fA-F_]' + _float = r'((\d*\.?\d+)|(\d+\.?\d*))([eE][-+]?\d+)?' + _h = r'[A-Za-z0-9][-A-Za-z0-9]*' + + tokens = { + 'root': [ + # Whitespace + (r'^@.*?\n', Comment.Preproc), + (r'#.*?\n', Comment.Single), + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), + # Keywords + (r'(add|alarm|break|case|const|continue|delete|do|else|enum|event' + r'|export|for|function|if|global|hook|local|module|next' + r'|of|print|redef|return|schedule|switch|type|when|while)\b', Keyword), + (r'(addr|any|bool|count|counter|double|file|int|interval|net' + r'|pattern|port|record|set|string|subnet|table|time|timer' + r'|vector)\b', Keyword.Type), + (r'(T|F)\b', Keyword.Constant), + (r'(&)((?:add|delete|expire)_func|attr|(?:create|read|write)_expire' + r'|default|disable_print_hook|raw_output|encrypt|group|log' + r'|mergeable|optional|persistent|priority|redef' + r'|rotate_(?:interval|size)|synchronized)\b', + bygroups(Punctuation, Keyword)), + (r'\s+module\b', Keyword.Namespace), + # Addresses, ports and networks + (r'\d+/(tcp|udp|icmp|unknown)\b', Number), + (r'(\d+\.){3}\d+', Number), + (r'(' + _hex + r'){7}' + _hex, Number), + (r'0x' + _hex + r'(' + _hex + r'|:)*::(' + _hex + r'|:)*', Number), + (r'((\d+|:)(' + _hex + r'|:)*)?::(' + _hex + r'|:)*', Number), + (r'(\d+\.\d+\.|(\d+\.){2}\d+)', Number), + # Hostnames + (_h + r'(\.' + _h + r')+', String), + # Numeric + (_float + r'\s+(day|hr|min|sec|msec|usec)s?\b', Literal.Date), + (r'0[xX]' + _hex, Number.Hex), + (_float, Number.Float), + (r'\d+', Number.Integer), + (r'/', String.Regex, 'regex'), + (r'"', String, 'string'), + # Operators + (r'[!%*/+:<=>?~|-]', Operator), + (r'([-+=&|]{2}|[+=!><-]=)', Operator), + (r'(in|match)\b', Operator.Word), + (r'[{}()\[\]$.,;]', Punctuation), + # Identfier + (r'([_a-zA-Z]\w*)(::)', bygroups(Name, Name.Namespace)), + (r'[a-zA-Z_]\w*', Name) + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), + (r'\\\n', String), + (r'\\', String) + ], + 'regex': [ + (r'/', String.Regex, '#pop'), + (r'\\[\\nt/]', String.Regex), # String.Escape is too intense here. + (r'[^\\/\n]+', String.Regex), + (r'\\\n', String.Regex), + (r'\\', String.Regex) + ] + } + + +class PuppetLexer(RegexLexer): + """ + For `Puppet `__ configuration DSL. + + .. versionadded:: 1.6 + """ + name = 'Puppet' + aliases = ['puppet'] + filenames = ['*.pp'] + + tokens = { + 'root': [ + include('comments'), + include('keywords'), + include('names'), + include('numbers'), + include('operators'), + include('strings'), + + (r'[]{}:(),;[]', Punctuation), + (r'[^\S\n]+', Text), + ], + + 'comments': [ + (r'\s*#.*$', Comment), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + ], + + 'operators': [ + (r'(=>|\?|<|>|=|\+|-|/|\*|~|!|\|)', Operator), + (r'(in|and|or|not)\b', Operator.Word), + ], + + 'names': [ + ('[a-zA-Z_]\w*', Name.Attribute), + (r'(\$\S+)(\[)(\S+)(\])', bygroups(Name.Variable, Punctuation, + String, Punctuation)), + (r'\$\S+', Name.Variable), + ], + + 'numbers': [ + # Copypasta from the Python lexer + (r'(\d+\.\d*|\d*\.\d+)([eE][+-]?[0-9]+)?j?', Number.Float), + (r'\d+[eE][+-]?[0-9]+j?', Number.Float), + (r'0[0-7]+j?', Number.Oct), + (r'0[xX][a-fA-F0-9]+', Number.Hex), + (r'\d+L', Number.Integer.Long), + (r'\d+j?', Number.Integer) + ], + + 'keywords': [ + # Left out 'group' and 'require' + # Since they're often used as attributes + (words(( + 'absent', 'alert', 'alias', 'audit', 'augeas', 'before', 'case', + 'check', 'class', 'computer', 'configured', 'contained', + 'create_resources', 'crit', 'cron', 'debug', 'default', + 'define', 'defined', 'directory', 'else', 'elsif', 'emerg', + 'err', 'exec', 'extlookup', 'fail', 'false', 'file', + 'filebucket', 'fqdn_rand', 'generate', 'host', 'if', 'import', + 'include', 'info', 'inherits', 'inline_template', 'installed', + 'interface', 'k5login', 'latest', 'link', 'loglevel', + 'macauthorization', 'mailalias', 'maillist', 'mcx', 'md5', + 'mount', 'mounted', 'nagios_command', 'nagios_contact', + 'nagios_contactgroup', 'nagios_host', 'nagios_hostdependency', + 'nagios_hostescalation', 'nagios_hostextinfo', 'nagios_hostgroup', + 'nagios_service', 'nagios_servicedependency', 'nagios_serviceescalation', + 'nagios_serviceextinfo', 'nagios_servicegroup', 'nagios_timeperiod', + 'node', 'noop', 'notice', 'notify', 'package', 'present', 'purged', + 'realize', 'regsubst', 'resources', 'role', 'router', 'running', + 'schedule', 'scheduled_task', 'search', 'selboolean', 'selmodule', + 'service', 'sha1', 'shellquote', 'split', 'sprintf', + 'ssh_authorized_key', 'sshkey', 'stage', 'stopped', 'subscribe', + 'tag', 'tagged', 'template', 'tidy', 'true', 'undef', 'unmounted', + 'user', 'versioncmp', 'vlan', 'warning', 'yumrepo', 'zfs', 'zone', + 'zpool'), prefix='(?i)', suffix=r'\b'), + Keyword), + ], + + 'strings': [ + (r'"([^"])*"', String), + (r"'(\\'|[^'])*'", String), + ], + + } + + +class RslLexer(RegexLexer): + """ + `RSL `_ is the formal specification + language used in RAISE (Rigorous Approach to Industrial Software Engineering) + method. + + .. versionadded:: 2.0 + """ + name = 'RSL' + aliases = ['rsl'] + filenames = ['*.rsl'] + mimetypes = ['text/rsl'] + + flags = re.MULTILINE | re.DOTALL + + tokens = { + 'root': [ + (words(( + 'Bool', 'Char', 'Int', 'Nat', 'Real', 'Text', 'Unit', 'abs', + 'all', 'always', 'any', 'as', 'axiom', 'card', 'case', 'channel', + 'chaos', 'class', 'devt_relation', 'dom', 'elems', 'else', 'elif', + 'end', 'exists', 'extend', 'false', 'for', 'hd', 'hide', 'if', + 'in', 'is', 'inds', 'initialise', 'int', 'inter', 'isin', 'len', + 'let', 'local', 'ltl_assertion', 'object', 'of', 'out', 'post', + 'pre', 'read', 'real', 'rng', 'scheme', 'skip', 'stop', 'swap', + 'then', 'theory', 'test_case', 'tl', 'transition_system', 'true', + 'type', 'union', 'until', 'use', 'value', 'variable', 'while', + 'with', 'write', '~isin', '-inflist', '-infset', '-list', + '-set'), prefix=r'\b', suffix=r'\b'), + Keyword), + (r'(variable|value)\b', Keyword.Declaration), + (r'--.*?\n', Comment), + (r'<:.*?:>', Comment), + (r'\{!.*?!\}', Comment), + (r'/\*.*?\*/', Comment), + (r'^[ \t]*([\w]+)[ \t]*:[^:]', Name.Function), + (r'(^[ \t]*)([\w]+)([ \t]*\([\w\s,]*\)[ \t]*)(is|as)', + bygroups(Text, Name.Function, Text, Keyword)), + (r'\b[A-Z]\w*\b', Keyword.Type), + (r'(true|false)\b', Keyword.Constant), + (r'".*"', String), + (r'\'.\'', String.Char), + (r'(><|->|-m->|/\\|<=|<<=|<\.|\|\||\|\^\||-~->|-~m->|\\/|>=|>>|' + r'\.>|\+\+|-\\|<->|=>|:-|~=|\*\*|<<|>>=|\+>|!!|\|=\||#)', + Operator), + (r'[0-9]+\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float), + (r'0x[0-9a-f]+', Number.Hex), + (r'[0-9]+', Number.Integer), + (r'.', Text), + ], + } + + def analyse_text(text): + """ + Check for the most common text in the beginning of a RSL file. + """ + if re.search(r'scheme\s*.*?=\s*class\s*type', text, re.I) is not None: + return 1.0 + + +class MscgenLexer(RegexLexer): + """ + For `Mscgen `_ files. + + .. versionadded:: 1.6 + """ + name = 'Mscgen' + aliases = ['mscgen', 'msc'] + filenames = ['*.msc'] + + _var = r'(\w+|"(?:\\"|[^"])*")' + + tokens = { + 'root': [ + (r'msc\b', Keyword.Type), + # Options + (r'(hscale|HSCALE|width|WIDTH|wordwraparcs|WORDWRAPARCS' + r'|arcgradient|ARCGRADIENT)\b', Name.Property), + # Operators + (r'(abox|ABOX|rbox|RBOX|box|BOX|note|NOTE)\b', Operator.Word), + (r'(\.|-|\|){3}', Keyword), + (r'(?:-|=|\.|:){2}' + r'|<<=>>|<->|<=>|<<>>|<:>' + r'|->|=>>|>>|=>|:>|-x|-X' + r'|<-|<<=|<<|<=|<:|x-|X-|=', Operator), + # Names + (r'\*', Name.Builtin), + (_var, Name.Variable), + # Other + (r'\[', Punctuation, 'attrs'), + (r'\{|\}|,|;', Punctuation), + include('comments') + ], + 'attrs': [ + (r'\]', Punctuation, '#pop'), + (_var + r'(\s*)(=)(\s*)' + _var, + bygroups(Name.Attribute, Text.Whitespace, Operator, Text.Whitespace, + String)), + (r',', Punctuation), + include('comments') + ], + 'comments': [ + (r'(?://|#).*?\n', Comment.Single), + (r'/\*(?:.|\n)*?\*/', Comment.Multiline), + (r'[ \t\r\n]+', Text.Whitespace) + ] + } + + +class VGLLexer(RegexLexer): + """ + For `SampleManager VGL `_ + source code. + + .. versionadded:: 1.6 + """ + name = 'VGL' + aliases = ['vgl'] + filenames = ['*.rpf'] + + flags = re.MULTILINE | re.DOTALL | re.IGNORECASE + + tokens = { + 'root': [ + (r'\{[^}]*\}', Comment.Multiline), + (r'declare', Keyword.Constant), + (r'(if|then|else|endif|while|do|endwhile|and|or|prompt|object' + r'|create|on|line|with|global|routine|value|endroutine|constant' + r'|global|set|join|library|compile_option|file|exists|create|copy' + r'|delete|enable|windows|name|notprotected)(?! *[=<>.,()])', + Keyword), + (r'(true|false|null|empty|error|locked)', Keyword.Constant), + (r'[~^*#!%&\[\]()<>|+=:;,./?-]', Operator), + (r'"[^"]*"', String), + (r'(\.)([a-z_$][\w$]*)', bygroups(Operator, Name.Attribute)), + (r'[0-9][0-9]*(\.[0-9]+(e[+\-]?[0-9]+)?)?', Number), + (r'[a-z_$][\w$]*', Name), + (r'[\r\n]+', Text), + (r'\s+', Text) + ] + } + + +class AlloyLexer(RegexLexer): + """ + For `Alloy `_ source code. + + .. versionadded:: 2.0 + """ + + name = 'Alloy' + aliases = ['alloy'] + filenames = ['*.als'] + mimetypes = ['text/x-alloy'] + + flags = re.MULTILINE | re.DOTALL + + iden_rex = r'[a-zA-Z_][\w\']*' + text_tuple = (r'[^\S\n]+', Text) + + tokens = { + 'sig': [ + (r'(extends)\b', Keyword, '#pop'), + (iden_rex, Name), + text_tuple, + (r',', Punctuation), + (r'\{', Operator, '#pop'), + ], + 'module': [ + text_tuple, + (iden_rex, Name, '#pop'), + ], + 'fun': [ + text_tuple, + (r'\{', Operator, '#pop'), + (iden_rex, Name, '#pop'), + ], + 'root': [ + (r'--.*?$', Comment.Single), + (r'//.*?$', Comment.Single), + (r'/\*.*?\*/', Comment.Multiline), + text_tuple, + (r'(module|open)(\s+)', bygroups(Keyword.Namespace, Text), + 'module'), + (r'(sig|enum)(\s+)', bygroups(Keyword.Declaration, Text), 'sig'), + (r'(iden|univ|none)\b', Keyword.Constant), + (r'(int|Int)\b', Keyword.Type), + (r'(this|abstract|extends|set|seq|one|lone|let)\b', Keyword), + (r'(all|some|no|sum|disj|when|else)\b', Keyword), + (r'(run|check|for|but|exactly|expect|as)\b', Keyword), + (r'(and|or|implies|iff|in)\b', Operator.Word), + (r'(fun|pred|fact|assert)(\s+)', bygroups(Keyword, Text), 'fun'), + (r'!|#|&&|\+\+|<<|>>|>=|<=>|<=|\.|->', Operator), + (r'[-+/*%=<>&!^|~{}\[\]().]', Operator), + (iden_rex, Name), + (r'[:,]', Punctuation), + (r'[0-9]+', Number.Integer), + (r'"(\\\\|\\"|[^"])*"', String), + (r'\n', Text), + ] + } + + +class PanLexer(RegexLexer): + """ + Lexer for `pan `_ source files. + + Based on tcsh lexer. + + .. versionadded:: 2.0 + """ + + name = 'Pan' + aliases = ['pan'] + filenames = ['*.pan'] + + tokens = { + 'root': [ + include('basic'), + (r'\(', Keyword, 'paren'), + (r'\{', Keyword, 'curly'), + include('data'), + ], + 'basic': [ + (words(( + 'if', 'for', 'with', 'else', 'type', 'bind', 'while', 'valid', 'final', 'prefix', + 'unique', 'object', 'foreach', 'include', 'template', 'function', 'variable', + 'structure', 'extensible', 'declaration'), prefix=r'\b', suffix=r'\s*\b'), + Keyword), + (words(( + 'file_contents', 'format', 'index', 'length', 'match', 'matches', 'replace', + 'splice', 'split', 'substr', 'to_lowercase', 'to_uppercase', 'debug', 'error', + 'traceback', 'deprecated', 'base64_decode', 'base64_encode', 'digest', 'escape', + 'unescape', 'append', 'create', 'first', 'nlist', 'key', 'list', 'merge', 'next', + 'prepend', 'is_boolean', 'is_defined', 'is_double', 'is_list', 'is_long', + 'is_nlist', 'is_null', 'is_number', 'is_property', 'is_resource', 'is_string', + 'to_boolean', 'to_double', 'to_long', 'to_string', 'clone', 'delete', 'exists', + 'path_exists', 'if_exists', 'return', 'value'), prefix=r'\b', suffix=r'\s*\b'), + Name.Builtin), + (r'#.*', Comment), + (r'\\[\w\W]', String.Escape), + (r'(\b\w+)(\s*)(=)', bygroups(Name.Variable, Text, Operator)), + (r'[\[\]{}()=]+', Operator), + (r'<<\s*(\'?)\\?(\w+)[\w\W]+?\2', String), + (r';', Punctuation), + ], + 'data': [ + (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double), + (r"(?s)'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single), + (r'\s+', Text), + (r'[^=\s\[\]{}()$"\'`\\;#]+', Text), + (r'\d+(?= |\Z)', Number), + ], + 'curly': [ + (r'\}', Keyword, '#pop'), + (r':-', Keyword), + (r'\w+', Name.Variable), + (r'[^}:"\'`$]+', Punctuation), + (r':', Punctuation), + include('root'), + ], + 'paren': [ + (r'\)', Keyword, '#pop'), + include('root'), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dylan.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dylan.py new file mode 100644 index 0000000000..9875fc0863 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/dylan.py @@ -0,0 +1,289 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.dylan + ~~~~~~~~~~~~~~~~~~~~~ + + Lexers for the Dylan language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, bygroups, do_insertions, default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Generic, Literal + +__all__ = ['DylanLexer', 'DylanConsoleLexer', 'DylanLidLexer'] + + +class DylanLexer(RegexLexer): + """ + For the `Dylan `_ language. + + .. versionadded:: 0.7 + """ + + name = 'Dylan' + aliases = ['dylan'] + filenames = ['*.dylan', '*.dyl', '*.intr'] + mimetypes = ['text/x-dylan'] + + flags = re.IGNORECASE + + builtins = set(( + 'subclass', 'abstract', 'block', 'concrete', 'constant', 'class', + 'compiler-open', 'compiler-sideways', 'domain', 'dynamic', + 'each-subclass', 'exception', 'exclude', 'function', 'generic', + 'handler', 'inherited', 'inline', 'inline-only', 'instance', + 'interface', 'import', 'keyword', 'library', 'macro', 'method', + 'module', 'open', 'primary', 'required', 'sealed', 'sideways', + 'singleton', 'slot', 'thread', 'variable', 'virtual')) + + keywords = set(( + 'above', 'afterwards', 'begin', 'below', 'by', 'case', 'cleanup', + 'create', 'define', 'else', 'elseif', 'end', 'export', 'finally', + 'for', 'from', 'if', 'in', 'let', 'local', 'otherwise', 'rename', + 'select', 'signal', 'then', 'to', 'unless', 'until', 'use', 'when', + 'while')) + + operators = set(( + '~', '+', '-', '*', '|', '^', '=', '==', '~=', '~==', '<', '<=', + '>', '>=', '&', '|')) + + functions = set(( + 'abort', 'abs', 'add', 'add!', 'add-method', 'add-new', 'add-new!', + 'all-superclasses', 'always', 'any?', 'applicable-method?', 'apply', + 'aref', 'aref-setter', 'as', 'as-lowercase', 'as-lowercase!', + 'as-uppercase', 'as-uppercase!', 'ash', 'backward-iteration-protocol', + 'break', 'ceiling', 'ceiling/', 'cerror', 'check-type', 'choose', + 'choose-by', 'complement', 'compose', 'concatenate', 'concatenate-as', + 'condition-format-arguments', 'condition-format-string', 'conjoin', + 'copy-sequence', 'curry', 'default-handler', 'dimension', 'dimensions', + 'direct-subclasses', 'direct-superclasses', 'disjoin', 'do', + 'do-handlers', 'element', 'element-setter', 'empty?', 'error', 'even?', + 'every?', 'false-or', 'fill!', 'find-key', 'find-method', 'first', + 'first-setter', 'floor', 'floor/', 'forward-iteration-protocol', + 'function-arguments', 'function-return-values', + 'function-specializers', 'gcd', 'generic-function-mandatory-keywords', + 'generic-function-methods', 'head', 'head-setter', 'identity', + 'initialize', 'instance?', 'integral?', 'intersection', + 'key-sequence', 'key-test', 'last', 'last-setter', 'lcm', 'limited', + 'list', 'logand', 'logbit?', 'logior', 'lognot', 'logxor', 'make', + 'map', 'map-as', 'map-into', 'max', 'member?', 'merge-hash-codes', + 'min', 'modulo', 'negative', 'negative?', 'next-method', + 'object-class', 'object-hash', 'odd?', 'one-of', 'pair', 'pop', + 'pop-last', 'positive?', 'push', 'push-last', 'range', 'rank', + 'rcurry', 'reduce', 'reduce1', 'remainder', 'remove', 'remove!', + 'remove-duplicates', 'remove-duplicates!', 'remove-key!', + 'remove-method', 'replace-elements!', 'replace-subsequence!', + 'restart-query', 'return-allowed?', 'return-description', + 'return-query', 'reverse', 'reverse!', 'round', 'round/', + 'row-major-index', 'second', 'second-setter', 'shallow-copy', + 'signal', 'singleton', 'size', 'size-setter', 'slot-initialized?', + 'sort', 'sort!', 'sorted-applicable-methods', 'subsequence-position', + 'subtype?', 'table-protocol', 'tail', 'tail-setter', 'third', + 'third-setter', 'truncate', 'truncate/', 'type-error-expected-type', + 'type-error-value', 'type-for-copy', 'type-union', 'union', 'values', + 'vector', 'zero?')) + + valid_name = '\\\\?[\\w!&*<>|^$%@\\-+~?/=]+' + + def get_tokens_unprocessed(self, text): + for index, token, value in RegexLexer.get_tokens_unprocessed(self, text): + if token is Name: + lowercase_value = value.lower() + if lowercase_value in self.builtins: + yield index, Name.Builtin, value + continue + if lowercase_value in self.keywords: + yield index, Keyword, value + continue + if lowercase_value in self.functions: + yield index, Name.Builtin, value + continue + if lowercase_value in self.operators: + yield index, Operator, value + continue + yield index, token, value + + tokens = { + 'root': [ + # Whitespace + (r'\s+', Text), + + # single line comment + (r'//.*?\n', Comment.Single), + + # lid header + (r'([a-z0-9-]+)(:)([ \t]*)(.*(?:\n[ \t].+)*)', + bygroups(Name.Attribute, Operator, Text, String)), + + default('code') # no header match, switch to code + ], + 'code': [ + # Whitespace + (r'\s+', Text), + + # single line comment + (r'//.*?\n', Comment.Single), + + # multi-line comment + (r'/\*', Comment.Multiline, 'comment'), + + # strings and characters + (r'"', String, 'string'), + (r"'(\\.|\\[0-7]{1,3}|\\x[a-f0-9]{1,2}|[^\\\'\n])'", String.Char), + + # binary integer + (r'#b[01]+', Number.Bin), + + # octal integer + (r'#o[0-7]+', Number.Oct), + + # floating point + (r'[-+]?(\d*\.\d+(e[-+]?\d+)?|\d+(\.\d*)?e[-+]?\d+)', Number.Float), + + # decimal integer + (r'[-+]?\d+', Number.Integer), + + # hex integer + (r'#x[0-9a-f]+', Number.Hex), + + # Macro parameters + (r'(\?' + valid_name + ')(:)' + r'(token|name|variable|expression|body|case-body|\*)', + bygroups(Name.Tag, Operator, Name.Builtin)), + (r'(\?)(:)(token|name|variable|expression|body|case-body|\*)', + bygroups(Name.Tag, Operator, Name.Builtin)), + (r'\?' + valid_name, Name.Tag), + + # Punctuation + (r'(=>|::|#\(|#\[|##|\?\?|\?=|\?|[(){}\[\],.;])', Punctuation), + + # Most operators are picked up as names and then re-flagged. + # This one isn't valid in a name though, so we pick it up now. + (r':=', Operator), + + # Pick up #t / #f before we match other stuff with #. + (r'#[tf]', Literal), + + # #"foo" style keywords + (r'#"', String.Symbol, 'keyword'), + + # #rest, #key, #all-keys, etc. + (r'#[a-z0-9-]+', Keyword), + + # required-init-keyword: style keywords. + (valid_name + ':', Keyword), + + # class names + (r'<' + valid_name + '>', Name.Class), + + # define variable forms. + (r'\*' + valid_name + '\*', Name.Variable.Global), + + # define constant forms. + (r'\$' + valid_name, Name.Constant), + + # everything else. We re-flag some of these in the method above. + (valid_name, Name), + ], + 'comment': [ + (r'[^*/]', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline) + ], + 'keyword': [ + (r'"', String.Symbol, '#pop'), + (r'[^\\"]+', String.Symbol), # all other characters + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-f0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # stray backslash + ] + } + + +class DylanLidLexer(RegexLexer): + """ + For Dylan LID (Library Interchange Definition) files. + + .. versionadded:: 1.6 + """ + + name = 'DylanLID' + aliases = ['dylan-lid', 'lid'] + filenames = ['*.lid', '*.hdp'] + mimetypes = ['text/x-dylan-lid'] + + flags = re.IGNORECASE + + tokens = { + 'root': [ + # Whitespace + (r'\s+', Text), + + # single line comment + (r'//.*?\n', Comment.Single), + + # lid header + (r'(.*?)(:)([ \t]*)(.*(?:\n[ \t].+)*)', + bygroups(Name.Attribute, Operator, Text, String)), + ] + } + + +class DylanConsoleLexer(Lexer): + """ + For Dylan interactive console output like: + + .. sourcecode:: dylan-console + + ? let a = 1; + => 1 + ? a + => 1 + + This is based on a copy of the RubyConsoleLexer. + + .. versionadded:: 1.6 + """ + name = 'Dylan session' + aliases = ['dylan-console', 'dylan-repl'] + filenames = ['*.dylan-console'] + mimetypes = ['text/x-dylan-console'] + + _line_re = re.compile('.*?\n') + _prompt_re = re.compile('\?| ') + + def get_tokens_unprocessed(self, text): + dylexer = DylanLexer(**self.options) + + curcode = '' + insertions = [] + for match in self._line_re.finditer(text): + line = match.group() + m = self._prompt_re.match(line) + if m is not None: + end = m.end() + insertions.append((len(curcode), + [(0, Generic.Prompt, line[:end])])) + curcode += line[end:] + else: + if curcode: + for item in do_insertions(insertions, + dylexer.get_tokens_unprocessed(curcode)): + yield item + curcode = '' + insertions = [] + yield match.start(), Generic.Output, line + if curcode: + for item in do_insertions(insertions, + dylexer.get_tokens_unprocessed(curcode)): + yield item diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ecl.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ecl.py new file mode 100644 index 0000000000..5c9b3bd1f7 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ecl.py @@ -0,0 +1,125 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.ecl + ~~~~~~~~~~~~~~~~~~~ + + Lexers for the ECL language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error + +__all__ = ['ECLLexer'] + + +class ECLLexer(RegexLexer): + """ + Lexer for the declarative big-data `ECL + `_ + language. + + .. versionadded:: 1.5 + """ + + name = 'ECL' + aliases = ['ecl'] + filenames = ['*.ecl'] + mimetypes = ['application/x-ecl'] + + flags = re.IGNORECASE | re.MULTILINE + + tokens = { + 'root': [ + include('whitespace'), + include('statements'), + ], + 'whitespace': [ + (r'\s+', Text), + (r'\/\/.*', Comment.Single), + (r'/(\\\n)?\*(.|\n)*?\*(\\\n)?/', Comment.Multiline), + ], + 'statements': [ + include('types'), + include('keywords'), + include('functions'), + include('hash'), + (r'"', String, 'string'), + (r'\'', String, 'string'), + (r'(\d+\.\d*|\.\d+|\d+)e[+-]?\d+[lu]*', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+f)f?', Number.Float), + (r'0x[0-9a-f]+[lu]*', Number.Hex), + (r'0[0-7]+[lu]*', Number.Oct), + (r'\d+[lu]*', Number.Integer), + (r'\*/', Error), + (r'[~!%^&*+=|?:<>/-]+', Operator), + (r'[{}()\[\],.;]', Punctuation), + (r'[a-z_]\w*', Name), + ], + 'hash': [ + (r'^#.*$', Comment.Preproc), + ], + 'types': [ + (r'(RECORD|END)\D', Keyword.Declaration), + (r'((?:ASCII|BIG_ENDIAN|BOOLEAN|DATA|DECIMAL|EBCDIC|INTEGER|PATTERN|' + r'QSTRING|REAL|RECORD|RULE|SET OF|STRING|TOKEN|UDECIMAL|UNICODE|' + r'UNSIGNED|VARSTRING|VARUNICODE)\d*)(\s+)', + bygroups(Keyword.Type, Text)), + ], + 'keywords': [ + (words(( + 'APPLY', 'ASSERT', 'BUILD', 'BUILDINDEX', 'EVALUATE', 'FAIL', + 'KEYDIFF', 'KEYPATCH', 'LOADXML', 'NOTHOR', 'NOTIFY', 'OUTPUT', + 'PARALLEL', 'SEQUENTIAL', 'SOAPCALL', 'CHECKPOINT', 'DEPRECATED', + 'FAILCODE', 'FAILMESSAGE', 'FAILURE', 'GLOBAL', 'INDEPENDENT', + 'ONWARNING', 'PERSIST', 'PRIORITY', 'RECOVERY', 'STORED', 'SUCCESS', + 'WAIT', 'WHEN'), suffix=r'\b'), + Keyword.Reserved), + # These are classed differently, check later + (words(( + 'ALL', 'AND', 'ANY', 'AS', 'ATMOST', 'BEFORE', 'BEGINC++', 'BEST', 'BETWEEN', 'CASE', + 'CONST', 'COUNTER', 'CSV', 'DESCEND', 'ENCRYPT', 'ENDC++', 'ENDMACRO', 'EXCEPT', + 'EXCLUSIVE', 'EXPIRE', 'EXPORT', 'EXTEND', 'FALSE', 'FEW', 'FIRST', 'FLAT', 'FULL', + 'FUNCTION', 'GROUP', 'HEADER', 'HEADING', 'HOLE', 'IFBLOCK', 'IMPORT', 'IN', 'JOINED', + 'KEEP', 'KEYED', 'LAST', 'LEFT', 'LIMIT', 'LOAD', 'LOCAL', 'LOCALE', 'LOOKUP', 'MACRO', + 'MANY', 'MAXCOUNT', 'MAXLENGTH', 'MIN SKEW', 'MODULE', 'INTERFACE', 'NAMED', 'NOCASE', + 'NOROOT', 'NOSCAN', 'NOSORT', 'NOT', 'OF', 'ONLY', 'OPT', 'OR', 'OUTER', 'OVERWRITE', + 'PACKED', 'PARTITION', 'PENALTY', 'PHYSICALLENGTH', 'PIPE', 'QUOTE', 'RELATIONSHIP', + 'REPEAT', 'RETURN', 'RIGHT', 'SCAN', 'SELF', 'SEPARATOR', 'SERVICE', 'SHARED', 'SKEW', + 'SKIP', 'SQL', 'STORE', 'TERMINATOR', 'THOR', 'THRESHOLD', 'TOKEN', 'TRANSFORM', 'TRIM', + 'TRUE', 'TYPE', 'UNICODEORDER', 'UNSORTED', 'VALIDATE', 'VIRTUAL', 'WHOLE', 'WILD', + 'WITHIN', 'XML', 'XPATH', '__COMPRESSED__'), suffix=r'\b'), + Keyword.Reserved), + ], + 'functions': [ + (words(( + 'ABS', 'ACOS', 'ALLNODES', 'ASCII', 'ASIN', 'ASSTRING', 'ATAN', 'ATAN2', 'AVE', 'CASE', + 'CHOOSE', 'CHOOSEN', 'CHOOSESETS', 'CLUSTERSIZE', 'COMBINE', 'CORRELATION', 'COS', + 'COSH', 'COUNT', 'COVARIANCE', 'CRON', 'DATASET', 'DEDUP', 'DEFINE', 'DENORMALIZE', + 'DISTRIBUTE', 'DISTRIBUTED', 'DISTRIBUTION', 'EBCDIC', 'ENTH', 'ERROR', 'EVALUATE', + 'EVENT', 'EVENTEXTRA', 'EVENTNAME', 'EXISTS', 'EXP', 'FAILCODE', 'FAILMESSAGE', + 'FETCH', 'FROMUNICODE', 'GETISVALID', 'GLOBAL', 'GRAPH', 'GROUP', 'HASH', 'HASH32', + 'HASH64', 'HASHCRC', 'HASHMD5', 'HAVING', 'IF', 'INDEX', 'INTFORMAT', 'ISVALID', + 'ITERATE', 'JOIN', 'KEYUNICODE', 'LENGTH', 'LIBRARY', 'LIMIT', 'LN', 'LOCAL', 'LOG', 'LOOP', + 'MAP', 'MATCHED', 'MATCHLENGTH', 'MATCHPOSITION', 'MATCHTEXT', 'MATCHUNICODE', + 'MAX', 'MERGE', 'MERGEJOIN', 'MIN', 'NOLOCAL', 'NONEMPTY', 'NORMALIZE', 'PARSE', 'PIPE', + 'POWER', 'PRELOAD', 'PROCESS', 'PROJECT', 'PULL', 'RANDOM', 'RANGE', 'RANK', 'RANKED', + 'REALFORMAT', 'RECORDOF', 'REGEXFIND', 'REGEXREPLACE', 'REGROUP', 'REJECTED', + 'ROLLUP', 'ROUND', 'ROUNDUP', 'ROW', 'ROWDIFF', 'SAMPLE', 'SET', 'SIN', 'SINH', 'SIZEOF', + 'SOAPCALL', 'SORT', 'SORTED', 'SQRT', 'STEPPED', 'STORED', 'SUM', 'TABLE', 'TAN', 'TANH', + 'THISNODE', 'TOPN', 'TOUNICODE', 'TRANSFER', 'TRIM', 'TRUNCATE', 'TYPEOF', 'UNGROUP', + 'UNICODEORDER', 'VARIANCE', 'WHICH', 'WORKUNIT', 'XMLDECODE', 'XMLENCODE', + 'XMLTEXT', 'XMLUNICODE'), suffix=r'\b'), + Name.Function), + ], + 'string': [ + (r'"', String, '#pop'), + (r'\'', String, '#pop'), + (r'[^"\']+', String), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/eiffel.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/eiffel.py new file mode 100644 index 0000000000..e3bf81f5e0 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/eiffel.py @@ -0,0 +1,65 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.eiffel + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexer for the Eiffel language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, include, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['EiffelLexer'] + + +class EiffelLexer(RegexLexer): + """ + For `Eiffel `_ source code. + + .. versionadded:: 2.0 + """ + name = 'Eiffel' + aliases = ['eiffel'] + filenames = ['*.e'] + mimetypes = ['text/x-eiffel'] + + tokens = { + 'root': [ + (r'[^\S\n]+', Text), + (r'--.*?\n', Comment.Single), + (r'[^\S\n]+', Text), + # Please note that keyword and operator are case insensitive. + (r'(?i)(true|false|void|current|result|precursor)\b', Keyword.Constant), + (r'(?i)(and(\s+then)?|not|xor|implies|or(\s+else)?)\b', Operator.Word), + (words(( + 'across', 'agent', 'alias', 'all', 'as', 'assign', 'attached', + 'attribute', 'check', 'class', 'convert', 'create', 'debug', + 'deferred', 'detachable', 'do', 'else', 'elseif', 'end', 'ensure', + 'expanded', 'export', 'external', 'feature', 'from', 'frozen', 'if', + 'inherit', 'inspect', 'invariant', 'like', 'local', 'loop', 'none', + 'note', 'obsolete', 'old', 'once', 'only', 'redefine', 'rename', + 'require', 'rescue', 'retry', 'select', 'separate', 'then', + 'undefine', 'until', 'variant', 'when'), prefix=r'(?i)\b', suffix=r'\b'), + Keyword.Reserved), + (r'"\[(([^\]%]|\n)|%(.|\n)|\][^"])*?\]"', String), + (r'"([^"%\n]|%.)*?"', String), + include('numbers'), + (r"'([^'%]|%'|%%)'", String.Char), + (r"(//|\\\\|>=|<=|:=|/=|~|/~|[\\?!#%&@|+/\-=>*$<^\[\]])", Operator), + (r"([{}():;,.])", Punctuation), + (r'([a-z]\w*)|([A-Z][A-Z0-9_]*[a-z]\w*)', Name), + (r'([A-Z][A-Z0-9_]*)', Name.Class), + (r'\n+', Text), + ], + 'numbers': [ + (r'0[xX][a-fA-F0-9]+', Number.Hex), + (r'0[bB][01]+', Number.Bin), + (r'0[cC][0-7]+', Number.Oct), + (r'([0-9]+\.[0-9]*)|([0-9]*\.[0-9]+)', Number.Float), + (r'[0-9]+', Number.Integer), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/erlang.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/erlang.py new file mode 100644 index 0000000000..563f7744c1 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/erlang.py @@ -0,0 +1,511 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.erlang + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Erlang. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, bygroups, words, do_insertions, \ + include, default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Generic + +__all__ = ['ErlangLexer', 'ErlangShellLexer', 'ElixirConsoleLexer', + 'ElixirLexer'] + + +line_re = re.compile('.*?\n') + + +class ErlangLexer(RegexLexer): + """ + For the Erlang functional programming language. + + Blame Jeremy Thurgood (http://jerith.za.net/). + + .. versionadded:: 0.9 + """ + + name = 'Erlang' + aliases = ['erlang'] + filenames = ['*.erl', '*.hrl', '*.es', '*.escript'] + mimetypes = ['text/x-erlang'] + + keywords = ( + 'after', 'begin', 'case', 'catch', 'cond', 'end', 'fun', 'if', + 'let', 'of', 'query', 'receive', 'try', 'when', + ) + + builtins = ( # See erlang(3) man page + 'abs', 'append_element', 'apply', 'atom_to_list', 'binary_to_list', + 'bitstring_to_list', 'binary_to_term', 'bit_size', 'bump_reductions', + 'byte_size', 'cancel_timer', 'check_process_code', 'delete_module', + 'demonitor', 'disconnect_node', 'display', 'element', 'erase', 'exit', + 'float', 'float_to_list', 'fun_info', 'fun_to_list', + 'function_exported', 'garbage_collect', 'get', 'get_keys', + 'group_leader', 'hash', 'hd', 'integer_to_list', 'iolist_to_binary', + 'iolist_size', 'is_atom', 'is_binary', 'is_bitstring', 'is_boolean', + 'is_builtin', 'is_float', 'is_function', 'is_integer', 'is_list', + 'is_number', 'is_pid', 'is_port', 'is_process_alive', 'is_record', + 'is_reference', 'is_tuple', 'length', 'link', 'list_to_atom', + 'list_to_binary', 'list_to_bitstring', 'list_to_existing_atom', + 'list_to_float', 'list_to_integer', 'list_to_pid', 'list_to_tuple', + 'load_module', 'localtime_to_universaltime', 'make_tuple', 'md5', + 'md5_final', 'md5_update', 'memory', 'module_loaded', 'monitor', + 'monitor_node', 'node', 'nodes', 'open_port', 'phash', 'phash2', + 'pid_to_list', 'port_close', 'port_command', 'port_connect', + 'port_control', 'port_call', 'port_info', 'port_to_list', + 'process_display', 'process_flag', 'process_info', 'purge_module', + 'put', 'read_timer', 'ref_to_list', 'register', 'resume_process', + 'round', 'send', 'send_after', 'send_nosuspend', 'set_cookie', + 'setelement', 'size', 'spawn', 'spawn_link', 'spawn_monitor', + 'spawn_opt', 'split_binary', 'start_timer', 'statistics', + 'suspend_process', 'system_flag', 'system_info', 'system_monitor', + 'system_profile', 'term_to_binary', 'tl', 'trace', 'trace_delivered', + 'trace_info', 'trace_pattern', 'trunc', 'tuple_size', 'tuple_to_list', + 'universaltime_to_localtime', 'unlink', 'unregister', 'whereis' + ) + + operators = r'(\+\+?|--?|\*|/|<|>|/=|=:=|=/=|=<|>=|==?|<-|!|\?)' + word_operators = ( + 'and', 'andalso', 'band', 'bnot', 'bor', 'bsl', 'bsr', 'bxor', + 'div', 'not', 'or', 'orelse', 'rem', 'xor' + ) + + atom_re = r"(?:[a-z]\w*|'[^\n']*[^\\]')" + + variable_re = r'(?:[A-Z_]\w*)' + + escape_re = r'(?:\\(?:[bdefnrstv\'"\\/]|[0-7][0-7]?[0-7]?|\^[a-zA-Z]))' + + macro_re = r'(?:'+variable_re+r'|'+atom_re+r')' + + base_re = r'(?:[2-9]|[12][0-9]|3[0-6])' + + tokens = { + 'root': [ + (r'\s+', Text), + (r'%.*\n', Comment), + (words(keywords, suffix=r'\b'), Keyword), + (words(builtins, suffix=r'\b'), Name.Builtin), + (words(word_operators, suffix=r'\b'), Operator.Word), + (r'^-', Punctuation, 'directive'), + (operators, Operator), + (r'"', String, 'string'), + (r'<<', Name.Label), + (r'>>', Name.Label), + ('(' + atom_re + ')(:)', bygroups(Name.Namespace, Punctuation)), + ('(?:^|(?<=:))(' + atom_re + r')(\s*)(\()', + bygroups(Name.Function, Text, Punctuation)), + (r'[+-]?' + base_re + r'#[0-9a-zA-Z]+', Number.Integer), + (r'[+-]?\d+', Number.Integer), + (r'[+-]?\d+.\d+', Number.Float), + (r'[]\[:_@\".{}()|;,]', Punctuation), + (variable_re, Name.Variable), + (atom_re, Name), + (r'\?'+macro_re, Name.Constant), + (r'\$(?:'+escape_re+r'|\\[ %]|[^\\])', String.Char), + (r'#'+atom_re+r'(:?\.'+atom_re+r')?', Name.Label), + ], + 'string': [ + (escape_re, String.Escape), + (r'"', String, '#pop'), + (r'~[0-9.*]*[~#+bBcdefginpPswWxX]', String.Interpol), + (r'[^"\\~]+', String), + (r'~', String), + ], + 'directive': [ + (r'(define)(\s*)(\()('+macro_re+r')', + bygroups(Name.Entity, Text, Punctuation, Name.Constant), '#pop'), + (r'(record)(\s*)(\()('+macro_re+r')', + bygroups(Name.Entity, Text, Punctuation, Name.Label), '#pop'), + (atom_re, Name.Entity, '#pop'), + ], + } + + +class ErlangShellLexer(Lexer): + """ + Shell sessions in erl (for Erlang code). + + .. versionadded:: 1.1 + """ + name = 'Erlang erl session' + aliases = ['erl'] + filenames = ['*.erl-sh'] + mimetypes = ['text/x-erl-shellsession'] + + _prompt_re = re.compile(r'\d+>(?=\s|\Z)') + + def get_tokens_unprocessed(self, text): + erlexer = ErlangLexer(**self.options) + + curcode = '' + insertions = [] + for match in line_re.finditer(text): + line = match.group() + m = self._prompt_re.match(line) + if m is not None: + end = m.end() + insertions.append((len(curcode), + [(0, Generic.Prompt, line[:end])])) + curcode += line[end:] + else: + if curcode: + for item in do_insertions(insertions, + erlexer.get_tokens_unprocessed(curcode)): + yield item + curcode = '' + insertions = [] + if line.startswith('*'): + yield match.start(), Generic.Traceback, line + else: + yield match.start(), Generic.Output, line + if curcode: + for item in do_insertions(insertions, + erlexer.get_tokens_unprocessed(curcode)): + yield item + + +def gen_elixir_string_rules(name, symbol, token): + states = {} + states['string_' + name] = [ + (r'[^#%s\\]+' % (symbol,), token), + include('escapes'), + (r'\\.', token), + (r'(%s)' % (symbol,), bygroups(token), "#pop"), + include('interpol') + ] + return states + + +def gen_elixir_sigstr_rules(term, token, interpol=True): + if interpol: + return [ + (r'[^#%s\\]+' % (term,), token), + include('escapes'), + (r'\\.', token), + (r'%s[a-zA-Z]*' % (term,), token, '#pop'), + include('interpol') + ] + else: + return [ + (r'[^%s\\]+' % (term,), token), + (r'\\.', token), + (r'%s[a-zA-Z]*' % (term,), token, '#pop'), + ] + + +class ElixirLexer(RegexLexer): + """ + For the `Elixir language `_. + + .. versionadded:: 1.5 + """ + + name = 'Elixir' + aliases = ['elixir', 'ex', 'exs'] + filenames = ['*.ex', '*.exs'] + mimetypes = ['text/x-elixir'] + + KEYWORD = ('fn', 'do', 'end', 'after', 'else', 'rescue', 'catch') + KEYWORD_OPERATOR = ('not', 'and', 'or', 'when', 'in') + BUILTIN = ( + 'case', 'cond', 'for', 'if', 'unless', 'try', 'receive', 'raise', + 'quote', 'unquote', 'unquote_splicing', 'throw', 'super' + ) + BUILTIN_DECLARATION = ( + 'def', 'defp', 'defmodule', 'defprotocol', 'defmacro', 'defmacrop', + 'defdelegate', 'defexception', 'defstruct', 'defimpl', 'defcallback' + ) + + BUILTIN_NAMESPACE = ('import', 'require', 'use', 'alias') + CONSTANT = ('nil', 'true', 'false') + + PSEUDO_VAR = ('_', '__MODULE__', '__DIR__', '__ENV__', '__CALLER__') + + OPERATORS3 = ( + '<<<', '>>>', '|||', '&&&', '^^^', '~~~', '===', '!==', + '~>>', '<~>', '|~>', '<|>', + ) + OPERATORS2 = ( + '==', '!=', '<=', '>=', '&&', '||', '<>', '++', '--', '|>', '=~', + '->', '<-', '|', '.', '=', '~>', '<~', + ) + OPERATORS1 = ('<', '>', '+', '-', '*', '/', '!', '^', '&') + + PUNCTUATION = ( + '\\\\', '<<', '>>', '=>', '(', ')', ':', ';', ',', '[', ']' + ) + + def get_tokens_unprocessed(self, text): + for index, token, value in RegexLexer.get_tokens_unprocessed(self, text): + if token is Name: + if value in self.KEYWORD: + yield index, Keyword, value + elif value in self.KEYWORD_OPERATOR: + yield index, Operator.Word, value + elif value in self.BUILTIN: + yield index, Keyword, value + elif value in self.BUILTIN_DECLARATION: + yield index, Keyword.Declaration, value + elif value in self.BUILTIN_NAMESPACE: + yield index, Keyword.Namespace, value + elif value in self.CONSTANT: + yield index, Name.Constant, value + elif value in self.PSEUDO_VAR: + yield index, Name.Builtin.Pseudo, value + else: + yield index, token, value + else: + yield index, token, value + + def gen_elixir_sigil_rules(): + # all valid sigil terminators (excluding heredocs) + terminators = [ + (r'\{', r'\}', 'cb'), + (r'\[', r'\]', 'sb'), + (r'\(', r'\)', 'pa'), + (r'<', r'>', 'ab'), + (r'/', r'/', 'slas'), + (r'\|', r'\|', 'pipe'), + ('"', '"', 'quot'), + ("'", "'", 'apos'), + ] + + # heredocs have slightly different rules + triquotes = [(r'"""', 'triquot'), (r"'''", 'triapos')] + + token = String.Other + states = {'sigils': []} + + for term, name in triquotes: + states['sigils'] += [ + (r'(~[a-z])(%s)' % (term,), bygroups(token, String.Heredoc), + (name + '-end', name + '-intp')), + (r'(~[A-Z])(%s)' % (term,), bygroups(token, String.Heredoc), + (name + '-end', name + '-no-intp')), + ] + + states[name + '-end'] = [ + (r'[a-zA-Z]+', token, '#pop'), + default('#pop'), + ] + states[name + '-intp'] = [ + (r'^\s*' + term, String.Heredoc, '#pop'), + include('heredoc_interpol'), + ] + states[name + '-no-intp'] = [ + (r'^\s*' + term, String.Heredoc, '#pop'), + include('heredoc_no_interpol'), + ] + + for lterm, rterm, name in terminators: + states['sigils'] += [ + (r'~[a-z]' + lterm, token, name + '-intp'), + (r'~[A-Z]' + lterm, token, name + '-no-intp'), + ] + states[name + '-intp'] = gen_elixir_sigstr_rules(rterm, token) + states[name + '-no-intp'] = \ + gen_elixir_sigstr_rules(rterm, token, interpol=False) + + return states + + op3_re = "|".join(re.escape(s) for s in OPERATORS3) + op2_re = "|".join(re.escape(s) for s in OPERATORS2) + op1_re = "|".join(re.escape(s) for s in OPERATORS1) + ops_re = r'(?:%s|%s|%s)' % (op3_re, op2_re, op1_re) + punctuation_re = "|".join(re.escape(s) for s in PUNCTUATION) + alnum = '\w' + name_re = r'(?:\.\.\.|[a-z_]%s*[!?]?)' % alnum + modname_re = r'[A-Z]%(alnum)s*(?:\.[A-Z]%(alnum)s*)*' % {'alnum': alnum} + complex_name_re = r'(?:%s|%s|%s)' % (name_re, modname_re, ops_re) + special_atom_re = r'(?:\.\.\.|<<>>|%\{\}|%|\{\})' + + long_hex_char_re = r'(\\x\{)([\da-fA-F]+)(\})' + hex_char_re = r'(\\x[\da-fA-F]{1,2})' + escape_char_re = r'(\\[abdefnrstv])' + + tokens = { + 'root': [ + (r'\s+', Text), + (r'#.*$', Comment.Single), + + # Various kinds of characters + (r'(\?)' + long_hex_char_re, + bygroups(String.Char, + String.Escape, Number.Hex, String.Escape)), + (r'(\?)' + hex_char_re, + bygroups(String.Char, String.Escape)), + (r'(\?)' + escape_char_re, + bygroups(String.Char, String.Escape)), + (r'\?\\?.', String.Char), + + # '::' has to go before atoms + (r':::', String.Symbol), + (r'::', Operator), + + # atoms + (r':' + special_atom_re, String.Symbol), + (r':' + complex_name_re, String.Symbol), + (r':"', String.Symbol, 'string_double_atom'), + (r":'", String.Symbol, 'string_single_atom'), + + # [keywords: ...] + (r'(%s|%s)(:)(?=\s|\n)' % (special_atom_re, complex_name_re), + bygroups(String.Symbol, Punctuation)), + + # @attributes + (r'@' + name_re, Name.Attribute), + + # identifiers + (name_re, Name), + (r'(%%?)(%s)' % (modname_re,), bygroups(Punctuation, Name.Class)), + + # operators and punctuation + (op3_re, Operator), + (op2_re, Operator), + (punctuation_re, Punctuation), + (r'&\d', Name.Entity), # anon func arguments + (op1_re, Operator), + + # numbers + (r'0b[01]+', Number.Bin), + (r'0o[0-7]+', Number.Oct), + (r'0x[\da-fA-F]+', Number.Hex), + (r'\d(_?\d)*\.\d(_?\d)*([eE][-+]?\d(_?\d)*)?', Number.Float), + (r'\d(_?\d)*', Number.Integer), + + # strings and heredocs + (r'"""\s*', String.Heredoc, 'heredoc_double'), + (r"'''\s*$", String.Heredoc, 'heredoc_single'), + (r'"', String.Double, 'string_double'), + (r"'", String.Single, 'string_single'), + + include('sigils'), + + (r'%\{', Punctuation, 'map_key'), + (r'\{', Punctuation, 'tuple'), + ], + 'heredoc_double': [ + (r'^\s*"""', String.Heredoc, '#pop'), + include('heredoc_interpol'), + ], + 'heredoc_single': [ + (r"^\s*'''", String.Heredoc, '#pop'), + include('heredoc_interpol'), + ], + 'heredoc_interpol': [ + (r'[^#\\\n]+', String.Heredoc), + include('escapes'), + (r'\\.', String.Heredoc), + (r'\n+', String.Heredoc), + include('interpol'), + ], + 'heredoc_no_interpol': [ + (r'[^\\\n]+', String.Heredoc), + (r'\\.', String.Heredoc), + (r'\n+', String.Heredoc), + ], + 'escapes': [ + (long_hex_char_re, + bygroups(String.Escape, Number.Hex, String.Escape)), + (hex_char_re, String.Escape), + (escape_char_re, String.Escape), + ], + 'interpol': [ + (r'#\{', String.Interpol, 'interpol_string'), + ], + 'interpol_string': [ + (r'\}', String.Interpol, "#pop"), + include('root') + ], + 'map_key': [ + include('root'), + (r':', Punctuation, 'map_val'), + (r'=>', Punctuation, 'map_val'), + (r'\}', Punctuation, '#pop'), + ], + 'map_val': [ + include('root'), + (r',', Punctuation, '#pop'), + (r'(?=\})', Punctuation, '#pop'), + ], + 'tuple': [ + include('root'), + (r'\}', Punctuation, '#pop'), + ], + } + tokens.update(gen_elixir_string_rules('double', '"', String.Double)) + tokens.update(gen_elixir_string_rules('single', "'", String.Single)) + tokens.update(gen_elixir_string_rules('double_atom', '"', String.Symbol)) + tokens.update(gen_elixir_string_rules('single_atom', "'", String.Symbol)) + tokens.update(gen_elixir_sigil_rules()) + + +class ElixirConsoleLexer(Lexer): + """ + For Elixir interactive console (iex) output like: + + .. sourcecode:: iex + + iex> [head | tail] = [1,2,3] + [1,2,3] + iex> head + 1 + iex> tail + [2,3] + iex> [head | tail] + [1,2,3] + iex> length [head | tail] + 3 + + .. versionadded:: 1.5 + """ + + name = 'Elixir iex session' + aliases = ['iex'] + mimetypes = ['text/x-elixir-shellsession'] + + _prompt_re = re.compile('(iex|\.{3})(\(\d+\))?> ') + + def get_tokens_unprocessed(self, text): + exlexer = ElixirLexer(**self.options) + + curcode = '' + in_error = False + insertions = [] + for match in line_re.finditer(text): + line = match.group() + if line.startswith(u'** '): + in_error = True + insertions.append((len(curcode), + [(0, Generic.Error, line[:-1])])) + curcode += line[-1:] + else: + m = self._prompt_re.match(line) + if m is not None: + in_error = False + end = m.end() + insertions.append((len(curcode), + [(0, Generic.Prompt, line[:end])])) + curcode += line[end:] + else: + if curcode: + for item in do_insertions( + insertions, exlexer.get_tokens_unprocessed(curcode)): + yield item + curcode = '' + insertions = [] + token = Generic.Error if in_error else Generic.Output + yield match.start(), token, line + if curcode: + for item in do_insertions( + insertions, exlexer.get_tokens_unprocessed(curcode)): + yield item diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/esoteric.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/esoteric.py new file mode 100644 index 0000000000..7a026aed92 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/esoteric.py @@ -0,0 +1,114 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.esoteric + ~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for esoteric languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, include +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error + +__all__ = ['BrainfuckLexer', 'BefungeLexer', 'RedcodeLexer'] + + +class BrainfuckLexer(RegexLexer): + """ + Lexer for the esoteric `BrainFuck `_ + language. + """ + + name = 'Brainfuck' + aliases = ['brainfuck', 'bf'] + filenames = ['*.bf', '*.b'] + mimetypes = ['application/x-brainfuck'] + + tokens = { + 'common': [ + # use different colors for different instruction types + (r'[.,]+', Name.Tag), + (r'[+-]+', Name.Builtin), + (r'[<>]+', Name.Variable), + (r'[^.,+\-<>\[\]]+', Comment), + ], + 'root': [ + (r'\[', Keyword, 'loop'), + (r'\]', Error), + include('common'), + ], + 'loop': [ + (r'\[', Keyword, '#push'), + (r'\]', Keyword, '#pop'), + include('common'), + ] + } + + +class BefungeLexer(RegexLexer): + """ + Lexer for the esoteric `Befunge `_ + language. + + .. versionadded:: 0.7 + """ + name = 'Befunge' + aliases = ['befunge'] + filenames = ['*.befunge'] + mimetypes = ['application/x-befunge'] + + tokens = { + 'root': [ + (r'[0-9a-f]', Number), + (r'[+*/%!`-]', Operator), # Traditional math + (r'[<>^v?\[\]rxjk]', Name.Variable), # Move, imperatives + (r'[:\\$.,n]', Name.Builtin), # Stack ops, imperatives + (r'[|_mw]', Keyword), + (r'[{}]', Name.Tag), # Befunge-98 stack ops + (r'".*?"', String.Double), # Strings don't appear to allow escapes + (r'\'.', String.Single), # Single character + (r'[#;]', Comment), # Trampoline... depends on direction hit + (r'[pg&~=@iotsy]', Keyword), # Misc + (r'[()A-Z]', Comment), # Fingerprints + (r'\s+', Text), # Whitespace doesn't matter + ], + } + + +class RedcodeLexer(RegexLexer): + """ + A simple Redcode lexer based on ICWS'94. + Contributed by Adam Blinkinsop . + + .. versionadded:: 0.8 + """ + name = 'Redcode' + aliases = ['redcode'] + filenames = ['*.cw'] + + opcodes = ('DAT', 'MOV', 'ADD', 'SUB', 'MUL', 'DIV', 'MOD', + 'JMP', 'JMZ', 'JMN', 'DJN', 'CMP', 'SLT', 'SPL', + 'ORG', 'EQU', 'END') + modifiers = ('A', 'B', 'AB', 'BA', 'F', 'X', 'I') + + tokens = { + 'root': [ + # Whitespace: + (r'\s+', Text), + (r';.*$', Comment.Single), + # Lexemes: + # Identifiers + (r'\b(%s)\b' % '|'.join(opcodes), Name.Function), + (r'\b(%s)\b' % '|'.join(modifiers), Name.Decorator), + (r'[A-Za-z_]\w+', Name), + # Operators + (r'[-+*/%]', Operator), + (r'[#$@<>]', Operator), # mode + (r'[.,]', Punctuation), # mode + # Numbers + (r'[-+]?\d+', Number.Integer), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/factor.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/factor.py new file mode 100644 index 0000000000..402fc1291a --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/factor.py @@ -0,0 +1,344 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.factor + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for the Factor language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, bygroups, default, words +from pygments.token import Text, Comment, Keyword, Name, String, Number + +__all__ = ['FactorLexer'] + + +class FactorLexer(RegexLexer): + """ + Lexer for the `Factor `_ language. + + .. versionadded:: 1.4 + """ + name = 'Factor' + aliases = ['factor'] + filenames = ['*.factor'] + mimetypes = ['text/x-factor'] + + flags = re.MULTILINE | re.UNICODE + + builtin_kernel = words(( + '-rot', '2bi', '2bi@', '2bi*', '2curry', '2dip', '2drop', '2dup', '2keep', '2nip', + '2over', '2tri', '2tri@', '2tri*', '3bi', '3curry', '3dip', '3drop', '3dup', '3keep', + '3tri', '4dip', '4drop', '4dup', '4keep', '', '=', '>boolean', 'clone', + '?', '?execute', '?if', 'and', 'assert', 'assert=', 'assert?', 'bi', 'bi-curry', + 'bi-curry@', 'bi-curry*', 'bi@', 'bi*', 'boa', 'boolean', 'boolean?', 'both?', + 'build', 'call', 'callstack', 'callstack>array', 'callstack?', 'clear', '(clone)', + 'compose', 'compose?', 'curry', 'curry?', 'datastack', 'die', 'dip', 'do', 'drop', + 'dup', 'dupd', 'either?', 'eq?', 'equal?', 'execute', 'hashcode', 'hashcode*', + 'identity-hashcode', 'identity-tuple', 'identity-tuple?', 'if', 'if*', + 'keep', 'loop', 'most', 'new', 'nip', 'not', 'null', 'object', 'or', 'over', + 'pick', 'prepose', 'retainstack', 'rot', 'same?', 'swap', 'swapd', 'throw', + 'tri', 'tri-curry', 'tri-curry@', 'tri-curry*', 'tri@', 'tri*', 'tuple', + 'tuple?', 'unless', 'unless*', 'until', 'when', 'when*', 'while', 'with', + 'wrapper', 'wrapper?', 'xor'), suffix=r'\s') + + builtin_assocs = words(( + '2cache', '', '>alist', '?at', '?of', 'assoc', 'assoc-all?', + 'assoc-any?', 'assoc-clone-like', 'assoc-combine', 'assoc-diff', + 'assoc-diff!', 'assoc-differ', 'assoc-each', 'assoc-empty?', + 'assoc-filter', 'assoc-filter!', 'assoc-filter-as', 'assoc-find', + 'assoc-hashcode', 'assoc-intersect', 'assoc-like', 'assoc-map', + 'assoc-map-as', 'assoc-partition', 'assoc-refine', 'assoc-size', + 'assoc-stack', 'assoc-subset?', 'assoc-union', 'assoc-union!', + 'assoc=', 'assoc>map', 'assoc?', 'at', 'at+', 'at*', 'cache', 'change-at', + 'clear-assoc', 'delete-at', 'delete-at*', 'enum', 'enum?', 'extract-keys', + 'inc-at', 'key?', 'keys', 'map>assoc', 'maybe-set-at', 'new-assoc', 'of', + 'push-at', 'rename-at', 'set-at', 'sift-keys', 'sift-values', 'substitute', + 'unzip', 'value-at', 'value-at*', 'value?', 'values', 'zip'), suffix=r'\s') + + builtin_combinators = words(( + '2cleave', '2cleave>quot', '3cleave', '3cleave>quot', '4cleave', + '4cleave>quot', 'alist>quot', 'call-effect', 'case', 'case-find', + 'case>quot', 'cleave', 'cleave>quot', 'cond', 'cond>quot', 'deep-spread>quot', + 'execute-effect', 'linear-case-quot', 'no-case', 'no-case?', 'no-cond', + 'no-cond?', 'recursive-hashcode', 'shallow-spread>quot', 'spread', + 'to-fixed-point', 'wrong-values', 'wrong-values?'), suffix=r'\s') + + builtin_math = words(( + '-', '/', '/f', '/i', '/mod', '2/', '2^', '<', '<=', '', '>', + '>=', '>bignum', '>fixnum', '>float', '>integer', '(all-integers?)', + '(each-integer)', '(find-integer)', '*', '+', '?1+', + 'abs', 'align', 'all-integers?', 'bignum', 'bignum?', 'bit?', 'bitand', + 'bitnot', 'bitor', 'bits>double', 'bits>float', 'bitxor', 'complex', + 'complex?', 'denominator', 'double>bits', 'each-integer', 'even?', + 'find-integer', 'find-last-integer', 'fixnum', 'fixnum?', 'float', + 'float>bits', 'float?', 'fp-bitwise=', 'fp-infinity?', 'fp-nan-payload', + 'fp-nan?', 'fp-qnan?', 'fp-sign', 'fp-snan?', 'fp-special?', + 'if-zero', 'imaginary-part', 'integer', 'integer>fixnum', + 'integer>fixnum-strict', 'integer?', 'log2', 'log2-expects-positive', + 'log2-expects-positive?', 'mod', 'neg', 'neg?', 'next-float', + 'next-power-of-2', 'number', 'number=', 'number?', 'numerator', 'odd?', + 'out-of-fixnum-range', 'out-of-fixnum-range?', 'power-of-2?', + 'prev-float', 'ratio', 'ratio?', 'rational', 'rational?', 'real', + 'real-part', 'real?', 'recip', 'rem', 'sgn', 'shift', 'sq', 'times', + 'u<', 'u<=', 'u>', 'u>=', 'unless-zero', 'unordered?', 'when-zero', + 'zero?'), suffix=r'\s') + + builtin_sequences = words(( + '1sequence', '2all?', '2each', '2map', '2map-as', '2map-reduce', '2reduce', + '2selector', '2sequence', '3append', '3append-as', '3each', '3map', '3map-as', + '3sequence', '4sequence', '', '', '', '?first', + '?last', '?nth', '?second', '?set-nth', 'accumulate', 'accumulate!', + 'accumulate-as', 'all?', 'any?', 'append', 'append!', 'append-as', + 'assert-sequence', 'assert-sequence=', 'assert-sequence?', + 'binary-reduce', 'bounds-check', 'bounds-check?', 'bounds-error', + 'bounds-error?', 'but-last', 'but-last-slice', 'cartesian-each', + 'cartesian-map', 'cartesian-product', 'change-nth', 'check-slice', + 'check-slice-error', 'clone-like', 'collapse-slice', 'collector', + 'collector-for', 'concat', 'concat-as', 'copy', 'count', 'cut', 'cut-slice', + 'cut*', 'delete-all', 'delete-slice', 'drop-prefix', 'each', 'each-from', + 'each-index', 'empty?', 'exchange', 'filter', 'filter!', 'filter-as', 'find', + 'find-from', 'find-index', 'find-index-from', 'find-last', 'find-last-from', + 'first', 'first2', 'first3', 'first4', 'flip', 'follow', 'fourth', 'glue', 'halves', + 'harvest', 'head', 'head-slice', 'head-slice*', 'head*', 'head?', + 'if-empty', 'immutable', 'immutable-sequence', 'immutable-sequence?', + 'immutable?', 'index', 'index-from', 'indices', 'infimum', 'infimum-by', + 'insert-nth', 'interleave', 'iota', 'iota-tuple', 'iota-tuple?', 'join', + 'join-as', 'last', 'last-index', 'last-index-from', 'length', 'lengthen', + 'like', 'longer', 'longer?', 'longest', 'map', 'map!', 'map-as', 'map-find', + 'map-find-last', 'map-index', 'map-integers', 'map-reduce', 'map-sum', + 'max-length', 'member-eq?', 'member?', 'midpoint@', 'min-length', + 'mismatch', 'move', 'new-like', 'new-resizable', 'new-sequence', + 'non-negative-integer-expected', 'non-negative-integer-expected?', + 'nth', 'nths', 'pad-head', 'pad-tail', 'padding', 'partition', 'pop', 'pop*', + 'prefix', 'prepend', 'prepend-as', 'produce', 'produce-as', 'product', 'push', + 'push-all', 'push-either', 'push-if', 'reduce', 'reduce-index', 'remove', + 'remove!', 'remove-eq', 'remove-eq!', 'remove-nth', 'remove-nth!', 'repetition', + 'repetition?', 'replace-slice', 'replicate', 'replicate-as', 'rest', + 'rest-slice', 'reverse', 'reverse!', 'reversed', 'reversed?', 'second', + 'selector', 'selector-for', 'sequence', 'sequence-hashcode', 'sequence=', + 'sequence?', 'set-first', 'set-fourth', 'set-last', 'set-length', 'set-nth', + 'set-second', 'set-third', 'short', 'shorten', 'shorter', 'shorter?', + 'shortest', 'sift', 'slice', 'slice-error', 'slice-error?', 'slice?', + 'snip', 'snip-slice', 'start', 'start*', 'subseq', 'subseq?', 'suffix', + 'suffix!', 'sum', 'sum-lengths', 'supremum', 'supremum-by', 'surround', 'tail', + 'tail-slice', 'tail-slice*', 'tail*', 'tail?', 'third', 'trim', + 'trim-head', 'trim-head-slice', 'trim-slice', 'trim-tail', 'trim-tail-slice', + 'unclip', 'unclip-last', 'unclip-last-slice', 'unclip-slice', 'unless-empty', + 'virtual-exemplar', 'virtual-sequence', 'virtual-sequence?', 'virtual@', + 'when-empty'), suffix=r'\s') + + builtin_namespaces = words(( + '+@', 'change', 'change-global', 'counter', 'dec', 'get', 'get-global', + 'global', 'inc', 'init-namespaces', 'initialize', 'is-global', 'make-assoc', + 'namespace', 'namestack', 'off', 'on', 'set', 'set-global', 'set-namestack', + 'toggle', 'with-global', 'with-scope', 'with-variable', 'with-variables'), + suffix=r'\s') + + builtin_arrays = words(( + '1array', '2array', '3array', '4array', '', '>array', 'array', + 'array?', 'pair', 'pair?', 'resize-array'), suffix=r'\s') + + builtin_io = words(( + '(each-stream-block-slice)', '(each-stream-block)', + '(stream-contents-by-block)', '(stream-contents-by-element)', + '(stream-contents-by-length-or-block)', + '(stream-contents-by-length)', '+byte+', '+character+', + 'bad-seek-type', 'bad-seek-type?', 'bl', 'contents', 'each-block', + 'each-block-size', 'each-block-slice', 'each-line', 'each-morsel', + 'each-stream-block', 'each-stream-block-slice', 'each-stream-line', + 'error-stream', 'flush', 'input-stream', 'input-stream?', + 'invalid-read-buffer', 'invalid-read-buffer?', 'lines', 'nl', + 'output-stream', 'output-stream?', 'print', 'read', 'read-into', + 'read-partial', 'read-partial-into', 'read-until', 'read1', 'readln', + 'seek-absolute', 'seek-absolute?', 'seek-end', 'seek-end?', + 'seek-input', 'seek-output', 'seek-relative', 'seek-relative?', + 'stream-bl', 'stream-contents', 'stream-contents*', 'stream-copy', + 'stream-copy*', 'stream-element-type', 'stream-flush', + 'stream-length', 'stream-lines', 'stream-nl', 'stream-print', + 'stream-read', 'stream-read-into', 'stream-read-partial', + 'stream-read-partial-into', 'stream-read-partial-unsafe', + 'stream-read-unsafe', 'stream-read-until', 'stream-read1', + 'stream-readln', 'stream-seek', 'stream-seekable?', 'stream-tell', + 'stream-write', 'stream-write1', 'tell-input', 'tell-output', + 'with-error-stream', 'with-error-stream*', 'with-error>output', + 'with-input-output+error-streams', + 'with-input-output+error-streams*', 'with-input-stream', + 'with-input-stream*', 'with-output-stream', 'with-output-stream*', + 'with-output>error', 'with-output+error-stream', + 'with-output+error-stream*', 'with-streams', 'with-streams*', + 'write', 'write1'), suffix=r'\s') + + builtin_strings = words(( + '1string', '', '>string', 'resize-string', 'string', + 'string?'), suffix=r'\s') + + builtin_vectors = words(( + '1vector', '', '>vector', '?push', 'vector', 'vector?'), + suffix=r'\s') + + builtin_continuations = words(( + '', '', '', 'attempt-all', + 'attempt-all-error', 'attempt-all-error?', 'callback-error-hook', + 'callcc0', 'callcc1', 'cleanup', 'compute-restarts', 'condition', + 'condition?', 'continuation', 'continuation?', 'continue', + 'continue-restart', 'continue-with', 'current-continuation', + 'error', 'error-continuation', 'error-in-thread', 'error-thread', + 'ifcc', 'ignore-errors', 'in-callback?', 'original-error', 'recover', + 'restart', 'restart?', 'restarts', 'rethrow', 'rethrow-restarts', + 'return', 'return-continuation', 'thread-error-hook', 'throw-continue', + 'throw-restarts', 'with-datastack', 'with-return'), suffix=r'\s') + + tokens = { + 'root': [ + # factor allows a file to start with a shebang + (r'#!.*$', Comment.Preproc), + default('base'), + ], + 'base': [ + (r'\s+', Text), + + # defining words + (r'((?:MACRO|MEMO|TYPED)?:[:]?)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Function)), + (r'(M:[:]?)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Class, Text, Name.Function)), + (r'(C:)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Function, Text, Name.Class)), + (r'(GENERIC:)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Function)), + (r'(HOOK:|GENERIC#)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Function, Text, Name.Function)), + (r'\(\s', Name.Function, 'stackeffect'), + (r';\s', Keyword), + + # imports and namespaces + (r'(USING:)(\s+)', + bygroups(Keyword.Namespace, Text), 'vocabs'), + (r'(USE:|UNUSE:|IN:|QUALIFIED:)(\s+)(\S+)', + bygroups(Keyword.Namespace, Text, Name.Namespace)), + (r'(QUALIFIED-WITH:)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword.Namespace, Text, Name.Namespace, Text, Name.Namespace)), + (r'(FROM:|EXCLUDE:)(\s+)(\S+)(\s+=>\s)', + bygroups(Keyword.Namespace, Text, Name.Namespace, Text), 'words'), + (r'(RENAME:)(\s+)(\S+)(\s+)(\S+)(\s+=>\s+)(\S+)', + bygroups(Keyword.Namespace, Text, Name.Function, Text, Name.Namespace, Text, Name.Function)), + (r'(ALIAS:|TYPEDEF:)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword.Namespace, Text, Name.Function, Text, Name.Function)), + (r'(DEFER:|FORGET:|POSTPONE:)(\s+)(\S+)', + bygroups(Keyword.Namespace, Text, Name.Function)), + + # tuples and classes + (r'(TUPLE:|ERROR:)(\s+)(\S+)(\s+<\s+)(\S+)', + bygroups(Keyword, Text, Name.Class, Text, Name.Class), 'slots'), + (r'(TUPLE:|ERROR:|BUILTIN:)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Class), 'slots'), + (r'(MIXIN:|UNION:|INTERSECTION:)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Class)), + (r'(PREDICATE:)(\s+)(\S+)(\s+<\s+)(\S+)', + bygroups(Keyword, Text, Name.Class, Text, Name.Class)), + (r'(C:)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Function, Text, Name.Class)), + (r'(INSTANCE:)(\s+)(\S+)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Class, Text, Name.Class)), + (r'(SLOT:)(\s+)(\S+)', bygroups(Keyword, Text, Name.Function)), + (r'(SINGLETON:)(\s+)(\S+)', bygroups(Keyword, Text, Name.Class)), + (r'SINGLETONS:', Keyword, 'classes'), + + # other syntax + (r'(CONSTANT:|SYMBOL:|MAIN:|HELP:)(\s+)(\S+)', + bygroups(Keyword, Text, Name.Function)), + (r'SYMBOLS:\s', Keyword, 'words'), + (r'SYNTAX:\s', Keyword), + (r'ALIEN:\s', Keyword), + (r'(STRUCT:)(\s+)(\S+)', bygroups(Keyword, Text, Name.Class)), + (r'(FUNCTION:)(\s+\S+\s+)(\S+)(\s+\(\s+[^)]+\)\s)', + bygroups(Keyword.Namespace, Text, Name.Function, Text)), + (r'(FUNCTION-ALIAS:)(\s+)(\S+)(\s+\S+\s+)(\S+)(\s+\(\s+[^)]+\)\s)', + bygroups(Keyword.Namespace, Text, Name.Function, Text, Name.Function, Text)), + + # vocab.private + (r'(?:)\s', Keyword.Namespace), + + # strings + (r'"""\s+(?:.|\n)*?\s+"""', String), + (r'"(?:\\\\|\\"|[^"])*"', String), + (r'\S+"\s+(?:\\\\|\\"|[^"])*"', String), + (r'CHAR:\s+(?:\\[\\abfnrstv]|[^\\]\S*)\s', String.Char), + + # comments + (r'!\s+.*$', Comment), + (r'#!\s+.*$', Comment), + (r'/\*\s+(?:.|\n)*?\s\*/\s', Comment), + + # boolean constants + (r'[tf]\s', Name.Constant), + + # symbols and literals + (r'[\\$]\s+\S+', Name.Constant), + (r'M\\\s+\S+\s+\S+', Name.Constant), + + # numbers + (r'[+-]?(?:[\d,]*\d)?\.(?:\d([\d,]*\d)?)?(?:[eE][+-]?\d+)?\s', Number), + (r'[+-]?\d(?:[\d,]*\d)?(?:[eE][+-]?\d+)?\s', Number), + (r'0x[a-fA-F\d](?:[a-fA-F\d,]*[a-fA-F\d])?(?:p\d([\d,]*\d)?)?\s', Number), + (r'NAN:\s+[a-fA-F\d](?:[a-fA-F\d,]*[a-fA-F\d])?(?:p\d([\d,]*\d)?)?\s', Number), + (r'0b[01]+\s', Number.Bin), + (r'0o[0-7]+\s', Number.Oct), + (r'(?:\d([\d,]*\d)?)?\+\d(?:[\d,]*\d)?/\d(?:[\d,]*\d)?\s', Number), + (r'(?:\-\d([\d,]*\d)?)?\-\d(?:[\d,]*\d)?/\d(?:[\d,]*\d)?\s', Number), + + # keywords + (r'(?:deprecated|final|foldable|flushable|inline|recursive)\s', + Keyword), + + # builtins + (builtin_kernel, Name.Builtin), + (builtin_assocs, Name.Builtin), + (builtin_combinators, Name.Builtin), + (builtin_math, Name.Builtin), + (builtin_sequences, Name.Builtin), + (builtin_namespaces, Name.Builtin), + (builtin_arrays, Name.Builtin), + (builtin_io, Name.Builtin), + (builtin_strings, Name.Builtin), + (builtin_vectors, Name.Builtin), + (builtin_continuations, Name.Builtin), + + # everything else is text + (r'\S+', Text), + ], + 'stackeffect': [ + (r'\s+', Text), + (r'\(\s+', Name.Function, 'stackeffect'), + (r'\)\s', Name.Function, '#pop'), + (r'--\s', Name.Function), + (r'\S+', Name.Variable), + ], + 'slots': [ + (r'\s+', Text), + (r';\s', Keyword, '#pop'), + (r'(\{\s+)(\S+)(\s+[^}]+\s+\}\s)', + bygroups(Text, Name.Variable, Text)), + (r'\S+', Name.Variable), + ], + 'vocabs': [ + (r'\s+', Text), + (r';\s', Keyword, '#pop'), + (r'\S+', Name.Namespace), + ], + 'classes': [ + (r'\s+', Text), + (r';\s', Keyword, '#pop'), + (r'\S+', Name.Class), + ], + 'words': [ + (r'\s+', Text), + (r';\s', Keyword, '#pop'), + (r'\S+', Name.Function), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fantom.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fantom.py new file mode 100644 index 0000000000..953b324ca3 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fantom.py @@ -0,0 +1,250 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.fantom + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexer for the Fantom language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from string import Template + +from pygments.lexer import RegexLexer, include, bygroups, using, \ + this, default, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Literal + +__all__ = ['FantomLexer'] + + +class FantomLexer(RegexLexer): + """ + For Fantom source code. + + .. versionadded:: 1.5 + """ + name = 'Fantom' + aliases = ['fan'] + filenames = ['*.fan'] + mimetypes = ['application/x-fantom'] + + # often used regexes + def s(str): + return Template(str).substitute( + dict( + pod=r'[\"\w\.]+', + eos=r'\n|;', + id=r'[a-zA-Z_]\w*', + # all chars which can be part of type definition. Starts with + # either letter, or [ (maps), or | (funcs) + type=r'(?:\[|[a-zA-Z_]|\|)[:\w\[\]|\->?]*?', + ) + ) + + tokens = { + 'comments': [ + (r'(?s)/\*.*?\*/', Comment.Multiline), # Multiline + (r'//.*?\n', Comment.Single), # Single line + # TODO: highlight references in fandocs + (r'\*\*.*?\n', Comment.Special), # Fandoc + (r'#.*\n', Comment.Single) # Shell-style + ], + 'literals': [ + (r'\b-?[\d_]+(ns|ms|sec|min|hr|day)', Number), # Duration + (r'\b-?[\d_]*\.[\d_]+(ns|ms|sec|min|hr|day)', Number), # Duration with dot + (r'\b-?(\d+)?\.\d+(f|F|d|D)?', Number.Float), # Float/Decimal + (r'\b-?0x[0-9a-fA-F_]+', Number.Hex), # Hex + (r'\b-?[\d_]+', Number.Integer), # Int + (r"'\\.'|'[^\\]'|'\\u[0-9a-f]{4}'", String.Char), # Char + (r'"', Punctuation, 'insideStr'), # Opening quote + (r'`', Punctuation, 'insideUri'), # Opening accent + (r'\b(true|false|null)\b', Keyword.Constant), # Bool & null + (r'(?:(\w+)(::))?(\w+)(<\|)(.*?)(\|>)', # DSL + bygroups(Name.Namespace, Punctuation, Name.Class, + Punctuation, String, Punctuation)), + (r'(?:(\w+)(::))?(\w+)?(#)(\w+)?', # Type/slot literal + bygroups(Name.Namespace, Punctuation, Name.Class, + Punctuation, Name.Function)), + (r'\[,\]', Literal), # Empty list + (s(r'($type)(\[,\])'), # Typed empty list + bygroups(using(this, state='inType'), Literal)), + (r'\[:\]', Literal), # Empty Map + (s(r'($type)(\[:\])'), + bygroups(using(this, state='inType'), Literal)), + ], + 'insideStr': [ + (r'\\\\', String.Escape), # Escaped backslash + (r'\\"', String.Escape), # Escaped " + (r'\\`', String.Escape), # Escaped ` + (r'\$\w+', String.Interpol), # Subst var + (r'\$\{.*?\}', String.Interpol), # Subst expr + (r'"', Punctuation, '#pop'), # Closing quot + (r'.', String) # String content + ], + 'insideUri': [ # TODO: remove copy/paste str/uri + (r'\\\\', String.Escape), # Escaped backslash + (r'\\"', String.Escape), # Escaped " + (r'\\`', String.Escape), # Escaped ` + (r'\$\w+', String.Interpol), # Subst var + (r'\$\{.*?\}', String.Interpol), # Subst expr + (r'`', Punctuation, '#pop'), # Closing tick + (r'.', String.Backtick) # URI content + ], + 'protectionKeywords': [ + (r'\b(public|protected|private|internal)\b', Keyword), + ], + 'typeKeywords': [ + (r'\b(abstract|final|const|native|facet|enum)\b', Keyword), + ], + 'methodKeywords': [ + (r'\b(abstract|native|once|override|static|virtual|final)\b', + Keyword), + ], + 'fieldKeywords': [ + (r'\b(abstract|const|final|native|override|static|virtual|' + r'readonly)\b', Keyword) + ], + 'otherKeywords': [ + (words(( + 'try', 'catch', 'throw', 'finally', 'for', 'if', 'else', 'while', + 'as', 'is', 'isnot', 'switch', 'case', 'default', 'continue', + 'break', 'do', 'return', 'get', 'set'), prefix=r'\b', suffix=r'\b'), + Keyword), + (r'\b(it|this|super)\b', Name.Builtin.Pseudo), + ], + 'operators': [ + (r'\+\+|\-\-|\+|\-|\*|/|\|\||&&|<=>|<=|<|>=|>|=|!|\[|\]', Operator) + ], + 'inType': [ + (r'[\[\]|\->:?]', Punctuation), + (s(r'$id'), Name.Class), + default('#pop'), + + ], + 'root': [ + include('comments'), + include('protectionKeywords'), + include('typeKeywords'), + include('methodKeywords'), + include('fieldKeywords'), + include('literals'), + include('otherKeywords'), + include('operators'), + (r'using\b', Keyword.Namespace, 'using'), # Using stmt + (r'@\w+', Name.Decorator, 'facet'), # Symbol + (r'(class|mixin)(\s+)(\w+)', bygroups(Keyword, Text, Name.Class), + 'inheritance'), # Inheritance list + + # Type var := val + (s(r'($type)([ \t]+)($id)(\s*)(:=)'), + bygroups(using(this, state='inType'), Text, + Name.Variable, Text, Operator)), + + # var := val + (s(r'($id)(\s*)(:=)'), + bygroups(Name.Variable, Text, Operator)), + + # .someId( or ->someId( ### + (s(r'(\.|(?:\->))($id)(\s*)(\()'), + bygroups(Operator, Name.Function, Text, Punctuation), + 'insideParen'), + + # .someId or ->someId + (s(r'(\.|(?:\->))($id)'), + bygroups(Operator, Name.Function)), + + # new makeXXX ( + (r'(new)(\s+)(make\w*)(\s*)(\()', + bygroups(Keyword, Text, Name.Function, Text, Punctuation), + 'insideMethodDeclArgs'), + + # Type name ( + (s(r'($type)([ \t]+)' # Return type and whitespace + r'($id)(\s*)(\()'), # method name + open brace + bygroups(using(this, state='inType'), Text, + Name.Function, Text, Punctuation), + 'insideMethodDeclArgs'), + + # ArgType argName, + (s(r'($type)(\s+)($id)(\s*)(,)'), + bygroups(using(this, state='inType'), Text, Name.Variable, + Text, Punctuation)), + + # ArgType argName) + # Covered in 'insideParen' state + + # ArgType argName -> ArgType| + (s(r'($type)(\s+)($id)(\s*)(\->)(\s*)($type)(\|)'), + bygroups(using(this, state='inType'), Text, Name.Variable, + Text, Punctuation, Text, using(this, state='inType'), + Punctuation)), + + # ArgType argName| + (s(r'($type)(\s+)($id)(\s*)(\|)'), + bygroups(using(this, state='inType'), Text, Name.Variable, + Text, Punctuation)), + + # Type var + (s(r'($type)([ \t]+)($id)'), + bygroups(using(this, state='inType'), Text, + Name.Variable)), + + (r'\(', Punctuation, 'insideParen'), + (r'\{', Punctuation, 'insideBrace'), + (r'.', Text) + ], + 'insideParen': [ + (r'\)', Punctuation, '#pop'), + include('root'), + ], + 'insideMethodDeclArgs': [ + (r'\)', Punctuation, '#pop'), + (s(r'($type)(\s+)($id)(\s*)(\))'), + bygroups(using(this, state='inType'), Text, Name.Variable, + Text, Punctuation), '#pop'), + include('root'), + ], + 'insideBrace': [ + (r'\}', Punctuation, '#pop'), + include('root'), + ], + 'inheritance': [ + (r'\s+', Text), # Whitespace + (r':|,', Punctuation), + (r'(?:(\w+)(::))?(\w+)', + bygroups(Name.Namespace, Punctuation, Name.Class)), + (r'\{', Punctuation, '#pop') + ], + 'using': [ + (r'[ \t]+', Text), # consume whitespaces + (r'(\[)(\w+)(\])', + bygroups(Punctuation, Comment.Special, Punctuation)), # ffi + (r'(\")?([\w.]+)(\")?', + bygroups(Punctuation, Name.Namespace, Punctuation)), # podname + (r'::', Punctuation, 'usingClass'), + default('#pop') + ], + 'usingClass': [ + (r'[ \t]+', Text), # consume whitespaces + (r'(as)(\s+)(\w+)', + bygroups(Keyword.Declaration, Text, Name.Class), '#pop:2'), + (r'[\w$]+', Name.Class), + default('#pop:2') # jump out to root state + ], + 'facet': [ + (r'\s+', Text), + (r'\{', Punctuation, 'facetFields'), + default('#pop') + ], + 'facetFields': [ + include('comments'), + include('literals'), + include('operators'), + (r'\s+', Text), + (r'(\s*)(\w+)(\s*)(=)', bygroups(Text, Name, Text, Operator)), + (r'\}', Punctuation, '#pop'), + (r'.', Text) + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/felix.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/felix.py new file mode 100644 index 0000000000..ca8df5728b --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/felix.py @@ -0,0 +1,273 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.felix + ~~~~~~~~~~~~~~~~~~~~~ + + Lexer for the Felix language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, include, bygroups, default, words, \ + combined +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['FelixLexer'] + + +class FelixLexer(RegexLexer): + """ + For `Felix `_ source code. + + .. versionadded:: 1.2 + """ + + name = 'Felix' + aliases = ['felix', 'flx'] + filenames = ['*.flx', '*.flxh'] + mimetypes = ['text/x-felix'] + + preproc = ( + 'elif', 'else', 'endif', 'if', 'ifdef', 'ifndef', + ) + + keywords = ( + '_', '_deref', 'all', 'as', + 'assert', 'attempt', 'call', 'callback', 'case', 'caseno', 'cclass', + 'code', 'compound', 'ctypes', 'do', 'done', 'downto', 'elif', 'else', + 'endattempt', 'endcase', 'endif', 'endmatch', 'enum', 'except', + 'exceptions', 'expect', 'finally', 'for', 'forall', 'forget', 'fork', + 'functor', 'goto', 'ident', 'if', 'incomplete', 'inherit', 'instance', + 'interface', 'jump', 'lambda', 'loop', 'match', 'module', 'namespace', + 'new', 'noexpand', 'nonterm', 'obj', 'of', 'open', 'parse', 'raise', + 'regexp', 'reglex', 'regmatch', 'rename', 'return', 'the', 'then', + 'to', 'type', 'typecase', 'typedef', 'typematch', 'typeof', 'upto', + 'when', 'whilst', 'with', 'yield', + ) + + keyword_directives = ( + '_gc_pointer', '_gc_type', 'body', 'comment', 'const', 'export', + 'header', 'inline', 'lval', 'macro', 'noinline', 'noreturn', + 'package', 'private', 'pod', 'property', 'public', 'publish', + 'requires', 'todo', 'virtual', 'use', + ) + + keyword_declarations = ( + 'def', 'let', 'ref', 'val', 'var', + ) + + keyword_types = ( + 'unit', 'void', 'any', 'bool', + 'byte', 'offset', + 'address', 'caddress', 'cvaddress', 'vaddress', + 'tiny', 'short', 'int', 'long', 'vlong', + 'utiny', 'ushort', 'vshort', 'uint', 'ulong', 'uvlong', + 'int8', 'int16', 'int32', 'int64', + 'uint8', 'uint16', 'uint32', 'uint64', + 'float', 'double', 'ldouble', + 'complex', 'dcomplex', 'lcomplex', + 'imaginary', 'dimaginary', 'limaginary', + 'char', 'wchar', 'uchar', + 'charp', 'charcp', 'ucharp', 'ucharcp', + 'string', 'wstring', 'ustring', + 'cont', + 'array', 'varray', 'list', + 'lvalue', 'opt', 'slice', + ) + + keyword_constants = ( + 'false', 'true', + ) + + operator_words = ( + 'and', 'not', 'in', 'is', 'isin', 'or', 'xor', + ) + + name_builtins = ( + '_svc', 'while', + ) + + name_pseudo = ( + 'root', 'self', 'this', + ) + + decimal_suffixes = '([tTsSiIlLvV]|ll|LL|([iIuU])(8|16|32|64))?' + + tokens = { + 'root': [ + include('whitespace'), + + # Keywords + (words(('axiom', 'ctor', 'fun', 'gen', 'proc', 'reduce', + 'union'), suffix=r'\b'), + Keyword, 'funcname'), + (words(('class', 'cclass', 'cstruct', 'obj', 'struct'), suffix=r'\b'), + Keyword, 'classname'), + (r'(instance|module|typeclass)\b', Keyword, 'modulename'), + + (words(keywords, suffix=r'\b'), Keyword), + (words(keyword_directives, suffix=r'\b'), Name.Decorator), + (words(keyword_declarations, suffix=r'\b'), Keyword.Declaration), + (words(keyword_types, suffix=r'\b'), Keyword.Type), + (words(keyword_constants, suffix=r'\b'), Keyword.Constant), + + # Operators + include('operators'), + + # Float Literal + # -- Hex Float + (r'0[xX]([0-9a-fA-F_]*\.[0-9a-fA-F_]+|[0-9a-fA-F_]+)' + r'[pP][+\-]?[0-9_]+[lLfFdD]?', Number.Float), + # -- DecimalFloat + (r'[0-9_]+(\.[0-9_]+[eE][+\-]?[0-9_]+|' + r'\.[0-9_]*|[eE][+\-]?[0-9_]+)[lLfFdD]?', Number.Float), + (r'\.(0|[1-9][0-9_]*)([eE][+\-]?[0-9_]+)?[lLfFdD]?', + Number.Float), + + # IntegerLiteral + # -- Binary + (r'0[Bb][01_]+%s' % decimal_suffixes, Number.Bin), + # -- Octal + (r'0[0-7_]+%s' % decimal_suffixes, Number.Oct), + # -- Hexadecimal + (r'0[xX][0-9a-fA-F_]+%s' % decimal_suffixes, Number.Hex), + # -- Decimal + (r'(0|[1-9][0-9_]*)%s' % decimal_suffixes, Number.Integer), + + # Strings + ('([rR][cC]?|[cC][rR])"""', String, 'tdqs'), + ("([rR][cC]?|[cC][rR])'''", String, 'tsqs'), + ('([rR][cC]?|[cC][rR])"', String, 'dqs'), + ("([rR][cC]?|[cC][rR])'", String, 'sqs'), + ('[cCfFqQwWuU]?"""', String, combined('stringescape', 'tdqs')), + ("[cCfFqQwWuU]?'''", String, combined('stringescape', 'tsqs')), + ('[cCfFqQwWuU]?"', String, combined('stringescape', 'dqs')), + ("[cCfFqQwWuU]?'", String, combined('stringescape', 'sqs')), + + # Punctuation + (r'[\[\]{}:(),;?]', Punctuation), + + # Labels + (r'[a-zA-Z_]\w*:>', Name.Label), + + # Identifiers + (r'(%s)\b' % '|'.join(name_builtins), Name.Builtin), + (r'(%s)\b' % '|'.join(name_pseudo), Name.Builtin.Pseudo), + (r'[a-zA-Z_]\w*', Name), + ], + 'whitespace': [ + (r'\n', Text), + (r'\s+', Text), + + include('comment'), + + # Preprocessor + (r'#\s*if\s+0', Comment.Preproc, 'if0'), + (r'#', Comment.Preproc, 'macro'), + ], + 'operators': [ + (r'(%s)\b' % '|'.join(operator_words), Operator.Word), + (r'!=|==|<<|>>|\|\||&&|[-~+/*%=<>&^|.$]', Operator), + ], + 'comment': [ + (r'//(.*?)\n', Comment.Single), + (r'/[*]', Comment.Multiline, 'comment2'), + ], + 'comment2': [ + (r'[^/*]', Comment.Multiline), + (r'/[*]', Comment.Multiline, '#push'), + (r'[*]/', Comment.Multiline, '#pop'), + (r'[/*]', Comment.Multiline), + ], + 'if0': [ + (r'^\s*#if.*?(?]*?>)', + bygroups(Comment.Preproc, Text, String), '#pop'), + (r'(import|include)(\s+)("[^"]*?")', + bygroups(Comment.Preproc, Text, String), '#pop'), + (r"(import|include)(\s+)('[^']*?')", + bygroups(Comment.Preproc, Text, String), '#pop'), + (r'[^/\n]+', Comment.Preproc), + # (r'/[*](.|\n)*?[*]/', Comment), + # (r'//.*?\n', Comment, '#pop'), + (r'/', Comment.Preproc), + (r'(?<=\\)\n', Comment.Preproc), + (r'\n', Comment.Preproc, '#pop'), + ], + 'funcname': [ + include('whitespace'), + (r'[a-zA-Z_]\w*', Name.Function, '#pop'), + # anonymous functions + (r'(?=\()', Text, '#pop'), + ], + 'classname': [ + include('whitespace'), + (r'[a-zA-Z_]\w*', Name.Class, '#pop'), + # anonymous classes + (r'(?=\{)', Text, '#pop'), + ], + 'modulename': [ + include('whitespace'), + (r'\[', Punctuation, ('modulename2', 'tvarlist')), + default('modulename2'), + ], + 'modulename2': [ + include('whitespace'), + (r'([a-zA-Z_]\w*)', Name.Namespace, '#pop:2'), + ], + 'tvarlist': [ + include('whitespace'), + include('operators'), + (r'\[', Punctuation, '#push'), + (r'\]', Punctuation, '#pop'), + (r',', Punctuation), + (r'(with|where)\b', Keyword), + (r'[a-zA-Z_]\w*', Name), + ], + 'stringescape': [ + (r'\\([\\abfnrtv"\']|\n|N\{.*?\}|u[a-fA-F0-9]{4}|' + r'U[a-fA-F0-9]{8}|x[a-fA-F0-9]{2}|[0-7]{1,3})', String.Escape) + ], + 'strings': [ + (r'%(\([a-zA-Z0-9]+\))?[-#0 +]*([0-9]+|[*])?(\.([0-9]+|[*]))?' + '[hlL]?[diouxXeEfFgGcrs%]', String.Interpol), + (r'[^\\\'"%\n]+', String), + # quotes, percents and backslashes must be parsed one at a time + (r'[\'"\\]', String), + # unhandled string formatting sign + (r'%', String) + # newlines are an error (use "nl" state) + ], + 'nl': [ + (r'\n', String) + ], + 'dqs': [ + (r'"', String, '#pop'), + # included here again for raw strings + (r'\\\\|\\"|\\\n', String.Escape), + include('strings') + ], + 'sqs': [ + (r"'", String, '#pop'), + # included here again for raw strings + (r"\\\\|\\'|\\\n", String.Escape), + include('strings') + ], + 'tdqs': [ + (r'"""', String, '#pop'), + include('strings'), + include('nl') + ], + 'tsqs': [ + (r"'''", String, '#pop'), + include('strings'), + include('nl') + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fortran.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fortran.py new file mode 100644 index 0000000000..3ef6ff459b --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/fortran.py @@ -0,0 +1,161 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.fortran + ~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Fortran languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['FortranLexer'] + + +class FortranLexer(RegexLexer): + """ + Lexer for FORTRAN 90 code. + + .. versionadded:: 0.10 + """ + name = 'Fortran' + aliases = ['fortran'] + filenames = ['*.f', '*.f90', '*.F', '*.F90'] + mimetypes = ['text/x-fortran'] + flags = re.IGNORECASE | re.MULTILINE + + # Data Types: INTEGER, REAL, COMPLEX, LOGICAL, CHARACTER and DOUBLE PRECISION + # Operators: **, *, +, -, /, <, >, <=, >=, ==, /= + # Logical (?): NOT, AND, OR, EQV, NEQV + + # Builtins: + # http://gcc.gnu.org/onlinedocs/gcc-3.4.6/g77/Table-of-Intrinsic-Functions.html + + tokens = { + 'root': [ + (r'^#.*\n', Comment.Preproc), + (r'!.*\n', Comment), + include('strings'), + include('core'), + (r'[a-z][\w$]*', Name), + include('nums'), + (r'[\s]+', Text), + ], + 'core': [ + # Statements + (words(( + 'ABSTRACT', 'ACCEPT', 'ALL', 'ALLSTOP', 'ALLOCATABLE', 'ALLOCATE', + 'ARRAY', 'ASSIGN', 'ASSOCIATE', 'ASYNCHRONOUS', 'BACKSPACE', 'BIND', + 'BLOCK', 'BLOCKDATA', 'BYTE', 'CALL', 'CASE', 'CLASS', 'CLOSE', + 'CODIMENSION', 'COMMON', 'CONCURRRENT', 'CONTIGUOUS', 'CONTAINS', + 'CONTINUE', 'CRITICAL', 'CYCLE', 'DATA', 'DEALLOCATE', 'DECODE', + 'DEFERRED', 'DIMENSION', 'DO', 'ELEMENTAL', 'ELSE', 'ENCODE', 'END', + 'ENTRY', 'ENUM', 'ENUMERATOR', 'EQUIVALENCE', 'EXIT', 'EXTENDS', + 'EXTERNAL', 'EXTRINSIC', 'FILE', 'FINAL', 'FORALL', 'FORMAT', + 'FUNCTION', 'GENERIC', 'GOTO', 'IF', 'IMAGES', 'IMPLICIT', + 'IMPORT', 'IMPURE', 'INCLUDE', 'INQUIRE', 'INTENT', 'INTERFACE', + 'INTRINSIC', 'IS', 'LOCK', 'MEMORY', 'MODULE', 'NAMELIST', 'NULLIFY', + 'NONE', 'NON_INTRINSIC', 'NON_OVERRIDABLE', 'NOPASS', 'OPEN', 'OPTIONAL', + 'OPTIONS', 'PARAMETER', 'PASS', 'PAUSE', 'POINTER', 'PRINT', 'PRIVATE', + 'PROGRAM', 'PROCEDURE', 'PROTECTED', 'PUBLIC', 'PURE', 'READ', + 'RECURSIVE', 'RESULT', 'RETURN', 'REWIND', 'SAVE', 'SELECT', 'SEQUENCE', + 'STOP', 'SUBMODULE', 'SUBROUTINE', 'SYNC', 'SYNCALL', 'SYNCIMAGES', + 'SYNCMEMORY', 'TARGET', 'THEN', 'TYPE', 'UNLOCK', 'USE', 'VALUE', + 'VOLATILE', 'WHERE', 'WRITE', 'WHILE'), prefix=r'\b', suffix=r'\s*\b'), + Keyword), + + # Data Types + (words(( + 'CHARACTER', 'COMPLEX', 'DOUBLE PRECISION', 'DOUBLE COMPLEX', 'INTEGER', + 'LOGICAL', 'REAL', 'C_INT', 'C_SHORT', 'C_LONG', 'C_LONG_LONG', 'C_SIGNED_CHAR', + 'C_SIZE_T', 'C_INT8_T', 'C_INT16_T', 'C_INT32_T', 'C_INT64_T', 'C_INT_LEAST8_T', + 'C_INT_LEAST16_T', 'C_INT_LEAST32_T', 'C_INT_LEAST64_T', 'C_INT_FAST8_T', + 'C_INT_FAST16_T', 'C_INT_FAST32_T', 'C_INT_FAST64_T', 'C_INTMAX_T', + 'C_INTPTR_T', 'C_FLOAT', 'C_DOUBLE', 'C_LONG_DOUBLE', 'C_FLOAT_COMPLEX', + 'C_DOUBLE_COMPLEX', 'C_LONG_DOUBLE_COMPLEX', 'C_BOOL', 'C_CHAR', 'C_PTR', + 'C_FUNPTR'), prefix=r'\b', suffix=r'\s*\b'), + Keyword.Type), + + # Operators + (r'(\*\*|\*|\+|-|\/|<|>|<=|>=|==|\/=|=)', Operator), + + (r'(::)', Keyword.Declaration), + + (r'[()\[\],:&%;.]', Punctuation), + # Intrinsics + (words(( + 'Abort', 'Abs', 'Access', 'AChar', 'ACos', 'ACosH', 'AdjustL', + 'AdjustR', 'AImag', 'AInt', 'Alarm', 'All', 'Allocated', 'ALog', + 'AMax', 'AMin', 'AMod', 'And', 'ANInt', 'Any', 'ASin', 'ASinH', + 'Associated', 'ATan', 'ATanH', 'Atomic_Define', 'Atomic_Ref', + 'BesJ', 'BesJN', 'Bessel_J0', 'Bessel_J1', 'Bessel_JN', 'Bessel_Y0', + 'Bessel_Y1', 'Bessel_YN', 'BesY', 'BesYN', 'BGE', 'BGT', 'BLE', + 'BLT', 'Bit_Size', 'BTest', 'CAbs', 'CCos', 'Ceiling', 'CExp', + 'Char', 'ChDir', 'ChMod', 'CLog', 'Cmplx', 'Command_Argument_Count', + 'Complex', 'Conjg', 'Cos', 'CosH', 'Count', 'CPU_Time', 'CShift', + 'CSin', 'CSqRt', 'CTime', 'C_Loc', 'C_Associated', + 'C_Null_Ptr', 'C_Null_Funptr', 'C_F_Pointer', 'C_F_ProcPointer', + 'C_Null_Char', 'C_Alert', 'C_Backspace', 'C_Form_Feed', 'C_FunLoc', + 'C_Sizeof', 'C_New_Line', 'C_Carriage_Return', + 'C_Horizontal_Tab', 'C_Vertical_Tab', 'DAbs', 'DACos', 'DASin', + 'DATan', 'Date_and_Time', 'DbesJ', 'DbesJN', 'DbesY', + 'DbesYN', 'Dble', 'DCos', 'DCosH', 'DDiM', 'DErF', + 'DErFC', 'DExp', 'Digits', 'DiM', 'DInt', 'DLog', 'DMax', + 'DMin', 'DMod', 'DNInt', 'Dot_Product', 'DProd', 'DSign', 'DSinH', + 'DShiftL', 'DShiftR', 'DSin', 'DSqRt', 'DTanH', 'DTan', 'DTime', + 'EOShift', 'Epsilon', 'ErF', 'ErFC', 'ErFC_Scaled', 'ETime', + 'Execute_Command_Line', 'Exit', 'Exp', 'Exponent', 'Extends_Type_Of', + 'FDate', 'FGet', 'FGetC', 'FindLoc', 'Float', 'Floor', 'Flush', + 'FNum', 'FPutC', 'FPut', 'Fraction', 'FSeek', 'FStat', 'FTell', + 'Gamma', 'GError', 'GetArg', 'Get_Command', 'Get_Command_Argument', + 'Get_Environment_Variable', 'GetCWD', 'GetEnv', 'GetGId', 'GetLog', + 'GetPId', 'GetUId', 'GMTime', 'HostNm', 'Huge', 'Hypot', 'IAbs', + 'IAChar', 'IAll', 'IAnd', 'IAny', 'IArgC', 'IBClr', 'IBits', + 'IBSet', 'IChar', 'IDate', 'IDiM', 'IDInt', 'IDNInt', 'IEOr', + 'IErrNo', 'IFix', 'Imag', 'ImagPart', 'Image_Index', 'Index', + 'Int', 'IOr', 'IParity', 'IRand', 'IsaTty', 'IShft', 'IShftC', + 'ISign', 'Iso_C_Binding', 'Is_Contiguous', 'Is_Iostat_End', + 'Is_Iostat_Eor', 'ITime', 'Kill', 'Kind', 'LBound', 'LCoBound', + 'Len', 'Len_Trim', 'LGe', 'LGt', 'Link', 'LLe', 'LLt', 'LnBlnk', + 'Loc', 'Log', 'Log_Gamma', 'Logical', 'Long', 'LShift', 'LStat', + 'LTime', 'MaskL', 'MaskR', 'MatMul', 'Max', 'MaxExponent', + 'MaxLoc', 'MaxVal', 'MClock', 'Merge', 'Merge_Bits', 'Move_Alloc', + 'Min', 'MinExponent', 'MinLoc', 'MinVal', 'Mod', 'Modulo', 'MvBits', + 'Nearest', 'New_Line', 'NInt', 'Norm2', 'Not', 'Null', 'Num_Images', + 'Or', 'Pack', 'Parity', 'PError', 'Precision', 'Present', 'Product', + 'Radix', 'Rand', 'Random_Number', 'Random_Seed', 'Range', 'Real', + 'RealPart', 'Rename', 'Repeat', 'Reshape', 'RRSpacing', 'RShift', + 'Same_Type_As', 'Scale', 'Scan', 'Second', 'Selected_Char_Kind', + 'Selected_Int_Kind', 'Selected_Real_Kind', 'Set_Exponent', 'Shape', + 'ShiftA', 'ShiftL', 'ShiftR', 'Short', 'Sign', 'Signal', 'SinH', + 'Sin', 'Sleep', 'Sngl', 'Spacing', 'Spread', 'SqRt', 'SRand', + 'Stat', 'Storage_Size', 'Sum', 'SymLnk', 'System', 'System_Clock', + 'Tan', 'TanH', 'Time', 'This_Image', 'Tiny', 'TrailZ', 'Transfer', + 'Transpose', 'Trim', 'TtyNam', 'UBound', 'UCoBound', 'UMask', + 'Unlink', 'Unpack', 'Verify', 'XOr', 'ZAbs', 'ZCos', 'ZExp', + 'ZLog', 'ZSin', 'ZSqRt'), prefix=r'\b', suffix=r'\s*\b'), + Name.Builtin), + + # Booleans + (r'\.(true|false)\.', Name.Builtin), + # Comparing Operators + (r'\.(eq|ne|lt|le|gt|ge|not|and|or|eqv|neqv)\.', Operator.Word), + ], + + 'strings': [ + (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double), + (r"(?s)'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single), + ], + + 'nums': [ + (r'\d+(?![.e])(_[a-z]\w+)?', Number.Integer), + (r'[+-]?\d*\.\d+(e[-+]?\d+)?(_[a-z]\w+)?', Number.Float), + (r'[+-]?\d+\.\d*(e[-+]?\d+)?(_[a-z]\w+)?', Number.Float), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/foxpro.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/foxpro.py new file mode 100644 index 0000000000..99a65ce74e --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/foxpro.py @@ -0,0 +1,428 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.foxpro + ~~~~~~~~~~~~~~~~~~~~~~ + + Simple lexer for Microsoft Visual FoxPro source code. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer +from pygments.token import Punctuation, Text, Comment, Operator, Keyword, \ + Name, String + +__all__ = ['FoxProLexer'] + + +class FoxProLexer(RegexLexer): + """Lexer for Microsoft Visual FoxPro language. + + FoxPro syntax allows to shorten all keywords and function names + to 4 characters. Shortened forms are not recognized by this lexer. + + .. versionadded:: 1.6 + """ + + name = 'FoxPro' + aliases = ['foxpro', 'vfp', 'clipper', 'xbase'] + filenames = ['*.PRG', '*.prg'] + mimetype = [] + + flags = re.IGNORECASE | re.MULTILINE + + tokens = { + 'root': [ + (r';\s*\n', Punctuation), # consume newline + (r'(^|\n)\s*', Text, 'newline'), + + # Square brackets may be used for array indices + # and for string literal. Look for arrays + # before matching string literals. + (r'(?<=\w)\[[0-9, ]+\]', Text), + (r'\'[^\'\n]*\'|"[^"\n]*"|\[[^]*]\]', String), + (r'(^\s*\*|&&|&&).*?\n', Comment.Single), + + (r'(ABS|ACLASS|ACOPY|ACOS|ADATABASES|ADBOBJECTS|ADDBS|' + r'ADDPROPERTY|ADEL|ADIR|ADLLS|ADOCKSTATE|AELEMENT|AERROR|' + r'AEVENTS|AFIELDS|AFONT|AGETCLASS|AGETFILEVERSION|AINS|' + r'AINSTANCE|ALANGUAGE|ALEN|ALIAS|ALINES|ALLTRIM|' + r'AMEMBERS|AMOUSEOBJ|ANETRESOURCES|APRINTERS|APROCINFO|' + r'ASC|ASCAN|ASELOBJ|ASESSIONS|ASIN|ASORT|ASQLHANDLES|' + r'ASTACKINFO|ASUBSCRIPT|AT|AT_C|ATAGINFO|ATAN|ATC|ATCC|' + r'ATCLINE|ATLINE|ATN2|AUSED|AVCXCLASSES|BAR|BARCOUNT|' + r'BARPROMPT|BETWEEN|BINDEVENT|BINTOC|BITAND|BITCLEAR|' + r'BITLSHIFT|BITNOT|BITOR|BITRSHIFT|BITSET|BITTEST|BITXOR|' + r'BOF|CANDIDATE|CAPSLOCK|CAST|CDOW|CDX|CEILING|CHR|CHRSAW|' + r'CHRTRAN|CHRTRANC|CLEARRESULTSET|CMONTH|CNTBAR|CNTPAD|COL|' + r'COM|Functions|COMARRAY|COMCLASSINFO|COMPOBJ|COMPROP|' + r'COMRETURNERROR|COS|CPCONVERT|CPCURRENT|CPDBF|CREATEBINARY|' + r'CREATEOBJECT|CREATEOBJECTEX|CREATEOFFLINE|CTOBIN|CTOD|' + r'CTOT|CURDIR|CURSORGETPROP|CURSORSETPROP|CURSORTOXML|' + r'CURVAL|DATE|DATETIME|DAY|DBC|DBF|DBGETPROP|DBSETPROP|' + r'DBUSED|DDEAbortTrans|DDEAdvise|DDEEnabled|DDEExecute|' + r'DDEInitiate|DDELastError|DDEPoke|DDERequest|DDESetOption|' + r'DDESetService|DDESetTopic|DDETerminate|DEFAULTEXT|' + r'DELETED|DESCENDING|DIFFERENCE|DIRECTORY|DISKSPACE|' + r'DisplayPath|DMY|DODEFAULT|DOW|DRIVETYPE|DROPOFFLINE|' + r'DTOC|DTOR|DTOS|DTOT|EDITSOURCE|EMPTY|EOF|ERROR|EVAL(UATE)?|' + r'EVENTHANDLER|EVL|EXECSCRIPT|EXP|FCHSIZE|FCLOSE|FCOUNT|' + r'FCREATE|FDATE|FEOF|FERROR|FFLUSH|FGETS|FIELD|FILE|' + r'FILETOSTR|FILTER|FKLABEL|FKMAX|FLDLIST|FLOCK|FLOOR|' + r'FONTMETRIC|FOPEN|FOR|FORCEEXT|FORCEPATH|FOUND|FPUTS|' + r'FREAD|FSEEK|FSIZE|FTIME|FULLPATH|FV|FWRITE|' + r'GETAUTOINCVALUE|GETBAR|GETCOLOR|GETCP|GETDIR|GETENV|' + r'GETFILE|GETFLDSTATE|GETFONT|GETINTERFACE|' + r'GETNEXTMODIFIED|GETOBJECT|GETPAD|GETPEM|GETPICT|' + r'GETPRINTER|GETRESULTSET|GETWORDCOUNT|GETWORDNUM|' + r'GETCURSORADAPTER|GOMONTH|HEADER|HOME|HOUR|ICASE|' + r'IDXCOLLATE|IIF|IMESTATUS|INDBC|INDEXSEEK|INKEY|INLIST|' + r'INPUTBOX|INSMODE|INT|ISALPHA|ISBLANK|ISCOLOR|ISDIGIT|' + r'ISEXCLUSIVE|ISFLOCKED|ISLEADBYTE|ISLOWER|ISMEMOFETCHED|' + r'ISMOUSE|ISNULL|ISPEN|ISREADONLY|ISRLOCKED|' + r'ISTRANSACTABLE|ISUPPER|JUSTDRIVE|JUSTEXT|JUSTFNAME|' + r'JUSTPATH|JUSTSTEM|KEY|KEYMATCH|LASTKEY|LEFT|LEFTC|LEN|' + r'LENC|LIKE|LIKEC|LINENO|LOADPICTURE|LOCFILE|LOCK|LOG|' + r'LOG10|LOOKUP|LOWER|LTRIM|LUPDATE|MAKETRANSACTABLE|MAX|' + r'MCOL|MDOWN|MDX|MDY|MEMLINES|MEMORY|MENU|MESSAGE|' + r'MESSAGEBOX|MIN|MINUTE|MLINE|MOD|MONTH|MRKBAR|MRKPAD|' + r'MROW|MTON|MWINDOW|NDX|NEWOBJECT|NORMALIZE|NTOM|NUMLOCK|' + r'NVL|OBJNUM|OBJTOCLIENT|OBJVAR|OCCURS|OEMTOANSI|OLDVAL|' + r'ON|ORDER|OS|PAD|PADL|PARAMETERS|PAYMENT|PCOL|PCOUNT|' + r'PEMSTATUS|PI|POPUP|PRIMARY|PRINTSTATUS|PRMBAR|PRMPAD|' + r'PROGRAM|PROMPT|PROPER|PROW|PRTINFO|PUTFILE|PV|QUARTER|' + r'RAISEEVENT|RAND|RAT|RATC|RATLINE|RDLEVEL|READKEY|RECCOUNT|' + r'RECNO|RECSIZE|REFRESH|RELATION|REPLICATE|REQUERY|RGB|' + r'RGBSCHEME|RIGHT|RIGHTC|RLOCK|ROUND|ROW|RTOD|RTRIM|' + r'SAVEPICTURE|SCHEME|SCOLS|SEC|SECONDS|SEEK|SELECT|SET|' + r'SETFLDSTATE|SETRESULTSET|SIGN|SIN|SKPBAR|SKPPAD|SOUNDEX|' + r'SPACE|SQLCANCEL|SQLCOLUMNS|SQLCOMMIT|SQLCONNECT|' + r'SQLDISCONNECT|SQLEXEC|SQLGETPROP|SQLIDLEDISCONNECT|' + r'SQLMORERESULTS|SQLPREPARE|SQLROLLBACK|SQLSETPROP|' + r'SQLSTRINGCONNECT|SQLTABLES|SQRT|SROWS|STR|STRCONV|' + r'STREXTRACT|STRTOFILE|STRTRAN|STUFF|STUFFC|SUBSTR|' + r'SUBSTRC|SYS|SYSMETRIC|TABLEREVERT|TABLEUPDATE|TAG|' + r'TAGCOUNT|TAGNO|TAN|TARGET|TEXTMERGE|TIME|TRANSFORM|' + r'TRIM|TTOC|TTOD|TXNLEVEL|TXTWIDTH|TYPE|UNBINDEVENTS|' + r'UNIQUE|UPDATED|UPPER|USED|VAL|VARREAD|VARTYPE|VERSION|' + r'WBORDER|WCHILD|WCOLS|WDOCKABLE|WEEK|WEXIST|WFONT|WLAST|' + r'WLCOL|WLROW|WMAXIMUM|WMINIMUM|WONTOP|WOUTPUT|WPARENT|' + r'WREAD|WROWS|WTITLE|WVISIBLE|XMLTOCURSOR|XMLUPDATEGRAM|' + r'YEAR)(?=\s*\()', Name.Function), + + (r'_ALIGNMENT|_ASCIICOLS|_ASCIIROWS|_ASSIST|_BEAUTIFY|_BOX|' + r'_BROWSER|_BUILDER|_CALCMEM|_CALCVALUE|_CLIPTEXT|_CONVERTER|' + r'_COVERAGE|_CUROBJ|_DBLCLICK|_DIARYDATE|_DOS|_FOXDOC|_FOXREF|' + r'_GALLERY|_GENGRAPH|_GENHTML|_GENMENU|_GENPD|_GENSCRN|' + r'_GENXTAB|_GETEXPR|_INCLUDE|_INCSEEK|_INDENT|_LMARGIN|_MAC|' + r'_MENUDESIGNER|_MLINE|_PADVANCE|_PAGENO|_PAGETOTAL|_PBPAGE|' + r'_PCOLNO|_PCOPIES|_PDRIVER|_PDSETUP|_PECODE|_PEJECT|_PEPAGE|' + r'_PLENGTH|_PLINENO|_PLOFFSET|_PPITCH|_PQUALITY|_PRETEXT|' + r'_PSCODE|_PSPACING|_PWAIT|_RMARGIN|_REPORTBUILDER|' + r'_REPORTOUTPUT|_REPORTPREVIEW|_SAMPLES|_SCCTEXT|_SCREEN|' + r'_SHELL|_SPELLCHK|_STARTUP|_TABS|_TALLY|_TASKPANE|_TEXT|' + r'_THROTTLE|_TOOLBOX|_TOOLTIPTIMEOUT|_TRANSPORT|_TRIGGERLEVEL|' + r'_UNIX|_VFP|_WINDOWS|_WIZARD|_WRAP', Keyword.Pseudo), + + (r'THISFORMSET|THISFORM|THIS', Name.Builtin), + + (r'Application|CheckBox|Collection|Column|ComboBox|' + r'CommandButton|CommandGroup|Container|Control|CursorAdapter|' + r'Cursor|Custom|DataEnvironment|DataObject|EditBox|' + r'Empty|Exception|Fields|Files|File|FormSet|Form|FoxCode|' + r'Grid|Header|Hyperlink|Image|Label|Line|ListBox|Objects|' + r'OptionButton|OptionGroup|PageFrame|Page|ProjectHook|Projects|' + r'Project|Relation|ReportListener|Separator|Servers|Server|' + r'Session|Shape|Spinner|Tables|TextBox|Timer|ToolBar|' + r'XMLAdapter|XMLField|XMLTable', Name.Class), + + (r'm\.[a-z_]\w*', Name.Variable), + (r'\.(F|T|AND|OR|NOT|NULL)\.|\b(AND|OR|NOT|NULL)\b', Operator.Word), + + (r'\.(ActiveColumn|ActiveControl|ActiveForm|ActivePage|' + r'ActiveProject|ActiveRow|AddLineFeeds|ADOCodePage|Alias|' + r'Alignment|Align|AllowAddNew|AllowAutoColumnFit|' + r'AllowCellSelection|AllowDelete|AllowHeaderSizing|' + r'AllowInsert|AllowModalMessages|AllowOutput|AllowRowSizing|' + r'AllowSimultaneousFetch|AllowTabs|AllowUpdate|' + r'AlwaysOnBottom|AlwaysOnTop|Anchor|Application|' + r'AutoActivate|AutoCenter|AutoCloseTables|AutoComplete|' + r'AutoCompSource|AutoCompTable|AutoHideScrollBar|' + r'AutoIncrement|AutoOpenTables|AutoRelease|AutoSize|' + r'AutoVerbMenu|AutoYield|BackColor|ForeColor|BackStyle|' + r'BaseClass|BatchUpdateCount|BindControls|BorderColor|' + r'BorderStyle|BorderWidth|BoundColumn|BoundTo|Bound|' + r'BreakOnError|BufferModeOverride|BufferMode|' + r'BuildDateTime|ButtonCount|Buttons|Cancel|Caption|' + r'Centered|Century|ChildAlias|ChildOrder|ChildTable|' + r'ClassLibrary|Class|ClipControls|Closable|CLSID|CodePage|' + r'ColorScheme|ColorSource|ColumnCount|ColumnLines|' + r'ColumnOrder|Columns|ColumnWidths|CommandClauses|' + r'Comment|CompareMemo|ConflictCheckCmd|ConflictCheckType|' + r'ContinuousScroll|ControlBox|ControlCount|Controls|' + r'ControlSource|ConversionFunc|Count|CurrentControl|' + r'CurrentDataSession|CurrentPass|CurrentX|CurrentY|' + r'CursorSchema|CursorSource|CursorStatus|Curvature|' + r'Database|DataSessionID|DataSession|DataSourceType|' + r'DataSource|DataType|DateFormat|DateMark|Debug|' + r'DeclareXMLPrefix|DEClassLibrary|DEClass|DefaultFilePath|' + r'Default|DefOLELCID|DeleteCmdDataSourceType|DeleteCmdDataSource|' + r'DeleteCmd|DeleteMark|Description|Desktop|' + r'Details|DisabledBackColor|DisabledForeColor|' + r'DisabledItemBackColor|DisabledItemForeColor|' + r'DisabledPicture|DisableEncode|DisplayCount|' + r'DisplayValue|Dockable|Docked|DockPosition|' + r'DocumentFile|DownPicture|DragIcon|DragMode|DrawMode|' + r'DrawStyle|DrawWidth|DynamicAlignment|DynamicBackColor|' + r'DynamicForeColor|DynamicCurrentControl|DynamicFontBold|' + r'DynamicFontItalic|DynamicFontStrikethru|' + r'DynamicFontUnderline|DynamicFontName|DynamicFontOutline|' + r'DynamicFontShadow|DynamicFontSize|DynamicInputMask|' + r'DynamicLineHeight|EditorOptions|Enabled|' + r'EnableHyperlinks|Encrypted|ErrorNo|Exclude|Exclusive|' + r'FetchAsNeeded|FetchMemoCmdList|FetchMemoDataSourceType|' + r'FetchMemoDataSource|FetchMemo|FetchSize|' + r'FileClassLibrary|FileClass|FillColor|FillStyle|Filter|' + r'FirstElement|FirstNestedTable|Flags|FontBold|FontItalic|' + r'FontStrikethru|FontUnderline|FontCharSet|FontCondense|' + r'FontExtend|FontName|FontOutline|FontShadow|FontSize|' + r'ForceCloseTag|Format|FormCount|FormattedOutput|Forms|' + r'FractionDigits|FRXDataSession|FullName|GDIPlusGraphics|' + r'GridLineColor|GridLines|GridLineWidth|HalfHeightCaption|' + r'HeaderClassLibrary|HeaderClass|HeaderHeight|Height|' + r'HelpContextID|HideSelection|HighlightBackColor|' + r'HighlightForeColor|HighlightStyle|HighlightRowLineWidth|' + r'HighlightRow|Highlight|HomeDir|Hours|HostName|' + r'HScrollSmallChange|hWnd|Icon|IncrementalSearch|Increment|' + r'InitialSelectedAlias|InputMask|InsertCmdDataSourceType|' + r'InsertCmdDataSource|InsertCmdRefreshCmd|' + r'InsertCmdRefreshFieldList|InsertCmdRefreshKeyFieldList|' + r'InsertCmd|Instancing|IntegralHeight|' + r'Interval|IMEMode|IsAttribute|IsBase64|IsBinary|IsNull|' + r'IsDiffGram|IsLoaded|ItemBackColor,|ItemData|ItemIDData|' + r'ItemTips|IXMLDOMElement|KeyboardHighValue|KeyboardLowValue|' + r'Keyfield|KeyFieldList|KeyPreview|KeySort|LanguageOptions|' + r'LeftColumn|Left|LineContents|LineNo|LineSlant|LinkMaster|' + r'ListCount|ListenerType|ListIndex|ListItemID|ListItem|' + r'List|LockColumnsLeft|LockColumns|LockScreen|MacDesktop|' + r'MainFile|MapN19_4ToCurrency|MapBinary|MapVarchar|Margin|' + r'MaxButton|MaxHeight|MaxLeft|MaxLength|MaxRecords|MaxTop|' + r'MaxWidth|MDIForm|MemberClassLibrary|MemberClass|' + r'MemoWindow|Message|MinButton|MinHeight|MinWidth|' + r'MouseIcon|MousePointer|Movable|MoverBars|MultiSelect|' + r'Name|NestedInto|NewIndex|NewItemID|NextSiblingTable|' + r'NoCpTrans|NoDataOnLoad|NoData|NullDisplay|' + r'NumberOfElements|Object|OLEClass|OLEDragMode|' + r'OLEDragPicture|OLEDropEffects|OLEDropHasData|' + r'OLEDropMode|OLEDropTextInsertion|OLELCID|' + r'OLERequestPendingTimeout|OLEServerBusyRaiseError|' + r'OLEServerBusyTimeout|OLETypeAllowed|OneToMany|' + r'OpenViews|OpenWindow|Optimize|OrderDirection|Order|' + r'OutputPageCount|OutputType|PageCount|PageHeight|' + r'PageNo|PageOrder|Pages|PageTotal|PageWidth|' + r'PanelLink|Panel|ParentAlias|ParentClass|ParentTable|' + r'Parent|Partition|PasswordChar|PictureMargin|' + r'PicturePosition|PictureSpacing|PictureSelectionDisplay|' + r'PictureVal|Picture|Prepared|' + r'PolyPoints|PreserveWhiteSpace|PreviewContainer|' + r'PrintJobName|Procedure|PROCESSID|ProgID|ProjectHookClass|' + r'ProjectHookLibrary|ProjectHook|QuietMode|' + r'ReadCycle|ReadLock|ReadMouse|ReadObject|ReadOnly|' + r'ReadSave|ReadTimeout|RecordMark|RecordSourceType|' + r'RecordSource|RefreshAlias|' + r'RefreshCmdDataSourceType|RefreshCmdDataSource|RefreshCmd|' + r'RefreshIgnoreFieldList|RefreshTimeStamp|RelationalExpr|' + r'RelativeColumn|RelativeRow|ReleaseType|Resizable|' + r'RespectCursorCP|RespectNesting|RightToLeft|RotateFlip|' + r'Rotation|RowColChange|RowHeight|RowSourceType|' + r'RowSource|ScaleMode|SCCProvider|SCCStatus|ScrollBars|' + r'Seconds|SelectCmd|SelectedID|' + r'SelectedItemBackColor|SelectedItemForeColor|Selected|' + r'SelectionNamespaces|SelectOnEntry|SelLength|SelStart|' + r'SelText|SendGDIPlusImage|SendUpdates|ServerClassLibrary|' + r'ServerClass|ServerHelpFile|ServerName|' + r'ServerProject|ShowTips|ShowInTaskbar|ShowWindow|' + r'Sizable|SizeBox|SOM|Sorted|Sparse|SpecialEffect|' + r'SpinnerHighValue|SpinnerLowValue|SplitBar|StackLevel|' + r'StartMode|StatusBarText|StatusBar|Stretch|StrictDateEntry|' + r'Style|TabIndex|Tables|TabOrientation|Tabs|TabStop|' + r'TabStretch|TabStyle|Tag|TerminateRead|Text|Themes|' + r'ThreadID|TimestampFieldList|TitleBar|ToolTipText|' + r'TopIndex|TopItemID|Top|TwoPassProcess|TypeLibCLSID|' + r'TypeLibDesc|TypeLibName|Type|Unicode|UpdatableFieldList|' + r'UpdateCmdDataSourceType|UpdateCmdDataSource|' + r'UpdateCmdRefreshCmd|UpdateCmdRefreshFieldList|' + r'UpdateCmdRefreshKeyFieldList|UpdateCmd|' + r'UpdateGramSchemaLocation|UpdateGram|UpdateNameList|UpdateType|' + r'UseCodePage|UseCursorSchema|UseDeDataSource|UseMemoSize|' + r'UserValue|UseTransactions|UTF8Encoded|Value|VersionComments|' + r'VersionCompany|VersionCopyright|VersionDescription|' + r'VersionNumber|VersionProduct|VersionTrademarks|Version|' + r'VFPXMLProgID|ViewPortHeight|ViewPortLeft|' + r'ViewPortTop|ViewPortWidth|VScrollSmallChange|View|Visible|' + r'VisualEffect|WhatsThisButton|WhatsThisHelpID|WhatsThisHelp|' + r'WhereType|Width|WindowList|WindowState|WindowType|WordWrap|' + r'WrapCharInCDATA|WrapInCDATA|WrapMemoInCDATA|XMLAdapter|' + r'XMLConstraints|XMLNameIsXPath|XMLNamespace|XMLName|' + r'XMLPrefix|XMLSchemaLocation|XMLTable|XMLType|' + r'XSDfractionDigits|XSDmaxLength|XSDtotalDigits|' + r'XSDtype|ZoomBox)', Name.Attribute), + + (r'\.(ActivateCell|AddColumn|AddItem|AddListItem|AddObject|' + r'AddProperty|AddTableSchema|AddToSCC|Add|' + r'ApplyDiffgram|Attach|AutoFit|AutoOpen|Box|Build|' + r'CancelReport|ChangesToCursor|CheckIn|CheckOut|Circle|' + r'CleanUp|ClearData|ClearStatus|Clear|CloneObject|CloseTables|' + r'Close|Cls|CursorAttach|CursorDetach|CursorFill|' + r'CursorRefresh|DataToClip|DelayedMemoFetch|DeleteColumn|' + r'Dock|DoMessage|DoScroll|DoStatus|DoVerb|Drag|Draw|Eval|' + r'GetData|GetDockState|GetFormat|GetKey|GetLatestVersion|' + r'GetPageHeight|GetPageWidth|Help|Hide|IncludePageInOutput|' + r'IndexToItemID|ItemIDToIndex|Item|LoadXML|Line|Modify|' + r'MoveItem|Move|Nest|OLEDrag|OnPreviewClose|OutputPage|' + r'Point|Print|PSet|Quit|ReadExpression|ReadMethod|' + r'RecordRefresh|Refresh|ReleaseXML|Release|RemoveFromSCC|' + r'RemoveItem|RemoveListItem|RemoveObject|Remove|' + r'Render|Requery|RequestData|ResetToDefault|Reset|Run|' + r'SaveAsClass|SaveAs|SetAll|SetData|SetFocus|SetFormat|' + r'SetMain|SetVar|SetViewPort|ShowWhatsThis|Show|' + r'SupportsListenerType|TextHeight|TextWidth|ToCursor|' + r'ToXML|UndoCheckOut|Unnest|UpdateStatus|WhatsThisMode|' + r'WriteExpression|WriteMethod|ZOrder)', Name.Function), + + (r'\.(Activate|AdjustObjectSize|AfterBand|AfterBuild|' + r'AfterCloseTables|AfterCursorAttach|AfterCursorClose|' + r'AfterCursorDetach|AfterCursorFill|AfterCursorRefresh|' + r'AfterCursorUpdate|AfterDelete|AfterInsert|' + r'AfterRecordRefresh|AfterUpdate|AfterDock|AfterReport|' + r'AfterRowColChange|BeforeBand|BeforeCursorAttach|' + r'BeforeCursorClose|BeforeCursorDetach|BeforeCursorFill|' + r'BeforeCursorRefresh|BeforeCursorUpdate|BeforeDelete|' + r'BeforeInsert|BeforeDock|BeforeOpenTables|' + r'BeforeRecordRefresh|BeforeReport|BeforeRowColChange|' + r'BeforeUpdate|Click|dbc_Activate|dbc_AfterAddTable|' + r'dbc_AfterAppendProc|dbc_AfterCloseTable|dbc_AfterCopyProc|' + r'dbc_AfterCreateConnection|dbc_AfterCreateOffline|' + r'dbc_AfterCreateTable|dbc_AfterCreateView|dbc_AfterDBGetProp|' + r'dbc_AfterDBSetProp|dbc_AfterDeleteConnection|' + r'dbc_AfterDropOffline|dbc_AfterDropTable|' + r'dbc_AfterModifyConnection|dbc_AfterModifyProc|' + r'dbc_AfterModifyTable|dbc_AfterModifyView|dbc_AfterOpenTable|' + r'dbc_AfterRemoveTable|dbc_AfterRenameConnection|' + r'dbc_AfterRenameTable|dbc_AfterRenameView|' + r'dbc_AfterValidateData|dbc_BeforeAddTable|' + r'dbc_BeforeAppendProc|dbc_BeforeCloseTable|' + r'dbc_BeforeCopyProc|dbc_BeforeCreateConnection|' + r'dbc_BeforeCreateOffline|dbc_BeforeCreateTable|' + r'dbc_BeforeCreateView|dbc_BeforeDBGetProp|' + r'dbc_BeforeDBSetProp|dbc_BeforeDeleteConnection|' + r'dbc_BeforeDropOffline|dbc_BeforeDropTable|' + r'dbc_BeforeModifyConnection|dbc_BeforeModifyProc|' + r'dbc_BeforeModifyTable|dbc_BeforeModifyView|' + r'dbc_BeforeOpenTable|dbc_BeforeRemoveTable|' + r'dbc_BeforeRenameConnection|dbc_BeforeRenameTable|' + r'dbc_BeforeRenameView|dbc_BeforeValidateData|' + r'dbc_CloseData|dbc_Deactivate|dbc_ModifyData|dbc_OpenData|' + r'dbc_PackData|DblClick|Deactivate|Deleted|Destroy|DoCmd|' + r'DownClick|DragDrop|DragOver|DropDown|ErrorMessage|Error|' + r'EvaluateContents|GotFocus|Init|InteractiveChange|KeyPress|' + r'LoadReport|Load|LostFocus|Message|MiddleClick|MouseDown|' + r'MouseEnter|MouseLeave|MouseMove|MouseUp|MouseWheel|Moved|' + r'OLECompleteDrag|OLEDragOver|OLEGiveFeedback|OLESetData|' + r'OLEStartDrag|OnMoveItem|Paint|ProgrammaticChange|' + r'QueryAddFile|QueryModifyFile|QueryNewFile|QueryRemoveFile|' + r'QueryRunFile|QueryUnload|RangeHigh|RangeLow|ReadActivate|' + r'ReadDeactivate|ReadShow|ReadValid|ReadWhen|Resize|' + r'RightClick|SCCInit|SCCDestroy|Scrolled|Timer|UIEnable|' + r'UnDock|UnloadReport|Unload|UpClick|Valid|When)', Name.Function), + + (r'\s+', Text), + # everything else is not colored + (r'.', Text), + ], + 'newline': [ + (r'\*.*?$', Comment.Single, '#pop'), + (r'(ACCEPT|ACTIVATE\s*MENU|ACTIVATE\s*POPUP|ACTIVATE\s*SCREEN|' + r'ACTIVATE\s*WINDOW|APPEND|APPEND\s*FROM|APPEND\s*FROM\s*ARRAY|' + r'APPEND\s*GENERAL|APPEND\s*MEMO|ASSIST|AVERAGE|BLANK|BROWSE|' + r'BUILD\s*APP|BUILD\s*EXE|BUILD\s*PROJECT|CALCULATE|CALL|' + r'CANCEL|CHANGE|CLEAR|CLOSE|CLOSE\s*MEMO|COMPILE|CONTINUE|' + r'COPY\s*FILE|COPY\s*INDEXES|COPY\s*MEMO|COPY\s*STRUCTURE|' + r'COPY\s*STRUCTURE\s*EXTENDED|COPY\s*TAG|COPY\s*TO|' + r'COPY\s*TO\s*ARRAY|COUNT|CREATE|CREATE\s*COLOR\s*SET|' + r'CREATE\s*CURSOR|CREATE\s*FROM|CREATE\s*LABEL|CREATE\s*MENU|' + r'CREATE\s*PROJECT|CREATE\s*QUERY|CREATE\s*REPORT|' + r'CREATE\s*SCREEN|CREATE\s*TABLE|CREATE\s*VIEW|DDE|' + r'DEACTIVATE\s*MENU|DEACTIVATE\s*POPUP|DEACTIVATE\s*WINDOW|' + r'DECLARE|DEFINE\s*BAR|DEFINE\s*BOX|DEFINE\s*MENU|' + r'DEFINE\s*PAD|DEFINE\s*POPUP|DEFINE\s*WINDOW|DELETE|' + r'DELETE\s*FILE|DELETE\s*TAG|DIMENSION|DIRECTORY|DISPLAY|' + r'DISPLAY\s*FILES|DISPLAY\s*MEMORY|DISPLAY\s*STATUS|' + r'DISPLAY\s*STRUCTURE|DO|EDIT|EJECT|EJECT\s*PAGE|ERASE|' + r'EXIT|EXPORT|EXTERNAL|FILER|FIND|FLUSH|FUNCTION|GATHER|' + r'GETEXPR|GO|GOTO|HELP|HIDE\s*MENU|HIDE\s*POPUP|' + r'HIDE\s*WINDOW|IMPORT|INDEX|INPUT|INSERT|JOIN|KEYBOARD|' + r'LABEL|LIST|LOAD|LOCATE|LOOP|MENU|MENU\s*TO|MODIFY\s*COMMAND|' + r'MODIFY\s*FILE|MODIFY\s*GENERAL|MODIFY\s*LABEL|MODIFY\s*MEMO|' + r'MODIFY\s*MENU|MODIFY\s*PROJECT|MODIFY\s*QUERY|' + r'MODIFY\s*REPORT|MODIFY\s*SCREEN|MODIFY\s*STRUCTURE|' + r'MODIFY\s*WINDOW|MOVE\s*POPUP|MOVE\s*WINDOW|NOTE|' + r'ON\s*APLABOUT|ON\s*BAR|ON\s*ERROR|ON\s*ESCAPE|' + r'ON\s*EXIT\s*BAR|ON\s*EXIT\s*MENU|ON\s*EXIT\s*PAD|' + r'ON\s*EXIT\s*POPUP|ON\s*KEY|ON\s*KEY\s*=|ON\s*KEY\s*LABEL|' + r'ON\s*MACHELP|ON\s*PAD|ON\s*PAGE|ON\s*READERROR|' + r'ON\s*SELECTION\s*BAR|ON\s*SELECTION\s*MENU|' + r'ON\s*SELECTION\s*PAD|ON\s*SELECTION\s*POPUP|ON\s*SHUTDOWN|' + r'PACK|PARAMETERS|PLAY\s*MACRO|POP\s*KEY|POP\s*MENU|' + r'POP\s*POPUP|PRIVATE|PROCEDURE|PUBLIC|PUSH\s*KEY|' + r'PUSH\s*MENU|PUSH\s*POPUP|QUIT|READ|READ\s*MENU|RECALL|' + r'REINDEX|RELEASE|RELEASE\s*MODULE|RENAME|REPLACE|' + r'REPLACE\s*FROM\s*ARRAY|REPORT|RESTORE\s*FROM|' + r'RESTORE\s*MACROS|RESTORE\s*SCREEN|RESTORE\s*WINDOW|' + r'RESUME|RETRY|RETURN|RUN|RUN\s*\/N"|RUNSCRIPT|' + r'SAVE\s*MACROS|SAVE\s*SCREEN|SAVE\s*TO|SAVE\s*WINDOWS|' + r'SCATTER|SCROLL|SEEK|SELECT|SET|SET\s*ALTERNATE|' + r'SET\s*ANSI|SET\s*APLABOUT|SET\s*AUTOSAVE|SET\s*BELL|' + r'SET\s*BLINK|SET\s*BLOCKSIZE|SET\s*BORDER|SET\s*BRSTATUS|' + r'SET\s*CARRY|SET\s*CENTURY|SET\s*CLEAR|SET\s*CLOCK|' + r'SET\s*COLLATE|SET\s*COLOR\s*OF|SET\s*COLOR\s*OF\s*SCHEME|' + r'SET\s*COLOR\s*SET|SET\s*COLOR\s*TO|SET\s*COMPATIBLE|' + r'SET\s*CONFIRM|SET\s*CONSOLE|SET\s*CURRENCY|SET\s*CURSOR|' + r'SET\s*DATE|SET\s*DEBUG|SET\s*DECIMALS|SET\s*DEFAULT|' + r'SET\s*DELETED|SET\s*DELIMITERS|SET\s*DEVELOPMENT|' + r'SET\s*DEVICE|SET\s*DISPLAY|SET\s*DOHISTORY|SET\s*ECHO|' + r'SET\s*ESCAPE|SET\s*EXACT|SET\s*EXCLUSIVE|SET\s*FIELDS|' + r'SET\s*FILTER|SET\s*FIXED|SET\s*FORMAT|SET\s*FULLPATH|' + r'SET\s*FUNCTION|SET\s*HEADINGS|SET\s*HELP|SET\s*HELPFILTER|' + r'SET\s*HOURS|SET\s*INDEX|SET\s*INTENSITY|SET\s*KEY|' + r'SET\s*KEYCOMP|SET\s*LIBRARY|SET\s*LOCK|SET\s*LOGERRORS|' + r'SET\s*MACDESKTOP|SET\s*MACHELP|SET\s*MACKEY|SET\s*MARGIN|' + r'SET\s*MARK\s*OF|SET\s*MARK\s*TO|SET\s*MEMOWIDTH|' + r'SET\s*MESSAGE|SET\s*MOUSE|SET\s*MULTILOCKS|SET\s*NEAR|' + r'SET\s*NOCPTRANS|SET\s*NOTIFY|SET\s*ODOMETER|SET\s*OPTIMIZE|' + r'SET\s*ORDER|SET\s*PALETTE|SET\s*PATH|SET\s*PDSETUP|' + r'SET\s*POINT|SET\s*PRINTER|SET\s*PROCEDURE|SET\s*READBORDER|' + r'SET\s*REFRESH|SET\s*RELATION|SET\s*RELATION\s*OFF|' + r'SET\s*REPROCESS|SET\s*RESOURCE|SET\s*SAFETY|SET\s*SCOREBOARD|' + r'SET\s*SEPARATOR|SET\s*SHADOWS|SET\s*SKIP|SET\s*SKIP\s*OF|' + r'SET\s*SPACE|SET\s*STATUS|SET\s*STATUS\s*BAR|SET\s*STEP|' + r'SET\s*STICKY|SET\s*SYSMENU|SET\s*TALK|SET\s*TEXTMERGE|' + r'SET\s*TEXTMERGE\s*DELIMITERS|SET\s*TOPIC|SET\s*TRBETWEEN|' + r'SET\s*TYPEAHEAD|SET\s*UDFPARMS|SET\s*UNIQUE|SET\s*VIEW|' + r'SET\s*VOLUME|SET\s*WINDOW\s*OF\s*MEMO|SET\s*XCMDFILE|' + r'SHOW\s*GET|SHOW\s*GETS|SHOW\s*MENU|SHOW\s*OBJECT|' + r'SHOW\s*POPUP|SHOW\s*WINDOW|SIZE\s*POPUP|SKIP|SORT|' + r'STORE|SUM|SUSPEND|TOTAL|TYPE|UNLOCK|UPDATE|USE|WAIT|' + r'ZAP|ZOOM\s*WINDOW|DO\s*CASE|CASE|OTHERWISE|ENDCASE|' + r'DO\s*WHILE|ENDDO|FOR|ENDFOR|NEXT|IF|ELSE|ENDIF|PRINTJOB|' + r'ENDPRINTJOB|SCAN|ENDSCAN|TEXT|ENDTEXT|=)', + Keyword.Reserved, '#pop'), + (r'#\s*(IF|ELIF|ELSE|ENDIF|DEFINE|IFDEF|IFNDEF|INCLUDE)', + Comment.Preproc, '#pop'), + (r'(m\.)?[a-z_]\w*', Name.Variable, '#pop'), + (r'.', Text, '#pop'), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/functional.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/functional.py new file mode 100644 index 0000000000..791e8b6485 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/functional.py @@ -0,0 +1,21 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.functional + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + + Just export lexer classes previously contained in this module. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexers.lisp import SchemeLexer, CommonLispLexer, RacketLexer, \ + NewLispLexer +from pygments.lexers.haskell import HaskellLexer, LiterateHaskellLexer, \ + KokaLexer +from pygments.lexers.theorem import CoqLexer +from pygments.lexers.erlang import ErlangLexer, ErlangShellLexer, \ + ElixirConsoleLexer, ElixirLexer +from pygments.lexers.ml import SMLLexer, OcamlLexer, OpaLexer + +__all__ = [] diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/go.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/go.py new file mode 100644 index 0000000000..11e29352dc --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/go.py @@ -0,0 +1,101 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.go + ~~~~~~~~~~~~~~~~~~ + + Lexers for the Google Go language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, bygroups, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['GoLexer'] + + +class GoLexer(RegexLexer): + """ + For `Go `_ source. + + .. versionadded:: 1.2 + """ + name = 'Go' + filenames = ['*.go'] + aliases = ['go'] + mimetypes = ['text/x-gosrc'] + + flags = re.MULTILINE | re.UNICODE + + tokens = { + 'root': [ + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuations + (r'//(.*?)\n', Comment.Single), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + (r'(import|package)\b', Keyword.Namespace), + (r'(var|func|struct|map|chan|type|interface|const)\b', + Keyword.Declaration), + (words(( + 'break', 'default', 'select', 'case', 'defer', 'go', + 'else', 'goto', 'switch', 'fallthrough', 'if', 'range', + 'continue', 'for', 'return'), suffix=r'\b'), + Keyword), + (r'(true|false|iota|nil)\b', Keyword.Constant), + # It seems the builtin types aren't actually keywords, but + # can be used as functions. So we need two declarations. + (words(( + 'uint', 'uint8', 'uint16', 'uint32', 'uint64', + 'int', 'int8', 'int16', 'int32', 'int64', + 'float', 'float32', 'float64', + 'complex64', 'complex128', 'byte', 'rune', + 'string', 'bool', 'error', 'uintptr', + 'print', 'println', 'panic', 'recover', 'close', 'complex', + 'real', 'imag', 'len', 'cap', 'append', 'copy', 'delete', + 'new', 'make'), suffix=r'\b(\()'), + bygroups(Name.Builtin, Punctuation)), + (words(( + 'uint', 'uint8', 'uint16', 'uint32', 'uint64', + 'int', 'int8', 'int16', 'int32', 'int64', + 'float', 'float32', 'float64', + 'complex64', 'complex128', 'byte', 'rune', + 'string', 'bool', 'error', 'uintptr'), suffix=r'\b'), + Keyword.Type), + # imaginary_lit + (r'\d+i', Number), + (r'\d+\.\d*([Ee][-+]\d+)?i', Number), + (r'\.\d+([Ee][-+]\d+)?i', Number), + (r'\d+[Ee][-+]\d+i', Number), + # float_lit + (r'\d+(\.\d+[eE][+\-]?\d+|' + r'\.\d*|[eE][+\-]?\d+)', Number.Float), + (r'\.\d+([eE][+\-]?\d+)?', Number.Float), + # int_lit + # -- octal_lit + (r'0[0-7]+', Number.Oct), + # -- hex_lit + (r'0[xX][0-9a-fA-F]+', Number.Hex), + # -- decimal_lit + (r'(0|[1-9][0-9]*)', Number.Integer), + # char_lit + (r"""'(\\['"\\abfnrtv]|\\x[0-9a-fA-F]{2}|\\[0-7]{1,3}""" + r"""|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}|[^\\])'""", + String.Char), + # StringLiteral + # -- raw_string_lit + (r'`[^`]*`', String), + # -- interpreted_string_lit + (r'"(\\\\|\\"|[^"])*"', String), + # Tokens + (r'(<<=|>>=|<<|>>|<=|>=|&\^=|&\^|\+=|-=|\*=|/=|%=|&=|\|=|&&|\|\|' + r'|<-|\+\+|--|==|!=|:=|\.\.\.|[+\-*/%&])', Operator), + (r'[|^<>=!()\[\]{}.,;:]', Punctuation), + # identifier + (r'[^\W\d]\w*', Name.Other), + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graph.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graph.py new file mode 100644 index 0000000000..6137363181 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graph.py @@ -0,0 +1,79 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.graph + ~~~~~~~~~~~~~~~~~~~~~ + + Lexers for graph query languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, using, this +from pygments.token import Keyword, Punctuation, Comment, Operator, Name,\ + String, Number, Whitespace + + +__all__ = ['CypherLexer'] + + +class CypherLexer(RegexLexer): + """ + For `Cypher Query Language + `_ + + For the Cypher version in Neo4J 2.0 + + .. versionadded:: 2.0 + """ + name = 'Cypher' + aliases = ['cypher'] + filenames = ['*.cyp', '*.cypher'] + + flags = re.MULTILINE | re.IGNORECASE + + tokens = { + 'root': [ + include('comment'), + include('keywords'), + include('clauses'), + include('relations'), + include('strings'), + include('whitespace'), + include('barewords'), + ], + 'comment': [ + (r'^.*//.*\n', Comment.Single), + ], + 'keywords': [ + (r'(create|order|match|limit|set|skip|start|return|with|where|' + r'delete|foreach|not|by)\b', Keyword), + ], + 'clauses': [ + # TODO: many missing ones, see http://docs.neo4j.org/refcard/2.0/ + (r'(all|any|as|asc|create|create\s+unique|delete|' + r'desc|distinct|foreach|in|is\s+null|limit|match|none|' + r'order\s+by|return|set|skip|single|start|union|where|with)\b', + Keyword), + ], + 'relations': [ + (r'(-\[)(.*?)(\]->)', bygroups(Operator, using(this), Operator)), + (r'(<-\[)(.*?)(\]-)', bygroups(Operator, using(this), Operator)), + (r'-->|<--|\[|\]', Operator), + (r'<|>|<>|=|<=|=>|\(|\)|\||:|,|;', Punctuation), + (r'[.*{}]', Punctuation), + ], + 'strings': [ + (r'"(?:\\[tbnrf\'"\\]|[^\\"])*"', String), + (r'`(?:``|[^`])+`', Name.Variable), + ], + 'whitespace': [ + (r'\s+', Whitespace), + ], + 'barewords': [ + (r'[a-z]\w*', Name), + (r'\d+', Number), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graphics.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graphics.py new file mode 100644 index 0000000000..0b8bf5d875 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/graphics.py @@ -0,0 +1,553 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.graphics + ~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for computer graphics and plotting related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, words, include, bygroups, using, \ + this, default +from pygments.token import Text, Comment, Operator, Keyword, Name, \ + Number, Punctuation, String + +__all__ = ['GLShaderLexer', 'PostScriptLexer', 'AsymptoteLexer', 'GnuplotLexer', + 'PovrayLexer'] + + +class GLShaderLexer(RegexLexer): + """ + GLSL (OpenGL Shader) lexer. + + .. versionadded:: 1.1 + """ + name = 'GLSL' + aliases = ['glsl'] + filenames = ['*.vert', '*.frag', '*.geo'] + mimetypes = ['text/x-glslsrc'] + + tokens = { + 'root': [ + (r'^#.*', Comment.Preproc), + (r'//.*', Comment.Single), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + (r'\+|-|~|!=?|\*|/|%|<<|>>|<=?|>=?|==?|&&?|\^|\|\|?', + Operator), + (r'[?:]', Operator), # quick hack for ternary + (r'\bdefined\b', Operator), + (r'[;{}(),\[\]]', Punctuation), + # FIXME when e is present, no decimal point needed + (r'[+-]?\d*\.\d+([eE][-+]?\d+)?', Number.Float), + (r'[+-]?\d+\.\d*([eE][-+]?\d+)?', Number.Float), + (r'0[xX][0-9a-fA-F]*', Number.Hex), + (r'0[0-7]*', Number.Oct), + (r'[1-9][0-9]*', Number.Integer), + (words(( + 'attribute', 'const', 'uniform', 'varying', 'centroid', 'break', + 'continue', 'do', 'for', 'while', 'if', 'else', 'in', 'out', + 'inout', 'float', 'int', 'void', 'bool', 'true', 'false', + 'invariant', 'discard', 'return', 'mat2', 'mat3' 'mat4', + 'mat2x2', 'mat3x2', 'mat4x2', 'mat2x3', 'mat3x3', 'mat4x3', + 'mat2x4', 'mat3x4', 'mat4x4', 'vec2', 'vec3', 'vec4', + 'ivec2', 'ivec3', 'ivec4', 'bvec2', 'bvec3', 'bvec4', + 'sampler1D', 'sampler2D', 'sampler3D' 'samplerCube', + 'sampler1DShadow', 'sampler2DShadow', 'struct'), + prefix=r'\b', suffix=r'\b'), + Keyword), + (words(( + 'asm', 'class', 'union', 'enum', 'typedef', 'template', 'this', + 'packed', 'goto', 'switch', 'default', 'inline', 'noinline', + 'volatile', 'public', 'static', 'extern', 'external', 'interface', + 'long', 'short', 'double', 'half', 'fixed', 'unsigned', 'lowp', + 'mediump', 'highp', 'precision', 'input', 'output', + 'hvec2', 'hvec3', 'hvec4', 'dvec2', 'dvec3', 'dvec4', + 'fvec2', 'fvec3', 'fvec4', 'sampler2DRect', 'sampler3DRect', + 'sampler2DRectShadow', 'sizeof', 'cast', 'namespace', 'using'), + prefix=r'\b', suffix=r'\b'), + Keyword), # future use + (r'[a-zA-Z_]\w*', Name), + (r'\.', Punctuation), + (r'\s+', Text), + ], + } + + +class PostScriptLexer(RegexLexer): + """ + Lexer for PostScript files. + + The PostScript Language Reference published by Adobe at + + is the authority for this. + + .. versionadded:: 1.4 + """ + name = 'PostScript' + aliases = ['postscript', 'postscr'] + filenames = ['*.ps', '*.eps'] + mimetypes = ['application/postscript'] + + delimiter = r'()<>\[\]{}/%\s' + delimiter_end = r'(?=[%s])' % delimiter + + valid_name_chars = r'[^%s]' % delimiter + valid_name = r"%s+%s" % (valid_name_chars, delimiter_end) + + tokens = { + 'root': [ + # All comment types + (r'^%!.+\n', Comment.Preproc), + (r'%%.*\n', Comment.Special), + (r'(^%.*\n){2,}', Comment.Multiline), + (r'%.*\n', Comment.Single), + + # String literals are awkward; enter separate state. + (r'\(', String, 'stringliteral'), + + (r'[{}<>\[\]]', Punctuation), + + # Numbers + (r'<[0-9A-Fa-f]+>' + delimiter_end, Number.Hex), + # Slight abuse: use Oct to signify any explicit base system + (r'[0-9]+\#(\-|\+)?([0-9]+\.?|[0-9]*\.[0-9]+|[0-9]+\.[0-9]*)' + r'((e|E)[0-9]+)?' + delimiter_end, Number.Oct), + (r'(\-|\+)?([0-9]+\.?|[0-9]*\.[0-9]+|[0-9]+\.[0-9]*)((e|E)[0-9]+)?' + + delimiter_end, Number.Float), + (r'(\-|\+)?[0-9]+' + delimiter_end, Number.Integer), + + # References + (r'\/%s' % valid_name, Name.Variable), + + # Names + (valid_name, Name.Function), # Anything else is executed + + # These keywords taken from + # + # Is there an authoritative list anywhere that doesn't involve + # trawling documentation? + + (r'(false|true)' + delimiter_end, Keyword.Constant), + + # Conditionals / flow control + (r'(eq|ne|g[et]|l[et]|and|or|not|if(?:else)?|for(?:all)?)' + + delimiter_end, Keyword.Reserved), + + (words(( + 'abs', 'add', 'aload', 'arc', 'arcn', 'array', 'atan', 'begin', + 'bind', 'ceiling', 'charpath', 'clip', 'closepath', 'concat', + 'concatmatrix', 'copy', 'cos', 'currentlinewidth', 'currentmatrix', + 'currentpoint', 'curveto', 'cvi', 'cvs', 'def', 'defaultmatrix', + 'dict', 'dictstackoverflow', 'div', 'dtransform', 'dup', 'end', + 'exch', 'exec', 'exit', 'exp', 'fill', 'findfont', 'floor', 'get', + 'getinterval', 'grestore', 'gsave', 'gt', 'identmatrix', 'idiv', + 'idtransform', 'index', 'invertmatrix', 'itransform', 'length', + 'lineto', 'ln', 'load', 'log', 'loop', 'matrix', 'mod', 'moveto', + 'mul', 'neg', 'newpath', 'pathforall', 'pathbbox', 'pop', 'print', + 'pstack', 'put', 'quit', 'rand', 'rangecheck', 'rcurveto', 'repeat', + 'restore', 'rlineto', 'rmoveto', 'roll', 'rotate', 'round', 'run', + 'save', 'scale', 'scalefont', 'setdash', 'setfont', 'setgray', + 'setlinecap', 'setlinejoin', 'setlinewidth', 'setmatrix', + 'setrgbcolor', 'shfill', 'show', 'showpage', 'sin', 'sqrt', + 'stack', 'stringwidth', 'stroke', 'strokepath', 'sub', 'syntaxerror', + 'transform', 'translate', 'truncate', 'typecheck', 'undefined', + 'undefinedfilename', 'undefinedresult'), suffix=delimiter_end), + Name.Builtin), + + (r'\s+', Text), + ], + + 'stringliteral': [ + (r'[^()\\]+', String), + (r'\\', String.Escape, 'escape'), + (r'\(', String, '#push'), + (r'\)', String, '#pop'), + ], + + 'escape': [ + (r'[0-8]{3}|n|r|t|b|f|\\|\(|\)', String.Escape, '#pop'), + default('#pop'), + ], + } + + +class AsymptoteLexer(RegexLexer): + """ + For `Asymptote `_ source code. + + .. versionadded:: 1.2 + """ + name = 'Asymptote' + aliases = ['asy', 'asymptote'] + filenames = ['*.asy'] + mimetypes = ['text/x-asymptote'] + + #: optional Comment or Whitespace + _ws = r'(?:\s|//.*?\n|/\*.*?\*/)+' + + tokens = { + 'whitespace': [ + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuation + (r'//(\n|(.|\n)*?[^\\]\n)', Comment), + (r'/(\\\n)?\*(.|\n)*?\*(\\\n)?/', Comment), + ], + 'statements': [ + # simple string (TeX friendly) + (r'"(\\\\|\\"|[^"])*"', String), + # C style string (with character escapes) + (r"'", String, 'string'), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'0x[0-9a-fA-F]+[Ll]?', Number.Hex), + (r'0[0-7]+[Ll]?', Number.Oct), + (r'\d+[Ll]?', Number.Integer), + (r'[~!%^&*+=|?:<>/-]', Operator), + (r'[()\[\],.]', Punctuation), + (r'\b(case)(.+?)(:)', bygroups(Keyword, using(this), Text)), + (r'(and|controls|tension|atleast|curl|if|else|while|for|do|' + r'return|break|continue|struct|typedef|new|access|import|' + r'unravel|from|include|quote|static|public|private|restricted|' + r'this|explicit|true|false|null|cycle|newframe|operator)\b', Keyword), + # Since an asy-type-name can be also an asy-function-name, + # in the following we test if the string " [a-zA-Z]" follows + # the Keyword.Type. + # Of course it is not perfect ! + (r'(Braid|FitResult|Label|Legend|TreeNode|abscissa|arc|arrowhead|' + r'binarytree|binarytreeNode|block|bool|bool3|bounds|bqe|circle|' + r'conic|coord|coordsys|cputime|ellipse|file|filltype|frame|grid3|' + r'guide|horner|hsv|hyperbola|indexedTransform|int|inversion|key|' + r'light|line|linefit|marginT|marker|mass|object|pair|parabola|path|' + r'path3|pen|picture|point|position|projection|real|revolution|' + r'scaleT|scientific|segment|side|slice|splitface|string|surface|' + r'tensionSpecifier|ticklocate|ticksgridT|tickvalues|transform|' + r'transformation|tree|triangle|trilinear|triple|vector|' + r'vertex|void)(?=\s+[a-zA-Z])', Keyword.Type), + # Now the asy-type-name which are not asy-function-name + # except yours ! + # Perhaps useless + (r'(Braid|FitResult|TreeNode|abscissa|arrowhead|block|bool|bool3|' + r'bounds|coord|frame|guide|horner|int|linefit|marginT|pair|pen|' + r'picture|position|real|revolution|slice|splitface|ticksgridT|' + r'tickvalues|tree|triple|vertex|void)\b', Keyword.Type), + ('[a-zA-Z_]\w*:(?!:)', Name.Label), + ('[a-zA-Z_]\w*', Name), + ], + 'root': [ + include('whitespace'), + # functions + (r'((?:[\w*\s])+?(?:\s|\*))' # return arguments + r'([a-zA-Z_]\w*)' # method name + r'(\s*\([^;]*?\))' # signature + r'(' + _ws + r')(\{)', + bygroups(using(this), Name.Function, using(this), using(this), + Punctuation), + 'function'), + # function declarations + (r'((?:[\w*\s])+?(?:\s|\*))' # return arguments + r'([a-zA-Z_]\w*)' # method name + r'(\s*\([^;]*?\))' # signature + r'(' + _ws + r')(;)', + bygroups(using(this), Name.Function, using(this), using(this), + Punctuation)), + default('statement'), + ], + 'statement': [ + include('whitespace'), + include('statements'), + ('[{}]', Punctuation), + (';', Punctuation, '#pop'), + ], + 'function': [ + include('whitespace'), + include('statements'), + (';', Punctuation), + (r'\{', Punctuation, '#push'), + (r'\}', Punctuation, '#pop'), + ], + 'string': [ + (r"'", String, '#pop'), + (r'\\([\\abfnrtv"\'?]|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'\n', String), + (r"[^\\'\n]+", String), # all other characters + (r'\\\n', String), + (r'\\n', String), # line continuation + (r'\\', String), # stray backslash + ], + } + + def get_tokens_unprocessed(self, text): + from pygments.lexers._asy_builtins import ASYFUNCNAME, ASYVARNAME + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text): + if token is Name and value in ASYFUNCNAME: + token = Name.Function + elif token is Name and value in ASYVARNAME: + token = Name.Variable + yield index, token, value + + +def _shortened(word): + dpos = word.find('$') + return '|'.join(word[:dpos] + word[dpos+1:i] + r'\b' + for i in range(len(word), dpos, -1)) + + +def _shortened_many(*words): + return '|'.join(map(_shortened, words)) + + +class GnuplotLexer(RegexLexer): + """ + For `Gnuplot `_ plotting scripts. + + .. versionadded:: 0.11 + """ + + name = 'Gnuplot' + aliases = ['gnuplot'] + filenames = ['*.plot', '*.plt'] + mimetypes = ['text/x-gnuplot'] + + tokens = { + 'root': [ + include('whitespace'), + (_shortened('bi$nd'), Keyword, 'bind'), + (_shortened_many('ex$it', 'q$uit'), Keyword, 'quit'), + (_shortened('f$it'), Keyword, 'fit'), + (r'(if)(\s*)(\()', bygroups(Keyword, Text, Punctuation), 'if'), + (r'else\b', Keyword), + (_shortened('pa$use'), Keyword, 'pause'), + (_shortened_many('p$lot', 'rep$lot', 'sp$lot'), Keyword, 'plot'), + (_shortened('sa$ve'), Keyword, 'save'), + (_shortened('se$t'), Keyword, ('genericargs', 'optionarg')), + (_shortened_many('sh$ow', 'uns$et'), + Keyword, ('noargs', 'optionarg')), + (_shortened_many('low$er', 'ra$ise', 'ca$ll', 'cd$', 'cl$ear', + 'h$elp', '\\?$', 'hi$story', 'l$oad', 'pr$int', + 'pwd$', 're$read', 'res$et', 'scr$eendump', + 'she$ll', 'sy$stem', 'up$date'), + Keyword, 'genericargs'), + (_shortened_many('pwd$', 're$read', 'res$et', 'scr$eendump', + 'she$ll', 'test$'), + Keyword, 'noargs'), + ('([a-zA-Z_]\w*)(\s*)(=)', + bygroups(Name.Variable, Text, Operator), 'genericargs'), + ('([a-zA-Z_]\w*)(\s*\(.*?\)\s*)(=)', + bygroups(Name.Function, Text, Operator), 'genericargs'), + (r'@[a-zA-Z_]\w*', Name.Constant), # macros + (r';', Keyword), + ], + 'comment': [ + (r'[^\\\n]', Comment), + (r'\\\n', Comment), + (r'\\', Comment), + # don't add the newline to the Comment token + default('#pop'), + ], + 'whitespace': [ + ('#', Comment, 'comment'), + (r'[ \t\v\f]+', Text), + ], + 'noargs': [ + include('whitespace'), + # semicolon and newline end the argument list + (r';', Punctuation, '#pop'), + (r'\n', Text, '#pop'), + ], + 'dqstring': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # stray backslash + (r'\n', String, '#pop'), # newline ends the string too + ], + 'sqstring': [ + (r"''", String), # escaped single quote + (r"'", String, '#pop'), + (r"[^\\'\n]+", String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # normal backslash + (r'\n', String, '#pop'), # newline ends the string too + ], + 'genericargs': [ + include('noargs'), + (r'"', String, 'dqstring'), + (r"'", String, 'sqstring'), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+', Number.Float), + (r'(\d+\.\d*|\.\d+)', Number.Float), + (r'-?\d+', Number.Integer), + ('[,.~!%^&*+=|?:<>/-]', Operator), + ('[{}()\[\]]', Punctuation), + (r'(eq|ne)\b', Operator.Word), + (r'([a-zA-Z_]\w*)(\s*)(\()', + bygroups(Name.Function, Text, Punctuation)), + (r'[a-zA-Z_]\w*', Name), + (r'@[a-zA-Z_]\w*', Name.Constant), # macros + (r'\\\n', Text), + ], + 'optionarg': [ + include('whitespace'), + (_shortened_many( + "a$ll", "an$gles", "ar$row", "au$toscale", "b$ars", "bor$der", + "box$width", "cl$abel", "c$lip", "cn$trparam", "co$ntour", "da$ta", + "data$file", "dg$rid3d", "du$mmy", "enc$oding", "dec$imalsign", + "fit$", "font$path", "fo$rmat", "fu$nction", "fu$nctions", "g$rid", + "hid$den3d", "his$torysize", "is$osamples", "k$ey", "keyt$itle", + "la$bel", "li$nestyle", "ls$", "loa$dpath", "loc$ale", "log$scale", + "mac$ros", "map$ping", "map$ping3d", "mar$gin", "lmar$gin", + "rmar$gin", "tmar$gin", "bmar$gin", "mo$use", "multi$plot", + "mxt$ics", "nomxt$ics", "mx2t$ics", "nomx2t$ics", "myt$ics", + "nomyt$ics", "my2t$ics", "nomy2t$ics", "mzt$ics", "nomzt$ics", + "mcbt$ics", "nomcbt$ics", "of$fsets", "or$igin", "o$utput", + "pa$rametric", "pm$3d", "pal$ette", "colorb$ox", "p$lot", + "poi$ntsize", "pol$ar", "pr$int", "obj$ect", "sa$mples", "si$ze", + "st$yle", "su$rface", "table$", "t$erminal", "termo$ptions", "ti$cs", + "ticsc$ale", "ticsl$evel", "timef$mt", "tim$estamp", "tit$le", + "v$ariables", "ve$rsion", "vi$ew", "xyp$lane", "xda$ta", "x2da$ta", + "yda$ta", "y2da$ta", "zda$ta", "cbda$ta", "xl$abel", "x2l$abel", + "yl$abel", "y2l$abel", "zl$abel", "cbl$abel", "xti$cs", "noxti$cs", + "x2ti$cs", "nox2ti$cs", "yti$cs", "noyti$cs", "y2ti$cs", "noy2ti$cs", + "zti$cs", "nozti$cs", "cbti$cs", "nocbti$cs", "xdti$cs", "noxdti$cs", + "x2dti$cs", "nox2dti$cs", "ydti$cs", "noydti$cs", "y2dti$cs", + "noy2dti$cs", "zdti$cs", "nozdti$cs", "cbdti$cs", "nocbdti$cs", + "xmti$cs", "noxmti$cs", "x2mti$cs", "nox2mti$cs", "ymti$cs", + "noymti$cs", "y2mti$cs", "noy2mti$cs", "zmti$cs", "nozmti$cs", + "cbmti$cs", "nocbmti$cs", "xr$ange", "x2r$ange", "yr$ange", + "y2r$ange", "zr$ange", "cbr$ange", "rr$ange", "tr$ange", "ur$ange", + "vr$ange", "xzeroa$xis", "x2zeroa$xis", "yzeroa$xis", "y2zeroa$xis", + "zzeroa$xis", "zeroa$xis", "z$ero"), Name.Builtin, '#pop'), + ], + 'bind': [ + ('!', Keyword, '#pop'), + (_shortened('all$windows'), Name.Builtin), + include('genericargs'), + ], + 'quit': [ + (r'gnuplot\b', Keyword), + include('noargs'), + ], + 'fit': [ + (r'via\b', Name.Builtin), + include('plot'), + ], + 'if': [ + (r'\)', Punctuation, '#pop'), + include('genericargs'), + ], + 'pause': [ + (r'(mouse|any|button1|button2|button3)\b', Name.Builtin), + (_shortened('key$press'), Name.Builtin), + include('genericargs'), + ], + 'plot': [ + (_shortened_many('ax$es', 'axi$s', 'bin$ary', 'ev$ery', 'i$ndex', + 'mat$rix', 's$mooth', 'thru$', 't$itle', + 'not$itle', 'u$sing', 'w$ith'), + Name.Builtin), + include('genericargs'), + ], + 'save': [ + (_shortened_many('f$unctions', 's$et', 't$erminal', 'v$ariables'), + Name.Builtin), + include('genericargs'), + ], + } + + +class PovrayLexer(RegexLexer): + """ + For `Persistence of Vision Raytracer `_ files. + + .. versionadded:: 0.11 + """ + name = 'POVRay' + aliases = ['pov'] + filenames = ['*.pov', '*.inc'] + mimetypes = ['text/x-povray'] + + tokens = { + 'root': [ + (r'/\*[\w\W]*?\*/', Comment.Multiline), + (r'//.*\n', Comment.Single), + (r'(?s)"(?:\\.|[^"\\])+"', String.Double), + (words(( + 'break', 'case', 'debug', 'declare', 'default', 'define', 'else', + 'elseif', 'end', 'error', 'fclose', 'fopen', 'for', 'if', 'ifdef', + 'ifndef', 'include', 'local', 'macro', 'range', 'read', 'render', + 'statistics', 'switch', 'undef', 'version', 'warning', 'while', + 'write'), prefix=r'#', suffix=r'\b'), + Comment.Preproc), + (words(( + 'aa_level', 'aa_threshold', 'abs', 'acos', 'acosh', 'adaptive', 'adc_bailout', + 'agate', 'agate_turb', 'all', 'alpha', 'ambient', 'ambient_light', 'angle', + 'aperture', 'arc_angle', 'area_light', 'asc', 'asin', 'asinh', 'assumed_gamma', + 'atan', 'atan2', 'atanh', 'atmosphere', 'atmospheric_attenuation', + 'attenuating', 'average', 'background', 'black_hole', 'blue', 'blur_samples', + 'bounded_by', 'box_mapping', 'bozo', 'break', 'brick', 'brick_size', + 'brightness', 'brilliance', 'bumps', 'bumpy1', 'bumpy2', 'bumpy3', 'bump_map', + 'bump_size', 'case', 'caustics', 'ceil', 'checker', 'chr', 'clipped_by', 'clock', + 'color', 'color_map', 'colour', 'colour_map', 'component', 'composite', 'concat', + 'confidence', 'conic_sweep', 'constant', 'control0', 'control1', 'cos', 'cosh', + 'count', 'crackle', 'crand', 'cube', 'cubic_spline', 'cylindrical_mapping', + 'debug', 'declare', 'default', 'degrees', 'dents', 'diffuse', 'direction', + 'distance', 'distance_maximum', 'div', 'dust', 'dust_type', 'eccentricity', + 'else', 'emitting', 'end', 'error', 'error_bound', 'exp', 'exponent', + 'fade_distance', 'fade_power', 'falloff', 'falloff_angle', 'false', + 'file_exists', 'filter', 'finish', 'fisheye', 'flatness', 'flip', 'floor', + 'focal_point', 'fog', 'fog_alt', 'fog_offset', 'fog_type', 'frequency', 'gif', + 'global_settings', 'glowing', 'gradient', 'granite', 'gray_threshold', + 'green', 'halo', 'hexagon', 'hf_gray_16', 'hierarchy', 'hollow', 'hypercomplex', + 'if', 'ifdef', 'iff', 'image_map', 'incidence', 'include', 'int', 'interpolate', + 'inverse', 'ior', 'irid', 'irid_wavelength', 'jitter', 'lambda', 'leopard', + 'linear', 'linear_spline', 'linear_sweep', 'location', 'log', 'looks_like', + 'look_at', 'low_error_factor', 'mandel', 'map_type', 'marble', 'material_map', + 'matrix', 'max', 'max_intersections', 'max_iteration', 'max_trace_level', + 'max_value', 'metallic', 'min', 'minimum_reuse', 'mod', 'mortar', + 'nearest_count', 'no', 'normal', 'normal_map', 'no_shadow', 'number_of_waves', + 'octaves', 'off', 'offset', 'omega', 'omnimax', 'on', 'once', 'onion', 'open', + 'orthographic', 'panoramic', 'pattern1', 'pattern2', 'pattern3', + 'perspective', 'pgm', 'phase', 'phong', 'phong_size', 'pi', 'pigment', + 'pigment_map', 'planar_mapping', 'png', 'point_at', 'pot', 'pow', 'ppm', + 'precision', 'pwr', 'quadratic_spline', 'quaternion', 'quick_color', + 'quick_colour', 'quilted', 'radial', 'radians', 'radiosity', 'radius', 'rainbow', + 'ramp_wave', 'rand', 'range', 'reciprocal', 'recursion_limit', 'red', + 'reflection', 'refraction', 'render', 'repeat', 'rgb', 'rgbf', 'rgbft', 'rgbt', + 'right', 'ripples', 'rotate', 'roughness', 'samples', 'scale', 'scallop_wave', + 'scattering', 'seed', 'shadowless', 'sin', 'sine_wave', 'sinh', 'sky', 'sky_sphere', + 'slice', 'slope_map', 'smooth', 'specular', 'spherical_mapping', 'spiral', + 'spiral1', 'spiral2', 'spotlight', 'spotted', 'sqr', 'sqrt', 'statistics', 'str', + 'strcmp', 'strength', 'strlen', 'strlwr', 'strupr', 'sturm', 'substr', 'switch', 'sys', + 't', 'tan', 'tanh', 'test_camera_1', 'test_camera_2', 'test_camera_3', + 'test_camera_4', 'texture', 'texture_map', 'tga', 'thickness', 'threshold', + 'tightness', 'tile2', 'tiles', 'track', 'transform', 'translate', 'transmit', + 'triangle_wave', 'true', 'ttf', 'turbulence', 'turb_depth', 'type', + 'ultra_wide_angle', 'up', 'use_color', 'use_colour', 'use_index', 'u_steps', + 'val', 'variance', 'vaxis_rotate', 'vcross', 'vdot', 'version', 'vlength', + 'vnormalize', 'volume_object', 'volume_rendered', 'vol_with_light', + 'vrotate', 'v_steps', 'warning', 'warp', 'water_level', 'waves', 'while', 'width', + 'wood', 'wrinkles', 'yes'), prefix=r'\b', suffix=r'\b'), + Keyword), + (words(( + 'bicubic_patch', 'blob', 'box', 'camera', 'cone', 'cubic', 'cylinder', 'difference', + 'disc', 'height_field', 'intersection', 'julia_fractal', 'lathe', + 'light_source', 'merge', 'mesh', 'object', 'plane', 'poly', 'polygon', 'prism', + 'quadric', 'quartic', 'smooth_triangle', 'sor', 'sphere', 'superellipsoid', + 'text', 'torus', 'triangle', 'union'), suffix=r'\b'), + Name.Builtin), + # TODO: <=, etc + (r'[\[\](){}<>;,]', Punctuation), + (r'[-+*/=]', Operator), + (r'\b(x|y|z|u|v)\b', Name.Builtin.Pseudo), + (r'[a-zA-Z_]\w*', Name), + (r'[0-9]+\.[0-9]*', Number.Float), + (r'\.[0-9]+', Number.Float), + (r'[0-9]+', Number.Integer), + (r'"(\\\\|\\"|[^"])*"', String), + (r'\s+', Text), + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haskell.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haskell.py new file mode 100644 index 0000000000..089cdf4e6b --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haskell.py @@ -0,0 +1,840 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.haskell + ~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Haskell and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, bygroups, do_insertions, \ + default, include +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Generic +from pygments import unistring as uni + +__all__ = ['HaskellLexer', 'IdrisLexer', 'AgdaLexer', 'CryptolLexer', + 'LiterateHaskellLexer', 'LiterateIdrisLexer', 'LiterateAgdaLexer', + 'LiterateCryptolLexer', 'KokaLexer'] + + +line_re = re.compile('.*?\n') + + +class HaskellLexer(RegexLexer): + """ + A Haskell lexer based on the lexemes defined in the Haskell 98 Report. + + .. versionadded:: 0.8 + """ + name = 'Haskell' + aliases = ['haskell', 'hs'] + filenames = ['*.hs'] + mimetypes = ['text/x-haskell'] + + flags = re.MULTILINE | re.UNICODE + + reserved = ('case', 'class', 'data', 'default', 'deriving', 'do', 'else', + 'if', 'in', 'infix[lr]?', 'instance', + 'let', 'newtype', 'of', 'then', 'type', 'where', '_') + ascii = ('NUL', 'SOH', '[SE]TX', 'EOT', 'ENQ', 'ACK', + 'BEL', 'BS', 'HT', 'LF', 'VT', 'FF', 'CR', 'S[OI]', 'DLE', + 'DC[1-4]', 'NAK', 'SYN', 'ETB', 'CAN', + 'EM', 'SUB', 'ESC', '[FGRU]S', 'SP', 'DEL') + + tokens = { + 'root': [ + # Whitespace: + (r'\s+', Text), + # (r'--\s*|.*$', Comment.Doc), + (r'--(?![!#$%&*+./<=>?@^|_~:\\]).*?$', Comment.Single), + (r'\{-', Comment.Multiline, 'comment'), + # Lexemes: + # Identifiers + (r'\bimport\b', Keyword.Reserved, 'import'), + (r'\bmodule\b', Keyword.Reserved, 'module'), + (r'\berror\b', Name.Exception), + (r'\b(%s)(?!\')\b' % '|'.join(reserved), Keyword.Reserved), + (r"'[^\\]'", String.Char), # this has to come before the TH quote + (r'^[_' + uni.Ll + r'][\w\']*', Name.Function), + (r"'?[_" + uni.Ll + r"][\w']*", Name), + (r"('')?[" + uni.Lu + r"][\w\']*", Keyword.Type), + # Operators + (r'\\(?![:!#$%&*+.\\/<=>?@^|~-]+)', Name.Function), # lambda operator + (r'(<-|::|->|=>|=)(?![:!#$%&*+.\\/<=>?@^|~-]+)', Operator.Word), # specials + (r':[:!#$%&*+.\\/<=>?@^|~-]*', Keyword.Type), # Constructor operators + (r'[:!#$%&*+.\\/<=>?@^|~-]+', Operator), # Other operators + # Numbers + (r'\d+[eE][+-]?\d+', Number.Float), + (r'\d+\.\d+([eE][+-]?\d+)?', Number.Float), + (r'0[oO][0-7]+', Number.Oct), + (r'0[xX][\da-fA-F]+', Number.Hex), + (r'\d+', Number.Integer), + # Character/String Literals + (r"'", String.Char, 'character'), + (r'"', String, 'string'), + # Special + (r'\[\]', Keyword.Type), + (r'\(\)', Name.Builtin), + (r'[][(),;`{}]', Punctuation), + ], + 'import': [ + # Import statements + (r'\s+', Text), + (r'"', String, 'string'), + # after "funclist" state + (r'\)', Punctuation, '#pop'), + (r'qualified\b', Keyword), + # import X as Y + (r'([' + uni.Lu + r'][\w.]*)(\s+)(as)(\s+)([' + uni.Lu + r'][\w.]*)', + bygroups(Name.Namespace, Text, Keyword, Text, Name), '#pop'), + # import X hiding (functions) + (r'([' + uni.Lu + r'][\w.]*)(\s+)(hiding)(\s+)(\()', + bygroups(Name.Namespace, Text, Keyword, Text, Punctuation), 'funclist'), + # import X (functions) + (r'([' + uni.Lu + r'][\w.]*)(\s+)(\()', + bygroups(Name.Namespace, Text, Punctuation), 'funclist'), + # import X + (r'[\w.]+', Name.Namespace, '#pop'), + ], + 'module': [ + (r'\s+', Text), + (r'([' + uni.Lu + r'][\w.]*)(\s+)(\()', + bygroups(Name.Namespace, Text, Punctuation), 'funclist'), + (r'[' + uni.Lu + r'][\w.]*', Name.Namespace, '#pop'), + ], + 'funclist': [ + (r'\s+', Text), + (r'[' + uni.Lu + r']\w*', Keyword.Type), + (r'(_[\w\']+|[' + uni.Ll + r'][\w\']*)', Name.Function), + (r'--(?![!#$%&*+./<=>?@^|_~:\\]).*?$', Comment.Single), + (r'\{-', Comment.Multiline, 'comment'), + (r',', Punctuation), + (r'[:!#$%&*+.\\/<=>?@^|~-]+', Operator), + # (HACK, but it makes sense to push two instances, believe me) + (r'\(', Punctuation, ('funclist', 'funclist')), + (r'\)', Punctuation, '#pop:2'), + ], + # NOTE: the next four states are shared in the AgdaLexer; make sure + # any change is compatible with Agda as well or copy over and change + 'comment': [ + # Multiline Comments + (r'[^-{}]+', Comment.Multiline), + (r'\{-', Comment.Multiline, '#push'), + (r'-\}', Comment.Multiline, '#pop'), + (r'[-{}]', Comment.Multiline), + ], + 'character': [ + # Allows multi-chars, incorrectly. + (r"[^\\']'", String.Char, '#pop'), + (r"\\", String.Escape, 'escape'), + ("'", String.Char, '#pop'), + ], + 'string': [ + (r'[^\\"]+', String), + (r"\\", String.Escape, 'escape'), + ('"', String, '#pop'), + ], + 'escape': [ + (r'[abfnrtv"\'&\\]', String.Escape, '#pop'), + (r'\^[][' + uni.Lu + r'@^_]', String.Escape, '#pop'), + ('|'.join(ascii), String.Escape, '#pop'), + (r'o[0-7]+', String.Escape, '#pop'), + (r'x[\da-fA-F]+', String.Escape, '#pop'), + (r'\d+', String.Escape, '#pop'), + (r'\s+\\', String.Escape, '#pop'), + ], + } + + +class IdrisLexer(RegexLexer): + """ + A lexer for the dependently typed programming language Idris. + + Based on the Haskell and Agda Lexer. + + .. versionadded:: 2.0 + """ + name = 'Idris' + aliases = ['idris', 'idr'] + filenames = ['*.idr'] + mimetypes = ['text/x-idris'] + + reserved = ('case', 'class', 'data', 'default', 'using', 'do', 'else', + 'if', 'in', 'infix[lr]?', 'instance', 'rewrite', 'auto', + 'namespace', 'codata', 'mutual', 'private', 'public', 'abstract', + 'total', 'partial', + 'let', 'proof', 'of', 'then', 'static', 'where', '_', 'with', + 'pattern', 'term', 'syntax', 'prefix', + 'postulate', 'parameters', 'record', 'dsl', 'impossible', 'implicit', + 'tactics', 'intros', 'intro', 'compute', 'refine', 'exact', 'trivial') + + ascii = ('NUL', 'SOH', '[SE]TX', 'EOT', 'ENQ', 'ACK', + 'BEL', 'BS', 'HT', 'LF', 'VT', 'FF', 'CR', 'S[OI]', 'DLE', + 'DC[1-4]', 'NAK', 'SYN', 'ETB', 'CAN', + 'EM', 'SUB', 'ESC', '[FGRU]S', 'SP', 'DEL') + + directives = ('lib', 'link', 'flag', 'include', 'hide', 'freeze', 'access', + 'default', 'logging', 'dynamic', 'name', 'error_handlers', 'language') + + tokens = { + 'root': [ + # Comments + (r'^(\s*)(%%%s)' % '|'.join(directives), + bygroups(Text, Keyword.Reserved)), + (r'(\s*)(--(?![!#$%&*+./<=>?@^|_~:\\]).*?)$', bygroups(Text, Comment.Single)), + (r'(\s*)(\|{3}.*?)$', bygroups(Text, Comment.Single)), + (r'(\s*)(\{-)', bygroups(Text, Comment.Multiline), 'comment'), + # Declaration + (r'^(\s*)([^\s(){}]+)(\s*)(:)(\s*)', + bygroups(Text, Name.Function, Text, Operator.Word, Text)), + # Identifiers + (r'\b(%s)(?!\')\b' % '|'.join(reserved), Keyword.Reserved), + (r'(import|module)(\s+)', bygroups(Keyword.Reserved, Text), 'module'), + (r"('')?[A-Z][\w\']*", Keyword.Type), + (r'[a-z][\w\']*', Text), + # Special Symbols + (r'(<-|::|->|=>|=)', Operator.Word), # specials + (r'([(){}\[\]:!#$%&*+.\\/<=>?@^|~-]+)', Operator.Word), # specials + # Numbers + (r'\d+[eE][+-]?\d+', Number.Float), + (r'\d+\.\d+([eE][+-]?\d+)?', Number.Float), + (r'0[xX][\da-fA-F]+', Number.Hex), + (r'\d+', Number.Integer), + # Strings + (r"'", String.Char, 'character'), + (r'"', String, 'string'), + (r'[^\s(){}]+', Text), + (r'\s+?', Text), # Whitespace + ], + 'module': [ + (r'\s+', Text), + (r'([A-Z][\w.]*)(\s+)(\()', + bygroups(Name.Namespace, Text, Punctuation), 'funclist'), + (r'[A-Z][\w.]*', Name.Namespace, '#pop'), + ], + 'funclist': [ + (r'\s+', Text), + (r'[A-Z]\w*', Keyword.Type), + (r'(_[\w\']+|[a-z][\w\']*)', Name.Function), + (r'--.*$', Comment.Single), + (r'\{-', Comment.Multiline, 'comment'), + (r',', Punctuation), + (r'[:!#$%&*+.\\/<=>?@^|~-]+', Operator), + # (HACK, but it makes sense to push two instances, believe me) + (r'\(', Punctuation, ('funclist', 'funclist')), + (r'\)', Punctuation, '#pop:2'), + ], + # NOTE: the next four states are shared in the AgdaLexer; make sure + # any change is compatible with Agda as well or copy over and change + 'comment': [ + # Multiline Comments + (r'[^-{}]+', Comment.Multiline), + (r'\{-', Comment.Multiline, '#push'), + (r'-\}', Comment.Multiline, '#pop'), + (r'[-{}]', Comment.Multiline), + ], + 'character': [ + # Allows multi-chars, incorrectly. + (r"[^\\']", String.Char), + (r"\\", String.Escape, 'escape'), + ("'", String.Char, '#pop'), + ], + 'string': [ + (r'[^\\"]+', String), + (r"\\", String.Escape, 'escape'), + ('"', String, '#pop'), + ], + 'escape': [ + (r'[abfnrtv"\'&\\]', String.Escape, '#pop'), + (r'\^[][A-Z@^_]', String.Escape, '#pop'), + ('|'.join(ascii), String.Escape, '#pop'), + (r'o[0-7]+', String.Escape, '#pop'), + (r'x[\da-fA-F]+', String.Escape, '#pop'), + (r'\d+', String.Escape, '#pop'), + (r'\s+\\', String.Escape, '#pop') + ], + } + + +class AgdaLexer(RegexLexer): + """ + For the `Agda `_ + dependently typed functional programming language and proof assistant. + + .. versionadded:: 2.0 + """ + + name = 'Agda' + aliases = ['agda'] + filenames = ['*.agda'] + mimetypes = ['text/x-agda'] + + reserved = ['abstract', 'codata', 'coinductive', 'constructor', 'data', + 'field', 'forall', 'hiding', 'in', 'inductive', 'infix', + 'infixl', 'infixr', 'instance', 'let', 'mutual', 'open', + 'pattern', 'postulate', 'primitive', 'private', + 'quote', 'quoteGoal', 'quoteTerm', + 'record', 'renaming', 'rewrite', 'syntax', 'tactic', + 'unquote', 'unquoteDecl', 'using', 'where', 'with'] + + tokens = { + 'root': [ + # Declaration + (r'^(\s*)([^\s(){}]+)(\s*)(:)(\s*)', + bygroups(Text, Name.Function, Text, Operator.Word, Text)), + # Comments + (r'--(?![!#$%&*+./<=>?@^|_~:\\]).*?$', Comment.Single), + (r'\{-', Comment.Multiline, 'comment'), + # Holes + (r'\{!', Comment.Directive, 'hole'), + # Lexemes: + # Identifiers + (r'\b(%s)(?!\')\b' % '|'.join(reserved), Keyword.Reserved), + (r'(import|module)(\s+)', bygroups(Keyword.Reserved, Text), 'module'), + (r'\b(Set|Prop)\b', Keyword.Type), + # Special Symbols + (r'(\(|\)|\{|\})', Operator), + (u'(\\.{1,3}|\\||\u039B|\u2200|\u2192|:|=|->)', Operator.Word), + # Numbers + (r'\d+[eE][+-]?\d+', Number.Float), + (r'\d+\.\d+([eE][+-]?\d+)?', Number.Float), + (r'0[xX][\da-fA-F]+', Number.Hex), + (r'\d+', Number.Integer), + # Strings + (r"'", String.Char, 'character'), + (r'"', String, 'string'), + (r'[^\s(){}]+', Text), + (r'\s+?', Text), # Whitespace + ], + 'hole': [ + # Holes + (r'[^!{}]+', Comment.Directive), + (r'\{!', Comment.Directive, '#push'), + (r'!\}', Comment.Directive, '#pop'), + (r'[!{}]', Comment.Directive), + ], + 'module': [ + (r'\{-', Comment.Multiline, 'comment'), + (r'[a-zA-Z][\w.]*', Name, '#pop'), + (r'[^a-zA-Z]+', Text) + ], + 'comment': HaskellLexer.tokens['comment'], + 'character': HaskellLexer.tokens['character'], + 'string': HaskellLexer.tokens['string'], + 'escape': HaskellLexer.tokens['escape'] + } + + +class CryptolLexer(RegexLexer): + """ + FIXME: A Cryptol2 lexer based on the lexemes defined in the Haskell 98 Report. + + .. versionadded:: 2.0 + """ + name = 'Cryptol' + aliases = ['cryptol', 'cry'] + filenames = ['*.cry'] + mimetypes = ['text/x-cryptol'] + + reserved = ('Arith', 'Bit', 'Cmp', 'False', 'Inf', 'True', 'else', + 'export', 'extern', 'fin', 'if', 'import', 'inf', 'lg2', + 'max', 'min', 'module', 'newtype', 'pragma', 'property', + 'then', 'type', 'where', 'width') + ascii = ('NUL', 'SOH', '[SE]TX', 'EOT', 'ENQ', 'ACK', + 'BEL', 'BS', 'HT', 'LF', 'VT', 'FF', 'CR', 'S[OI]', 'DLE', + 'DC[1-4]', 'NAK', 'SYN', 'ETB', 'CAN', + 'EM', 'SUB', 'ESC', '[FGRU]S', 'SP', 'DEL') + + tokens = { + 'root': [ + # Whitespace: + (r'\s+', Text), + # (r'--\s*|.*$', Comment.Doc), + (r'//.*$', Comment.Single), + (r'/\*', Comment.Multiline, 'comment'), + # Lexemes: + # Identifiers + (r'\bimport\b', Keyword.Reserved, 'import'), + (r'\bmodule\b', Keyword.Reserved, 'module'), + (r'\berror\b', Name.Exception), + (r'\b(%s)(?!\')\b' % '|'.join(reserved), Keyword.Reserved), + (r'^[_a-z][\w\']*', Name.Function), + (r"'?[_a-z][\w']*", Name), + (r"('')?[A-Z][\w\']*", Keyword.Type), + # Operators + (r'\\(?![:!#$%&*+.\\/<=>?@^|~-]+)', Name.Function), # lambda operator + (r'(<-|::|->|=>|=)(?![:!#$%&*+.\\/<=>?@^|~-]+)', Operator.Word), # specials + (r':[:!#$%&*+.\\/<=>?@^|~-]*', Keyword.Type), # Constructor operators + (r'[:!#$%&*+.\\/<=>?@^|~-]+', Operator), # Other operators + # Numbers + (r'\d+[eE][+-]?\d+', Number.Float), + (r'\d+\.\d+([eE][+-]?\d+)?', Number.Float), + (r'0[oO][0-7]+', Number.Oct), + (r'0[xX][\da-fA-F]+', Number.Hex), + (r'\d+', Number.Integer), + # Character/String Literals + (r"'", String.Char, 'character'), + (r'"', String, 'string'), + # Special + (r'\[\]', Keyword.Type), + (r'\(\)', Name.Builtin), + (r'[][(),;`{}]', Punctuation), + ], + 'import': [ + # Import statements + (r'\s+', Text), + (r'"', String, 'string'), + # after "funclist" state + (r'\)', Punctuation, '#pop'), + (r'qualified\b', Keyword), + # import X as Y + (r'([A-Z][\w.]*)(\s+)(as)(\s+)([A-Z][\w.]*)', + bygroups(Name.Namespace, Text, Keyword, Text, Name), '#pop'), + # import X hiding (functions) + (r'([A-Z][\w.]*)(\s+)(hiding)(\s+)(\()', + bygroups(Name.Namespace, Text, Keyword, Text, Punctuation), 'funclist'), + # import X (functions) + (r'([A-Z][\w.]*)(\s+)(\()', + bygroups(Name.Namespace, Text, Punctuation), 'funclist'), + # import X + (r'[\w.]+', Name.Namespace, '#pop'), + ], + 'module': [ + (r'\s+', Text), + (r'([A-Z][\w.]*)(\s+)(\()', + bygroups(Name.Namespace, Text, Punctuation), 'funclist'), + (r'[A-Z][\w.]*', Name.Namespace, '#pop'), + ], + 'funclist': [ + (r'\s+', Text), + (r'[A-Z]\w*', Keyword.Type), + (r'(_[\w\']+|[a-z][\w\']*)', Name.Function), + # TODO: these don't match the comments in docs, remove. + #(r'--(?![!#$%&*+./<=>?@^|_~:\\]).*?$', Comment.Single), + #(r'{-', Comment.Multiline, 'comment'), + (r',', Punctuation), + (r'[:!#$%&*+.\\/<=>?@^|~-]+', Operator), + # (HACK, but it makes sense to push two instances, believe me) + (r'\(', Punctuation, ('funclist', 'funclist')), + (r'\)', Punctuation, '#pop:2'), + ], + 'comment': [ + # Multiline Comments + (r'[^/*]+', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline), + ], + 'character': [ + # Allows multi-chars, incorrectly. + (r"[^\\']'", String.Char, '#pop'), + (r"\\", String.Escape, 'escape'), + ("'", String.Char, '#pop'), + ], + 'string': [ + (r'[^\\"]+', String), + (r"\\", String.Escape, 'escape'), + ('"', String, '#pop'), + ], + 'escape': [ + (r'[abfnrtv"\'&\\]', String.Escape, '#pop'), + (r'\^[][A-Z@^_]', String.Escape, '#pop'), + ('|'.join(ascii), String.Escape, '#pop'), + (r'o[0-7]+', String.Escape, '#pop'), + (r'x[\da-fA-F]+', String.Escape, '#pop'), + (r'\d+', String.Escape, '#pop'), + (r'\s+\\', String.Escape, '#pop'), + ], + } + + EXTRA_KEYWORDS = set(('join', 'split', 'reverse', 'transpose', 'width', + 'length', 'tail', '<<', '>>', '<<<', '>>>', 'const', + 'reg', 'par', 'seq', 'ASSERT', 'undefined', 'error', + 'trace')) + + def get_tokens_unprocessed(self, text): + stack = ['root'] + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text, stack): + if token is Name and value in self.EXTRA_KEYWORDS: + yield index, Name.Builtin, value + else: + yield index, token, value + + +class LiterateLexer(Lexer): + """ + Base class for lexers of literate file formats based on LaTeX or Bird-style + (prefixing each code line with ">"). + + Additional options accepted: + + `litstyle` + If given, must be ``"bird"`` or ``"latex"``. If not given, the style + is autodetected: if the first non-whitespace character in the source + is a backslash or percent character, LaTeX is assumed, else Bird. + """ + + bird_re = re.compile(r'(>[ \t]*)(.*\n)') + + def __init__(self, baselexer, **options): + self.baselexer = baselexer + Lexer.__init__(self, **options) + + def get_tokens_unprocessed(self, text): + style = self.options.get('litstyle') + if style is None: + style = (text.lstrip()[0:1] in '%\\') and 'latex' or 'bird' + + code = '' + insertions = [] + if style == 'bird': + # bird-style + for match in line_re.finditer(text): + line = match.group() + m = self.bird_re.match(line) + if m: + insertions.append((len(code), + [(0, Comment.Special, m.group(1))])) + code += m.group(2) + else: + insertions.append((len(code), [(0, Text, line)])) + else: + # latex-style + from pygments.lexers.markup import TexLexer + lxlexer = TexLexer(**self.options) + codelines = 0 + latex = '' + for match in line_re.finditer(text): + line = match.group() + if codelines: + if line.lstrip().startswith('\\end{code}'): + codelines = 0 + latex += line + else: + code += line + elif line.lstrip().startswith('\\begin{code}'): + codelines = 1 + latex += line + insertions.append((len(code), + list(lxlexer.get_tokens_unprocessed(latex)))) + latex = '' + else: + latex += line + insertions.append((len(code), + list(lxlexer.get_tokens_unprocessed(latex)))) + for item in do_insertions(insertions, self.baselexer.get_tokens_unprocessed(code)): + yield item + + +class LiterateHaskellLexer(LiterateLexer): + """ + For Literate Haskell (Bird-style or LaTeX) source. + + Additional options accepted: + + `litstyle` + If given, must be ``"bird"`` or ``"latex"``. If not given, the style + is autodetected: if the first non-whitespace character in the source + is a backslash or percent character, LaTeX is assumed, else Bird. + + .. versionadded:: 0.9 + """ + name = 'Literate Haskell' + aliases = ['lhs', 'literate-haskell', 'lhaskell'] + filenames = ['*.lhs'] + mimetypes = ['text/x-literate-haskell'] + + def __init__(self, **options): + hslexer = HaskellLexer(**options) + LiterateLexer.__init__(self, hslexer, **options) + + +class LiterateIdrisLexer(LiterateLexer): + """ + For Literate Idris (Bird-style or LaTeX) source. + + Additional options accepted: + + `litstyle` + If given, must be ``"bird"`` or ``"latex"``. If not given, the style + is autodetected: if the first non-whitespace character in the source + is a backslash or percent character, LaTeX is assumed, else Bird. + + .. versionadded:: 2.0 + """ + name = 'Literate Idris' + aliases = ['lidr', 'literate-idris', 'lidris'] + filenames = ['*.lidr'] + mimetypes = ['text/x-literate-idris'] + + def __init__(self, **options): + hslexer = IdrisLexer(**options) + LiterateLexer.__init__(self, hslexer, **options) + + +class LiterateAgdaLexer(LiterateLexer): + """ + For Literate Agda source. + + Additional options accepted: + + `litstyle` + If given, must be ``"bird"`` or ``"latex"``. If not given, the style + is autodetected: if the first non-whitespace character in the source + is a backslash or percent character, LaTeX is assumed, else Bird. + + .. versionadded:: 2.0 + """ + name = 'Literate Agda' + aliases = ['lagda', 'literate-agda'] + filenames = ['*.lagda'] + mimetypes = ['text/x-literate-agda'] + + def __init__(self, **options): + agdalexer = AgdaLexer(**options) + LiterateLexer.__init__(self, agdalexer, litstyle='latex', **options) + + +class LiterateCryptolLexer(LiterateLexer): + """ + For Literate Cryptol (Bird-style or LaTeX) source. + + Additional options accepted: + + `litstyle` + If given, must be ``"bird"`` or ``"latex"``. If not given, the style + is autodetected: if the first non-whitespace character in the source + is a backslash or percent character, LaTeX is assumed, else Bird. + + .. versionadded:: 2.0 + """ + name = 'Literate Cryptol' + aliases = ['lcry', 'literate-cryptol', 'lcryptol'] + filenames = ['*.lcry'] + mimetypes = ['text/x-literate-cryptol'] + + def __init__(self, **options): + crylexer = CryptolLexer(**options) + LiterateLexer.__init__(self, crylexer, **options) + + +class KokaLexer(RegexLexer): + """ + Lexer for the `Koka `_ + language. + + .. versionadded:: 1.6 + """ + + name = 'Koka' + aliases = ['koka'] + filenames = ['*.kk', '*.kki'] + mimetypes = ['text/x-koka'] + + keywords = [ + 'infix', 'infixr', 'infixl', + 'type', 'cotype', 'rectype', 'alias', + 'struct', 'con', + 'fun', 'function', 'val', 'var', + 'external', + 'if', 'then', 'else', 'elif', 'return', 'match', + 'private', 'public', 'private', + 'module', 'import', 'as', + 'include', 'inline', + 'rec', + 'try', 'yield', 'enum', + 'interface', 'instance', + ] + + # keywords that are followed by a type + typeStartKeywords = [ + 'type', 'cotype', 'rectype', 'alias', 'struct', 'enum', + ] + + # keywords valid in a type + typekeywords = [ + 'forall', 'exists', 'some', 'with', + ] + + # builtin names and special names + builtin = [ + 'for', 'while', 'repeat', + 'foreach', 'foreach-indexed', + 'error', 'catch', 'finally', + 'cs', 'js', 'file', 'ref', 'assigned', + ] + + # symbols that can be in an operator + symbols = r'[$%&*+@!/\\^~=.:\-?|<>]+' + + # symbol boundary: an operator keyword should not be followed by any of these + sboundary = '(?!'+symbols+')' + + # name boundary: a keyword should not be followed by any of these + boundary = '(?![\w/])' + + # koka token abstractions + tokenType = Name.Attribute + tokenTypeDef = Name.Class + tokenConstructor = Generic.Emph + + # main lexer + tokens = { + 'root': [ + include('whitespace'), + + # go into type mode + (r'::?' + sboundary, tokenType, 'type'), + (r'(alias)(\s+)([a-z]\w*)?', bygroups(Keyword, Text, tokenTypeDef), + 'alias-type'), + (r'(struct)(\s+)([a-z]\w*)?', bygroups(Keyword, Text, tokenTypeDef), + 'struct-type'), + ((r'(%s)' % '|'.join(typeStartKeywords)) + + r'(\s+)([a-z]\w*)?', bygroups(Keyword, Text, tokenTypeDef), + 'type'), + + # special sequences of tokens (we use ?: for non-capturing group as + # required by 'bygroups') + (r'(module)(\s+)(interface\s+)?((?:[a-z]\w*/)*[a-z]\w*)', + bygroups(Keyword, Text, Keyword, Name.Namespace)), + (r'(import)(\s+)((?:[a-z]\w*/)*[a-z]\w*)' + r'(?:(\s*)(=)(\s*)((?:qualified\s*)?)' + r'((?:[a-z]\w*/)*[a-z]\w*))?', + bygroups(Keyword, Text, Name.Namespace, Text, Keyword, Text, + Keyword, Name.Namespace)), + + (r'(^(?:(?:public|private)\s*)?(?:function|fun|val))' + r'(\s+)([a-z]\w*|\((?:' + symbols + r'|/)\))', + bygroups(Keyword, Text, Name.Function)), + (r'(^(?:(?:public|private)\s*)?external)(\s+)(inline\s+)?' + r'([a-z]\w*|\((?:' + symbols + r'|/)\))', + bygroups(Keyword, Text, Keyword, Name.Function)), + + # keywords + (r'(%s)' % '|'.join(typekeywords) + boundary, Keyword.Type), + (r'(%s)' % '|'.join(keywords) + boundary, Keyword), + (r'(%s)' % '|'.join(builtin) + boundary, Keyword.Pseudo), + (r'::?|:=|\->|[=.]' + sboundary, Keyword), + + # names + (r'((?:[a-z]\w*/)*)([A-Z]\w*)', + bygroups(Name.Namespace, tokenConstructor)), + (r'((?:[a-z]\w*/)*)([a-z]\w*)', bygroups(Name.Namespace, Name)), + (r'((?:[a-z]\w*/)*)(\((?:' + symbols + r'|/)\))', + bygroups(Name.Namespace, Name)), + (r'_\w*', Name.Variable), + + # literal string + (r'@"', String.Double, 'litstring'), + + # operators + (symbols + "|/(?![*/])", Operator), + (r'`', Operator), + (r'[{}()\[\];,]', Punctuation), + + # literals. No check for literal characters with len > 1 + (r'[0-9]+\.[0-9]+([eE][\-+]?[0-9]+)?', Number.Float), + (r'0[xX][0-9a-fA-F]+', Number.Hex), + (r'[0-9]+', Number.Integer), + + (r"'", String.Char, 'char'), + (r'"', String.Double, 'string'), + ], + + # type started by alias + 'alias-type': [ + (r'=', Keyword), + include('type') + ], + + # type started by struct + 'struct-type': [ + (r'(?=\((?!,*\)))', Punctuation, '#pop'), + include('type') + ], + + # type started by colon + 'type': [ + (r'[(\[<]', tokenType, 'type-nested'), + include('type-content') + ], + + # type nested in brackets: can contain parameters, comma etc. + 'type-nested': [ + (r'[)\]>]', tokenType, '#pop'), + (r'[(\[<]', tokenType, 'type-nested'), + (r',', tokenType), + (r'([a-z]\w*)(\s*)(:)(?!:)', + bygroups(Name, Text, tokenType)), # parameter name + include('type-content') + ], + + # shared contents of a type + 'type-content': [ + include('whitespace'), + + # keywords + (r'(%s)' % '|'.join(typekeywords) + boundary, Keyword), + (r'(?=((%s)' % '|'.join(keywords) + boundary + '))', + Keyword, '#pop'), # need to match because names overlap... + + # kinds + (r'[EPHVX]' + boundary, tokenType), + + # type names + (r'[a-z][0-9]*(?![\w/])', tokenType), + (r'_\w*', tokenType.Variable), # Generic.Emph + (r'((?:[a-z]\w*/)*)([A-Z]\w*)', + bygroups(Name.Namespace, tokenType)), + (r'((?:[a-z]\w*/)*)([a-z]\w+)', + bygroups(Name.Namespace, tokenType)), + + # type keyword operators + (r'::|->|[.:|]', tokenType), + + # catchall + default('#pop') + ], + + # comments and literals + 'whitespace': [ + (r'\n\s*#.*$', Comment.Preproc), + (r'\s+', Text), + (r'/\*', Comment.Multiline, 'comment'), + (r'//.*$', Comment.Single) + ], + 'comment': [ + (r'[^/*]+', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline), + ], + 'litstring': [ + (r'[^"]+', String.Double), + (r'""', String.Escape), + (r'"', String.Double, '#pop'), + ], + 'string': [ + (r'[^\\"\n]+', String.Double), + include('escape-sequence'), + (r'["\n]', String.Double, '#pop'), + ], + 'char': [ + (r'[^\\\'\n]+', String.Char), + include('escape-sequence'), + (r'[\'\n]', String.Char, '#pop'), + ], + 'escape-sequence': [ + (r'\\[nrt\\"\']', String.Escape), + (r'\\x[0-9a-fA-F]{2}', String.Escape), + (r'\\u[0-9a-fA-F]{4}', String.Escape), + # Yes, \U literals are 6 hex digits. + (r'\\U[0-9a-fA-F]{6}', String.Escape) + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haxe.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haxe.py new file mode 100644 index 0000000000..69c0adda23 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/haxe.py @@ -0,0 +1,936 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.haxe + ~~~~~~~~~~~~~~~~~~~~ + + Lexers for Haxe and related stuff. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import ExtendedRegexLexer, RegexLexer, include, bygroups, \ + default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Generic, Whitespace + +__all__ = ['HaxeLexer', 'HxmlLexer'] + + +class HaxeLexer(ExtendedRegexLexer): + """ + For Haxe source code (http://haxe.org/). + + .. versionadded:: 1.3 + """ + + name = 'Haxe' + aliases = ['hx', 'haxe', 'hxsl'] + filenames = ['*.hx', '*.hxsl'] + mimetypes = ['text/haxe', 'text/x-haxe', 'text/x-hx'] + + # keywords extracted from lexer.mll in the haxe compiler source + keyword = (r'(?:function|class|static|var|if|else|while|do|for|' + r'break|return|continue|extends|implements|import|' + r'switch|case|default|public|private|try|untyped|' + r'catch|new|this|throw|extern|enum|in|interface|' + r'cast|override|dynamic|typedef|package|' + r'inline|using|null|true|false|abstract)\b') + + # idtype in lexer.mll + typeid = r'_*[A-Z]\w*' + + # combined ident and dollar and idtype + ident = r'(?:_*[a-z]\w*|_+[0-9]\w*|' + typeid + '|_+|\$\w+)' + + binop = (r'(?:%=|&=|\|=|\^=|\+=|\-=|\*=|/=|<<=|>\s*>\s*=|>\s*>\s*>\s*=|==|' + r'!=|<=|>\s*=|&&|\|\||<<|>>>|>\s*>|\.\.\.|<|>|%|&|\||\^|\+|\*|' + r'/|\-|=>|=)') + + # ident except keywords + ident_no_keyword = r'(?!' + keyword + ')' + ident + + flags = re.DOTALL | re.MULTILINE + + preproc_stack = [] + + def preproc_callback(self, match, ctx): + proc = match.group(2) + + if proc == 'if': + # store the current stack + self.preproc_stack.append(ctx.stack[:]) + elif proc in ['else', 'elseif']: + # restore the stack back to right before #if + if self.preproc_stack: + ctx.stack = self.preproc_stack[-1][:] + elif proc == 'end': + # remove the saved stack of previous #if + if self.preproc_stack: + self.preproc_stack.pop() + + # #if and #elseif should follow by an expr + if proc in ['if', 'elseif']: + ctx.stack.append('preproc-expr') + + # #error can be optionally follow by the error msg + if proc in ['error']: + ctx.stack.append('preproc-error') + + yield match.start(), Comment.Preproc, '#' + proc + ctx.pos = match.end() + + tokens = { + 'root': [ + include('spaces'), + include('meta'), + (r'(?:package)\b', Keyword.Namespace, ('semicolon', 'package')), + (r'(?:import)\b', Keyword.Namespace, ('semicolon', 'import')), + (r'(?:using)\b', Keyword.Namespace, ('semicolon', 'using')), + (r'(?:extern|private)\b', Keyword.Declaration), + (r'(?:abstract)\b', Keyword.Declaration, 'abstract'), + (r'(?:class|interface)\b', Keyword.Declaration, 'class'), + (r'(?:enum)\b', Keyword.Declaration, 'enum'), + (r'(?:typedef)\b', Keyword.Declaration, 'typedef'), + + # top-level expression + # although it is not supported in haxe, but it is common to write + # expression in web pages the positive lookahead here is to prevent + # an infinite loop at the EOF + (r'(?=.)', Text, 'expr-statement'), + ], + + # space/tab/comment/preproc + 'spaces': [ + (r'\s+', Text), + (r'//[^\n\r]*', Comment.Single), + (r'/\*.*?\*/', Comment.Multiline), + (r'(#)(if|elseif|else|end|error)\b', preproc_callback), + ], + + 'string-single-interpol': [ + (r'\$\{', String.Interpol, ('string-interpol-close', 'expr')), + (r'\$\$', String.Escape), + (r'\$(?=' + ident + ')', String.Interpol, 'ident'), + include('string-single'), + ], + + 'string-single': [ + (r"'", String.Single, '#pop'), + (r'\\.', String.Escape), + (r'.', String.Single), + ], + + 'string-double': [ + (r'"', String.Double, '#pop'), + (r'\\.', String.Escape), + (r'.', String.Double), + ], + + 'string-interpol-close': [ + (r'\$'+ident, String.Interpol), + (r'\}', String.Interpol, '#pop'), + ], + + 'package': [ + include('spaces'), + (ident, Name.Namespace), + (r'\.', Punctuation, 'import-ident'), + default('#pop'), + ], + + 'import': [ + include('spaces'), + (ident, Name.Namespace), + (r'\*', Keyword), # wildcard import + (r'\.', Punctuation, 'import-ident'), + (r'in', Keyword.Namespace, 'ident'), + default('#pop'), + ], + + 'import-ident': [ + include('spaces'), + (r'\*', Keyword, '#pop'), # wildcard import + (ident, Name.Namespace, '#pop'), + ], + + 'using': [ + include('spaces'), + (ident, Name.Namespace), + (r'\.', Punctuation, 'import-ident'), + default('#pop'), + ], + + 'preproc-error': [ + (r'\s+', Comment.Preproc), + (r"'", String.Single, ('#pop', 'string-single')), + (r'"', String.Double, ('#pop', 'string-double')), + default('#pop'), + ], + + 'preproc-expr': [ + (r'\s+', Comment.Preproc), + (r'\!', Comment.Preproc), + (r'\(', Comment.Preproc, ('#pop', 'preproc-parenthesis')), + + (ident, Comment.Preproc, '#pop'), + + # Float + (r'\.[0-9]+', Number.Float), + (r'[0-9]+[eE][+\-]?[0-9]+', Number.Float), + (r'[0-9]+\.[0-9]*[eE][+\-]?[0-9]+', Number.Float), + (r'[0-9]+\.[0-9]+', Number.Float), + (r'[0-9]+\.(?!' + ident + '|\.\.)', Number.Float), + + # Int + (r'0x[0-9a-fA-F]+', Number.Hex), + (r'[0-9]+', Number.Integer), + + # String + (r"'", String.Single, ('#pop', 'string-single')), + (r'"', String.Double, ('#pop', 'string-double')), + ], + + 'preproc-parenthesis': [ + (r'\s+', Comment.Preproc), + (r'\)', Comment.Preproc, '#pop'), + default('preproc-expr-in-parenthesis'), + ], + + 'preproc-expr-chain': [ + (r'\s+', Comment.Preproc), + (binop, Comment.Preproc, ('#pop', 'preproc-expr-in-parenthesis')), + default('#pop'), + ], + + # same as 'preproc-expr' but able to chain 'preproc-expr-chain' + 'preproc-expr-in-parenthesis': [ + (r'\s+', Comment.Preproc), + (r'\!', Comment.Preproc), + (r'\(', Comment.Preproc, + ('#pop', 'preproc-expr-chain', 'preproc-parenthesis')), + + (ident, Comment.Preproc, ('#pop', 'preproc-expr-chain')), + + # Float + (r'\.[0-9]+', Number.Float, ('#pop', 'preproc-expr-chain')), + (r'[0-9]+[eE][+\-]?[0-9]+', Number.Float, ('#pop', 'preproc-expr-chain')), + (r'[0-9]+\.[0-9]*[eE][+\-]?[0-9]+', Number.Float, ('#pop', 'preproc-expr-chain')), + (r'[0-9]+\.[0-9]+', Number.Float, ('#pop', 'preproc-expr-chain')), + (r'[0-9]+\.(?!' + ident + '|\.\.)', Number.Float, ('#pop', 'preproc-expr-chain')), + + # Int + (r'0x[0-9a-fA-F]+', Number.Hex, ('#pop', 'preproc-expr-chain')), + (r'[0-9]+', Number.Integer, ('#pop', 'preproc-expr-chain')), + + # String + (r"'", String.Single, + ('#pop', 'preproc-expr-chain', 'string-single')), + (r'"', String.Double, + ('#pop', 'preproc-expr-chain', 'string-double')), + ], + + 'abstract': [ + include('spaces'), + default(('#pop', 'abstract-body', 'abstract-relation', + 'abstract-opaque', 'type-param-constraint', 'type-name')), + ], + + 'abstract-body': [ + include('spaces'), + (r'\{', Punctuation, ('#pop', 'class-body')), + ], + + 'abstract-opaque': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'parenthesis-close', 'type')), + default('#pop'), + ], + + 'abstract-relation': [ + include('spaces'), + (r'(?:to|from)', Keyword.Declaration, 'type'), + (r',', Punctuation), + default('#pop'), + ], + + 'meta': [ + include('spaces'), + (r'@', Name.Decorator, ('meta-body', 'meta-ident', 'meta-colon')), + ], + + # optional colon + 'meta-colon': [ + include('spaces'), + (r':', Name.Decorator, '#pop'), + default('#pop'), + ], + + # same as 'ident' but set token as Name.Decorator instead of Name + 'meta-ident': [ + include('spaces'), + (ident, Name.Decorator, '#pop'), + ], + + 'meta-body': [ + include('spaces'), + (r'\(', Name.Decorator, ('#pop', 'meta-call')), + default('#pop'), + ], + + 'meta-call': [ + include('spaces'), + (r'\)', Name.Decorator, '#pop'), + default(('#pop', 'meta-call-sep', 'expr')), + ], + + 'meta-call-sep': [ + include('spaces'), + (r'\)', Name.Decorator, '#pop'), + (r',', Punctuation, ('#pop', 'meta-call')), + ], + + 'typedef': [ + include('spaces'), + default(('#pop', 'typedef-body', 'type-param-constraint', + 'type-name')), + ], + + 'typedef-body': [ + include('spaces'), + (r'=', Operator, ('#pop', 'optional-semicolon', 'type')), + ], + + 'enum': [ + include('spaces'), + default(('#pop', 'enum-body', 'bracket-open', + 'type-param-constraint', 'type-name')), + ], + + 'enum-body': [ + include('spaces'), + include('meta'), + (r'\}', Punctuation, '#pop'), + (ident_no_keyword, Name, ('enum-member', 'type-param-constraint')), + ], + + 'enum-member': [ + include('spaces'), + (r'\(', Punctuation, + ('#pop', 'semicolon', 'flag', 'function-param')), + default(('#pop', 'semicolon', 'flag')), + ], + + 'class': [ + include('spaces'), + default(('#pop', 'class-body', 'bracket-open', 'extends', + 'type-param-constraint', 'type-name')), + ], + + 'extends': [ + include('spaces'), + (r'(?:extends|implements)\b', Keyword.Declaration, 'type'), + (r',', Punctuation), # the comma is made optional here, since haxe2 + # requires the comma but haxe3 does not allow it + default('#pop'), + ], + + 'bracket-open': [ + include('spaces'), + (r'\{', Punctuation, '#pop'), + ], + + 'bracket-close': [ + include('spaces'), + (r'\}', Punctuation, '#pop'), + ], + + 'class-body': [ + include('spaces'), + include('meta'), + (r'\}', Punctuation, '#pop'), + (r'(?:static|public|private|override|dynamic|inline|macro)\b', + Keyword.Declaration), + default('class-member'), + ], + + 'class-member': [ + include('spaces'), + (r'(var)\b', Keyword.Declaration, + ('#pop', 'optional-semicolon', 'var')), + (r'(function)\b', Keyword.Declaration, + ('#pop', 'optional-semicolon', 'class-method')), + ], + + # local function, anonymous or not + 'function-local': [ + include('spaces'), + (ident_no_keyword, Name.Function, + ('#pop', 'optional-expr', 'flag', 'function-param', + 'parenthesis-open', 'type-param-constraint')), + default(('#pop', 'optional-expr', 'flag', 'function-param', + 'parenthesis-open', 'type-param-constraint')), + ], + + 'optional-expr': [ + include('spaces'), + include('expr'), + default('#pop'), + ], + + 'class-method': [ + include('spaces'), + (ident, Name.Function, ('#pop', 'optional-expr', 'flag', + 'function-param', 'parenthesis-open', + 'type-param-constraint')), + ], + + # function arguments + 'function-param': [ + include('spaces'), + (r'\)', Punctuation, '#pop'), + (r'\?', Punctuation), + (ident_no_keyword, Name, + ('#pop', 'function-param-sep', 'assign', 'flag')), + ], + + 'function-param-sep': [ + include('spaces'), + (r'\)', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'function-param')), + ], + + 'prop-get-set': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'parenthesis-close', + 'prop-get-set-opt', 'comma', 'prop-get-set-opt')), + default('#pop'), + ], + + 'prop-get-set-opt': [ + include('spaces'), + (r'(?:default|null|never|dynamic|get|set)\b', Keyword, '#pop'), + (ident_no_keyword, Text, '#pop'), # custom getter/setter + ], + + 'expr-statement': [ + include('spaces'), + # makes semicolon optional here, just to avoid checking the last + # one is bracket or not. + default(('#pop', 'optional-semicolon', 'expr')), + ], + + 'expr': [ + include('spaces'), + (r'@', Name.Decorator, ('#pop', 'optional-expr', 'meta-body', + 'meta-ident', 'meta-colon')), + (r'(?:\+\+|\-\-|~(?!/)|!|\-)', Operator), + (r'\(', Punctuation, ('#pop', 'expr-chain', 'parenthesis')), + (r'(?:static|public|private|override|dynamic|inline)\b', + Keyword.Declaration), + (r'(?:function)\b', Keyword.Declaration, ('#pop', 'expr-chain', + 'function-local')), + (r'\{', Punctuation, ('#pop', 'expr-chain', 'bracket')), + (r'(?:true|false|null)\b', Keyword.Constant, ('#pop', 'expr-chain')), + (r'(?:this)\b', Keyword, ('#pop', 'expr-chain')), + (r'(?:cast)\b', Keyword, ('#pop', 'expr-chain', 'cast')), + (r'(?:try)\b', Keyword, ('#pop', 'catch', 'expr')), + (r'(?:var)\b', Keyword.Declaration, ('#pop', 'var')), + (r'(?:new)\b', Keyword, ('#pop', 'expr-chain', 'new')), + (r'(?:switch)\b', Keyword, ('#pop', 'switch')), + (r'(?:if)\b', Keyword, ('#pop', 'if')), + (r'(?:do)\b', Keyword, ('#pop', 'do')), + (r'(?:while)\b', Keyword, ('#pop', 'while')), + (r'(?:for)\b', Keyword, ('#pop', 'for')), + (r'(?:untyped|throw)\b', Keyword), + (r'(?:return)\b', Keyword, ('#pop', 'optional-expr')), + (r'(?:macro)\b', Keyword, ('#pop', 'macro')), + (r'(?:continue|break)\b', Keyword, '#pop'), + (r'(?:\$\s*[a-z]\b|\$(?!'+ident+'))', Name, ('#pop', 'dollar')), + (ident_no_keyword, Name, ('#pop', 'expr-chain')), + + # Float + (r'\.[0-9]+', Number.Float, ('#pop', 'expr-chain')), + (r'[0-9]+[eE][+\-]?[0-9]+', Number.Float, ('#pop', 'expr-chain')), + (r'[0-9]+\.[0-9]*[eE][+\-]?[0-9]+', Number.Float, ('#pop', 'expr-chain')), + (r'[0-9]+\.[0-9]+', Number.Float, ('#pop', 'expr-chain')), + (r'[0-9]+\.(?!' + ident + '|\.\.)', Number.Float, ('#pop', 'expr-chain')), + + # Int + (r'0x[0-9a-fA-F]+', Number.Hex, ('#pop', 'expr-chain')), + (r'[0-9]+', Number.Integer, ('#pop', 'expr-chain')), + + # String + (r"'", String.Single, ('#pop', 'expr-chain', 'string-single-interpol')), + (r'"', String.Double, ('#pop', 'expr-chain', 'string-double')), + + # EReg + (r'~/(\\\\|\\/|[^/\n])*/[gimsu]*', String.Regex, ('#pop', 'expr-chain')), + + # Array + (r'\[', Punctuation, ('#pop', 'expr-chain', 'array-decl')), + ], + + 'expr-chain': [ + include('spaces'), + (r'(?:\+\+|\-\-)', Operator), + (binop, Operator, ('#pop', 'expr')), + (r'(?:in)\b', Keyword, ('#pop', 'expr')), + (r'\?', Operator, ('#pop', 'expr', 'ternary', 'expr')), + (r'(\.)(' + ident_no_keyword + ')', bygroups(Punctuation, Name)), + (r'\[', Punctuation, 'array-access'), + (r'\(', Punctuation, 'call'), + default('#pop'), + ], + + # macro reification + 'macro': [ + include('spaces'), + include('meta'), + (r':', Punctuation, ('#pop', 'type')), + + (r'(?:extern|private)\b', Keyword.Declaration), + (r'(?:abstract)\b', Keyword.Declaration, ('#pop', 'optional-semicolon', 'abstract')), + (r'(?:class|interface)\b', Keyword.Declaration, ('#pop', 'optional-semicolon', 'macro-class')), + (r'(?:enum)\b', Keyword.Declaration, ('#pop', 'optional-semicolon', 'enum')), + (r'(?:typedef)\b', Keyword.Declaration, ('#pop', 'optional-semicolon', 'typedef')), + + default(('#pop', 'expr')), + ], + + 'macro-class': [ + (r'\{', Punctuation, ('#pop', 'class-body')), + include('class') + ], + + # cast can be written as "cast expr" or "cast(expr, type)" + 'cast': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'parenthesis-close', + 'cast-type', 'expr')), + default(('#pop', 'expr')), + ], + + # optionally give a type as the 2nd argument of cast() + 'cast-type': [ + include('spaces'), + (r',', Punctuation, ('#pop', 'type')), + default('#pop'), + ], + + 'catch': [ + include('spaces'), + (r'(?:catch)\b', Keyword, ('expr', 'function-param', + 'parenthesis-open')), + default('#pop'), + ], + + # do-while loop + 'do': [ + include('spaces'), + default(('#pop', 'do-while', 'expr')), + ], + + # the while after do + 'do-while': [ + include('spaces'), + (r'(?:while)\b', Keyword, ('#pop', 'parenthesis', + 'parenthesis-open')), + ], + + 'while': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'expr', 'parenthesis')), + ], + + 'for': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'expr', 'parenthesis')), + ], + + 'if': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'else', 'optional-semicolon', 'expr', + 'parenthesis')), + ], + + 'else': [ + include('spaces'), + (r'(?:else)\b', Keyword, ('#pop', 'expr')), + default('#pop'), + ], + + 'switch': [ + include('spaces'), + default(('#pop', 'switch-body', 'bracket-open', 'expr')), + ], + + 'switch-body': [ + include('spaces'), + (r'(?:case|default)\b', Keyword, ('case-block', 'case')), + (r'\}', Punctuation, '#pop'), + ], + + 'case': [ + include('spaces'), + (r':', Punctuation, '#pop'), + default(('#pop', 'case-sep', 'case-guard', 'expr')), + ], + + 'case-sep': [ + include('spaces'), + (r':', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'case')), + ], + + 'case-guard': [ + include('spaces'), + (r'(?:if)\b', Keyword, ('#pop', 'parenthesis', 'parenthesis-open')), + default('#pop'), + ], + + # optional multiple expr under a case + 'case-block': [ + include('spaces'), + (r'(?!(?:case|default)\b|\})', Keyword, 'expr-statement'), + default('#pop'), + ], + + 'new': [ + include('spaces'), + default(('#pop', 'call', 'parenthesis-open', 'type')), + ], + + 'array-decl': [ + include('spaces'), + (r'\]', Punctuation, '#pop'), + default(('#pop', 'array-decl-sep', 'expr')), + ], + + 'array-decl-sep': [ + include('spaces'), + (r'\]', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'array-decl')), + ], + + 'array-access': [ + include('spaces'), + default(('#pop', 'array-access-close', 'expr')), + ], + + 'array-access-close': [ + include('spaces'), + (r'\]', Punctuation, '#pop'), + ], + + 'comma': [ + include('spaces'), + (r',', Punctuation, '#pop'), + ], + + 'colon': [ + include('spaces'), + (r':', Punctuation, '#pop'), + ], + + 'semicolon': [ + include('spaces'), + (r';', Punctuation, '#pop'), + ], + + 'optional-semicolon': [ + include('spaces'), + (r';', Punctuation, '#pop'), + default('#pop'), + ], + + # identity that CAN be a Haxe keyword + 'ident': [ + include('spaces'), + (ident, Name, '#pop'), + ], + + 'dollar': [ + include('spaces'), + (r'\{', Punctuation, ('#pop', 'expr-chain', 'bracket-close', 'expr')), + default(('#pop', 'expr-chain')), + ], + + 'type-name': [ + include('spaces'), + (typeid, Name, '#pop'), + ], + + 'type-full-name': [ + include('spaces'), + (r'\.', Punctuation, 'ident'), + default('#pop'), + ], + + 'type': [ + include('spaces'), + (r'\?', Punctuation), + (ident, Name, ('#pop', 'type-check', 'type-full-name')), + (r'\{', Punctuation, ('#pop', 'type-check', 'type-struct')), + (r'\(', Punctuation, ('#pop', 'type-check', 'type-parenthesis')), + ], + + 'type-parenthesis': [ + include('spaces'), + default(('#pop', 'parenthesis-close', 'type')), + ], + + 'type-check': [ + include('spaces'), + (r'->', Punctuation, ('#pop', 'type')), + (r'<(?!=)', Punctuation, 'type-param'), + default('#pop'), + ], + + 'type-struct': [ + include('spaces'), + (r'\}', Punctuation, '#pop'), + (r'\?', Punctuation), + (r'>', Punctuation, ('comma', 'type')), + (ident_no_keyword, Name, ('#pop', 'type-struct-sep', 'type', 'colon')), + include('class-body'), + ], + + 'type-struct-sep': [ + include('spaces'), + (r'\}', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'type-struct')), + ], + + # type-param can be a normal type or a constant literal... + 'type-param-type': [ + # Float + (r'\.[0-9]+', Number.Float, '#pop'), + (r'[0-9]+[eE][+\-]?[0-9]+', Number.Float, '#pop'), + (r'[0-9]+\.[0-9]*[eE][+\-]?[0-9]+', Number.Float, '#pop'), + (r'[0-9]+\.[0-9]+', Number.Float, '#pop'), + (r'[0-9]+\.(?!' + ident + '|\.\.)', Number.Float, '#pop'), + + # Int + (r'0x[0-9a-fA-F]+', Number.Hex, '#pop'), + (r'[0-9]+', Number.Integer, '#pop'), + + # String + (r"'", String.Single, ('#pop', 'string-single')), + (r'"', String.Double, ('#pop', 'string-double')), + + # EReg + (r'~/(\\\\|\\/|[^/\n])*/[gim]*', String.Regex, '#pop'), + + # Array + (r'\[', Operator, ('#pop', 'array-decl')), + + include('type'), + ], + + # type-param part of a type + # ie. the path in Map + 'type-param': [ + include('spaces'), + default(('#pop', 'type-param-sep', 'type-param-type')), + ], + + 'type-param-sep': [ + include('spaces'), + (r'>', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'type-param')), + ], + + # optional type-param that may include constraint + # ie. + 'type-param-constraint': [ + include('spaces'), + (r'<(?!=)', Punctuation, ('#pop', 'type-param-constraint-sep', + 'type-param-constraint-flag', 'type-name')), + default('#pop'), + ], + + 'type-param-constraint-sep': [ + include('spaces'), + (r'>', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'type-param-constraint-sep', + 'type-param-constraint-flag', 'type-name')), + ], + + # the optional constraint inside type-param + 'type-param-constraint-flag': [ + include('spaces'), + (r':', Punctuation, ('#pop', 'type-param-constraint-flag-type')), + default('#pop'), + ], + + 'type-param-constraint-flag-type': [ + include('spaces'), + (r'\(', Punctuation, ('#pop', 'type-param-constraint-flag-type-sep', + 'type')), + default(('#pop', 'type')), + ], + + 'type-param-constraint-flag-type-sep': [ + include('spaces'), + (r'\)', Punctuation, '#pop'), + (r',', Punctuation, 'type'), + ], + + # a parenthesis expr that contain exactly one expr + 'parenthesis': [ + include('spaces'), + default(('#pop', 'parenthesis-close', 'flag', 'expr')), + ], + + 'parenthesis-open': [ + include('spaces'), + (r'\(', Punctuation, '#pop'), + ], + + 'parenthesis-close': [ + include('spaces'), + (r'\)', Punctuation, '#pop'), + ], + + 'var': [ + include('spaces'), + (ident_no_keyword, Text, ('#pop', 'var-sep', 'assign', 'flag', 'prop-get-set')), + ], + + # optional more var decl. + 'var-sep': [ + include('spaces'), + (r',', Punctuation, ('#pop', 'var')), + default('#pop'), + ], + + # optional assignment + 'assign': [ + include('spaces'), + (r'=', Operator, ('#pop', 'expr')), + default('#pop'), + ], + + # optional type flag + 'flag': [ + include('spaces'), + (r':', Punctuation, ('#pop', 'type')), + default('#pop'), + ], + + # colon as part of a ternary operator (?:) + 'ternary': [ + include('spaces'), + (r':', Operator, '#pop'), + ], + + # function call + 'call': [ + include('spaces'), + (r'\)', Punctuation, '#pop'), + default(('#pop', 'call-sep', 'expr')), + ], + + # after a call param + 'call-sep': [ + include('spaces'), + (r'\)', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'call')), + ], + + # bracket can be block or object + 'bracket': [ + include('spaces'), + (r'(?!(?:\$\s*[a-z]\b|\$(?!'+ident+')))' + ident_no_keyword, Name, + ('#pop', 'bracket-check')), + (r"'", String.Single, ('#pop', 'bracket-check', 'string-single')), + (r'"', String.Double, ('#pop', 'bracket-check', 'string-double')), + default(('#pop', 'block')), + ], + + 'bracket-check': [ + include('spaces'), + (r':', Punctuation, ('#pop', 'object-sep', 'expr')), # is object + default(('#pop', 'block', 'optional-semicolon', 'expr-chain')), # is block + ], + + # code block + 'block': [ + include('spaces'), + (r'\}', Punctuation, '#pop'), + default('expr-statement'), + ], + + # object in key-value pairs + 'object': [ + include('spaces'), + (r'\}', Punctuation, '#pop'), + default(('#pop', 'object-sep', 'expr', 'colon', 'ident-or-string')) + ], + + # a key of an object + 'ident-or-string': [ + include('spaces'), + (ident_no_keyword, Name, '#pop'), + (r"'", String.Single, ('#pop', 'string-single')), + (r'"', String.Double, ('#pop', 'string-double')), + ], + + # after a key-value pair in object + 'object-sep': [ + include('spaces'), + (r'\}', Punctuation, '#pop'), + (r',', Punctuation, ('#pop', 'object')), + ], + + + + } + + def analyse_text(text): + if re.match(r'\w+\s*:\s*\w', text): + return 0.3 + + +class HxmlLexer(RegexLexer): + """ + Lexer for `haXe build `_ files. + + .. versionadded:: 1.6 + """ + name = 'Hxml' + aliases = ['haxeml', 'hxml'] + filenames = ['*.hxml'] + + tokens = { + 'root': [ + # Seperator + (r'(--)(next)', bygroups(Punctuation, Generic.Heading)), + # Compiler switches with one dash + (r'(-)(prompt|debug|v)', bygroups(Punctuation, Keyword.Keyword)), + # Compilerswitches with two dashes + (r'(--)(neko-source|flash-strict|flash-use-stage|no-opt|no-traces|' + r'no-inline|times|no-output)', bygroups(Punctuation, Keyword)), + # Targets and other options that take an argument + (r'(-)(cpp|js|neko|x|as3|swf9?|swf-lib|php|xml|main|lib|D|resource|' + r'cp|cmd)( +)(.+)', + bygroups(Punctuation, Keyword, Whitespace, String)), + # Options that take only numerical arguments + (r'(-)(swf-version)( +)(\d+)', + bygroups(Punctuation, Keyword, Number.Integer)), + # An Option that defines the size, the fps and the background + # color of an flash movie + (r'(-)(swf-header)( +)(\d+)(:)(\d+)(:)(\d+)(:)([A-Fa-f0-9]{6})', + bygroups(Punctuation, Keyword, Whitespace, Number.Integer, + Punctuation, Number.Integer, Punctuation, Number.Integer, + Punctuation, Number.Hex)), + # options with two dashes that takes arguments + (r'(--)(js-namespace|php-front|php-lib|remap|gen-hx-classes)( +)' + r'(.+)', bygroups(Punctuation, Keyword, Whitespace, String)), + # Single line comment, multiline ones are not allowed. + (r'#.*', Comment.Single) + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/hdl.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/hdl.py new file mode 100644 index 0000000000..c8e347185c --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/hdl.py @@ -0,0 +1,375 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.hdl + ~~~~~~~~~~~~~~~~~~~ + + Lexers for hardware descriptor languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, bygroups, include, using, this, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error + +__all__ = ['VerilogLexer', 'SystemVerilogLexer', 'VhdlLexer'] + + +class VerilogLexer(RegexLexer): + """ + For verilog source code with preprocessor directives. + + .. versionadded:: 1.4 + """ + name = 'verilog' + aliases = ['verilog', 'v'] + filenames = ['*.v'] + mimetypes = ['text/x-verilog'] + + #: optional Comment or Whitespace + _ws = r'(?:\s|//.*?\n|/[*].*?[*]/)+' + + tokens = { + 'root': [ + (r'^\s*`define', Comment.Preproc, 'macro'), + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuation + (r'/(\\\n)?/(\n|(.|\n)*?[^\\]\n)', Comment.Single), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + (r'[{}#@]', Punctuation), + (r'L?"', String, 'string'), + (r"L?'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'([0-9]+)|(\'h)[0-9a-fA-F]+', Number.Hex), + (r'([0-9]+)|(\'b)[01]+', Number.Bin), + (r'([0-9]+)|(\'d)[0-9]+', Number.Integer), + (r'([0-9]+)|(\'o)[0-7]+', Number.Oct), + (r'\'[01xz]', Number), + (r'\d+[Ll]?', Number.Integer), + (r'\*/', Error), + (r'[~!%^&*+=|?:<>/-]', Operator), + (r'[()\[\],.;\']', Punctuation), + (r'`[a-zA-Z_]\w*', Name.Constant), + + (r'^(\s*)(package)(\s+)', bygroups(Text, Keyword.Namespace, Text)), + (r'^(\s*)(import)(\s+)', bygroups(Text, Keyword.Namespace, Text), + 'import'), + + (words(( + 'always', 'always_comb', 'always_ff', 'always_latch', 'and', + 'assign', 'automatic', 'begin', 'break', 'buf', 'bufif0', 'bufif1', + 'case', 'casex', 'casez', 'cmos', 'const', 'continue', 'deassign', + 'default', 'defparam', 'disable', 'do', 'edge', 'else', 'end', 'endcase', + 'endfunction', 'endgenerate', 'endmodule', 'endpackage', 'endprimitive', + 'endspecify', 'endtable', 'endtask', 'enum', 'event', 'final', 'for', + 'force', 'forever', 'fork', 'function', 'generate', 'genvar', 'highz0', + 'highz1', 'if', 'initial', 'inout', 'input', 'integer', 'join', 'large', + 'localparam', 'macromodule', 'medium', 'module', 'nand', 'negedge', + 'nmos', 'nor', 'not', 'notif0', 'notif1', 'or', 'output', 'packed', + 'parameter', 'pmos', 'posedge', 'primitive', 'pull0', 'pull1', + 'pulldown', 'pullup', 'rcmos', 'ref', 'release', 'repeat', 'return', + 'rnmos', 'rpmos', 'rtran', 'rtranif0', 'rtranif1', 'scalared', 'signed', + 'small', 'specify', 'specparam', 'strength', 'string', 'strong0', + 'strong1', 'struct', 'table', 'task', 'tran', 'tranif0', 'tranif1', + 'type', 'typedef', 'unsigned', 'var', 'vectored', 'void', 'wait', + 'weak0', 'weak1', 'while', 'xnor', 'xor'), suffix=r'\b'), + Keyword), + + (words(( + 'accelerate', 'autoexpand_vectornets', 'celldefine', 'default_nettype', + 'else', 'elsif', 'endcelldefine', 'endif', 'endprotect', 'endprotected', + 'expand_vectornets', 'ifdef', 'ifndef', 'include', 'noaccelerate', + 'noexpand_vectornets', 'noremove_gatenames', 'noremove_netnames', + 'nounconnected_drive', 'protect', 'protected', 'remove_gatenames', + 'remove_netnames', 'resetall', 'timescale', 'unconnected_drive', + 'undef'), prefix=r'`', suffix=r'\b'), + Comment.Preproc), + + (words(( + 'bits', 'bitstoreal', 'bitstoshortreal', 'countdrivers', 'display', 'fclose', + 'fdisplay', 'finish', 'floor', 'fmonitor', 'fopen', 'fstrobe', 'fwrite', + 'getpattern', 'history', 'incsave', 'input', 'itor', 'key', 'list', 'log', + 'monitor', 'monitoroff', 'monitoron', 'nokey', 'nolog', 'printtimescale', + 'random', 'readmemb', 'readmemh', 'realtime', 'realtobits', 'reset', + 'reset_count', 'reset_value', 'restart', 'rtoi', 'save', 'scale', 'scope', + 'shortrealtobits', 'showscopes', 'showvariables', 'showvars', 'sreadmemb', + 'sreadmemh', 'stime', 'stop', 'strobe', 'time', 'timeformat', 'write'), + prefix=r'\$', suffix=r'\b'), + Name.Builtin), + + (words(( + 'byte', 'shortint', 'int', 'longint', 'integer', 'time', + 'bit', 'logic', 'reg', 'supply0', 'supply1', 'tri', 'triand', + 'trior', 'tri0', 'tri1', 'trireg', 'uwire', 'wire', 'wand', 'wo' + 'shortreal', 'real', 'realtime'), suffix=r'\b'), + Keyword.Type), + ('[a-zA-Z_]\w*:(?!:)', Name.Label), + ('[a-zA-Z_]\w*', Name), + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # stray backslash + ], + 'macro': [ + (r'[^/\n]+', Comment.Preproc), + (r'/[*](.|\n)*?[*]/', Comment.Multiline), + (r'//.*?\n', Comment.Single, '#pop'), + (r'/', Comment.Preproc), + (r'(?<=\\)\n', Comment.Preproc), + (r'\n', Comment.Preproc, '#pop'), + ], + 'import': [ + (r'[\w:]+\*?', Name.Namespace, '#pop') + ] + } + + def get_tokens_unprocessed(self, text): + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text): + # Convention: mark all upper case names as constants + if token is Name: + if value.isupper(): + token = Name.Constant + yield index, token, value + + +class SystemVerilogLexer(RegexLexer): + """ + Extends verilog lexer to recognise all SystemVerilog keywords from IEEE + 1800-2009 standard. + + .. versionadded:: 1.5 + """ + name = 'systemverilog' + aliases = ['systemverilog', 'sv'] + filenames = ['*.sv', '*.svh'] + mimetypes = ['text/x-systemverilog'] + + #: optional Comment or Whitespace + _ws = r'(?:\s|//.*?\n|/[*].*?[*]/)+' + + tokens = { + 'root': [ + (r'^\s*`define', Comment.Preproc, 'macro'), + (r'^(\s*)(package)(\s+)', bygroups(Text, Keyword.Namespace, Text)), + (r'^(\s*)(import)(\s+)', bygroups(Text, Keyword.Namespace, Text), 'import'), + + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuation + (r'/(\\\n)?/(\n|(.|\n)*?[^\\]\n)', Comment.Single), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + (r'[{}#@]', Punctuation), + (r'L?"', String, 'string'), + (r"L?'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'([0-9]+)|(\'h)[0-9a-fA-F]+', Number.Hex), + (r'([0-9]+)|(\'b)[01]+', Number.Bin), + (r'([0-9]+)|(\'d)[0-9]+', Number.Integer), + (r'([0-9]+)|(\'o)[0-7]+', Number.Oct), + (r'\'[01xz]', Number), + (r'\d+[Ll]?', Number.Integer), + (r'\*/', Error), + (r'[~!%^&*+=|?:<>/-]', Operator), + (r'[()\[\],.;\']', Punctuation), + (r'`[a-zA-Z_]\w*', Name.Constant), + + (words(( + 'accept_on', 'alias', 'always', 'always_comb', 'always_ff', 'always_latch', + 'and', 'assert', 'assign', 'assume', 'automatic', 'before', 'begin', 'bind', 'bins', + 'binsof', 'bit', 'break', 'buf', 'bufif0', 'bufif1', 'byte', 'case', 'casex', 'casez', + 'cell', 'chandle', 'checker', 'class', 'clocking', 'cmos', 'config', 'const', 'constraint', + 'context', 'continue', 'cover', 'covergroup', 'coverpoint', 'cross', 'deassign', + 'default', 'defparam', 'design', 'disable', 'dist', 'do', 'edge', 'else', 'end', 'endcase', + 'endchecker', 'endclass', 'endclocking', 'endconfig', 'endfunction', 'endgenerate', + 'endgroup', 'endinterface', 'endmodule', 'endpackage', 'endprimitive', + 'endprogram', 'endproperty', 'endsequence', 'endspecify', 'endtable', + 'endtask', 'enum', 'event', 'eventually', 'expect', 'export', 'extends', 'extern', + 'final', 'first_match', 'for', 'force', 'foreach', 'forever', 'fork', 'forkjoin', + 'function', 'generate', 'genvar', 'global', 'highz0', 'highz1', 'if', 'iff', 'ifnone', + 'ignore_bins', 'illegal_bins', 'implies', 'import', 'incdir', 'include', + 'initial', 'inout', 'input', 'inside', 'instance', 'int', 'integer', 'interface', + 'intersect', 'join', 'join_any', 'join_none', 'large', 'let', 'liblist', 'library', + 'local', 'localparam', 'logic', 'longint', 'macromodule', 'matches', 'medium', + 'modport', 'module', 'nand', 'negedge', 'new', 'nexttime', 'nmos', 'nor', 'noshowcancelled', + 'not', 'notif0', 'notif1', 'null', 'or', 'output', 'package', 'packed', 'parameter', + 'pmos', 'posedge', 'primitive', 'priority', 'program', 'property', 'protected', + 'pull0', 'pull1', 'pulldown', 'pullup', 'pulsestyle_ondetect', 'pulsestyle_onevent', + 'pure', 'rand', 'randc', 'randcase', 'randsequence', 'rcmos', 'real', 'realtime', + 'ref', 'reg', 'reject_on', 'release', 'repeat', 'restrict', 'return', 'rnmos', + 'rpmos', 'rtran', 'rtranif0', 'rtranif1', 's_always', 's_eventually', 's_nexttime', + 's_until', 's_until_with', 'scalared', 'sequence', 'shortint', 'shortreal', + 'showcancelled', 'signed', 'small', 'solve', 'specify', 'specparam', 'static', + 'string', 'strong', 'strong0', 'strong1', 'struct', 'super', 'supply0', 'supply1', + 'sync_accept_on', 'sync_reject_on', 'table', 'tagged', 'task', 'this', 'throughout', + 'time', 'timeprecision', 'timeunit', 'tran', 'tranif0', 'tranif1', 'tri', 'tri0', + 'tri1', 'triand', 'trior', 'trireg', 'type', 'typedef', 'union', 'unique', 'unique0', + 'unsigned', 'until', 'until_with', 'untyped', 'use', 'uwire', 'var', 'vectored', + 'virtual', 'void', 'wait', 'wait_order', 'wand', 'weak', 'weak0', 'weak1', 'while', + 'wildcard', 'wire', 'with', 'within', 'wor', 'xnor', 'xor'), suffix=r'\b'), + Keyword), + + (words(( + '`__FILE__', '`__LINE__', '`begin_keywords', '`celldefine', '`default_nettype', + '`define', '`else', '`elsif', '`end_keywords', '`endcelldefine', '`endif', + '`ifdef', '`ifndef', '`include', '`line', '`nounconnected_drive', '`pragma', + '`resetall', '`timescale', '`unconnected_drive', '`undef', '`undefineall'), + suffix=r'\b'), + Comment.Preproc), + + (words(( + '$display', '$displayb', '$displayh', '$displayo', '$dumpall', '$dumpfile', + '$dumpflush', '$dumplimit', '$dumpoff', '$dumpon', '$dumpports', + '$dumpportsall', '$dumpportsflush', '$dumpportslimit', '$dumpportsoff', + '$dumpportson', '$dumpvars', '$fclose', '$fdisplay', '$fdisplayb', + '$fdisplayh', '$fdisplayo', '$feof', '$ferror', '$fflush', '$fgetc', + '$fgets', '$finish', '$fmonitor', '$fmonitorb', '$fmonitorh', '$fmonitoro', + '$fopen', '$fread', '$fscanf', '$fseek', '$fstrobe', '$fstrobeb', '$fstrobeh', + '$fstrobeo', '$ftell', '$fwrite', '$fwriteb', '$fwriteh', '$fwriteo', + '$monitor', '$monitorb', '$monitorh', '$monitoro', '$monitoroff', + '$monitoron', '$plusargs', '$random', '$readmemb', '$readmemh', '$rewind', + '$sformat', '$sformatf', '$sscanf', '$strobe', '$strobeb', '$strobeh', '$strobeo', + '$swrite', '$swriteb', '$swriteh', '$swriteo', '$test', '$ungetc', + '$value$plusargs', '$write', '$writeb', '$writeh', '$writememb', + '$writememh', '$writeo'), suffix=r'\b'), + Name.Builtin), + + (r'(class)(\s+)', bygroups(Keyword, Text), 'classname'), + (words(( + 'byte', 'shortint', 'int', 'longint', 'integer', 'time', + 'bit', 'logic', 'reg', 'supply0', 'supply1', 'tri', 'triand', + 'trior', 'tri0', 'tri1', 'trireg', 'uwire', 'wire', 'wand', 'wo' + 'shortreal', 'real', 'realtime'), suffix=r'\b'), + Keyword.Type), + ('[a-zA-Z_]\w*:(?!:)', Name.Label), + ('[a-zA-Z_]\w*', Name), + ], + 'classname': [ + (r'[a-zA-Z_]\w*', Name.Class, '#pop'), + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # stray backslash + ], + 'macro': [ + (r'[^/\n]+', Comment.Preproc), + (r'/[*](.|\n)*?[*]/', Comment.Multiline), + (r'//.*?\n', Comment.Single, '#pop'), + (r'/', Comment.Preproc), + (r'(?<=\\)\n', Comment.Preproc), + (r'\n', Comment.Preproc, '#pop'), + ], + 'import': [ + (r'[\w:]+\*?', Name.Namespace, '#pop') + ] + } + + def get_tokens_unprocessed(self, text): + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text): + # Convention: mark all upper case names as constants + if token is Name: + if value.isupper(): + token = Name.Constant + yield index, token, value + + +class VhdlLexer(RegexLexer): + """ + For VHDL source code. + + .. versionadded:: 1.5 + """ + name = 'vhdl' + aliases = ['vhdl'] + filenames = ['*.vhdl', '*.vhd'] + mimetypes = ['text/x-vhdl'] + flags = re.MULTILINE | re.IGNORECASE + + tokens = { + 'root': [ + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuation + (r'--.*?$', Comment.Single), + (r"'(U|X|0|1|Z|W|L|H|-)'", String.Char), + (r'[~!%^&*+=|?:<>/-]', Operator), + (r"'[a-z_]\w*", Name.Attribute), + (r'[()\[\],.;\']', Punctuation), + (r'"[^\n\\]*"', String), + + (r'(library)(\s+)([a-z_]\w*)', + bygroups(Keyword, Text, Name.Namespace)), + (r'(use)(\s+)(entity)', bygroups(Keyword, Text, Keyword)), + (r'(use)(\s+)([a-z_][\w.]*)', + bygroups(Keyword, Text, Name.Namespace)), + (r'(entity|component)(\s+)([a-z_]\w*)', + bygroups(Keyword, Text, Name.Class)), + (r'(architecture|configuration)(\s+)([a-z_]\w*)(\s+)' + r'(of)(\s+)([a-z_]\w*)(\s+)(is)', + bygroups(Keyword, Text, Name.Class, Text, Keyword, Text, + Name.Class, Text, Keyword)), + + (r'(end)(\s+)', bygroups(using(this), Text), 'endblock'), + + include('types'), + include('keywords'), + include('numbers'), + + (r'[a-z_]\w*', Name), + ], + 'endblock': [ + include('keywords'), + (r'[a-z_]\w*', Name.Class), + (r'(\s+)', Text), + (r';', Punctuation, '#pop'), + ], + 'types': [ + (words(( + 'boolean', 'bit', 'character', 'severity_level', 'integer', 'time', + 'delay_length', 'natural', 'positive', 'string', 'bit_vector', + 'file_open_kind', 'file_open_status', 'std_ulogic', 'std_ulogic_vector', + 'std_logic', 'std_logic_vector'), suffix=r'\b'), + Keyword.Type), + ], + 'keywords': [ + (words(( + 'abs', 'access', 'after', 'alias', 'all', 'and', + 'architecture', 'array', 'assert', 'attribute', 'begin', 'block', + 'body', 'buffer', 'bus', 'case', 'component', 'configuration', + 'constant', 'disconnect', 'downto', 'else', 'elsif', 'end', + 'entity', 'exit', 'file', 'for', 'function', 'generate', + 'generic', 'group', 'guarded', 'if', 'impure', 'in', + 'inertial', 'inout', 'is', 'label', 'library', 'linkage', + 'literal', 'loop', 'map', 'mod', 'nand', 'new', + 'next', 'nor', 'not', 'null', 'of', 'on', + 'open', 'or', 'others', 'out', 'package', 'port', + 'postponed', 'procedure', 'process', 'pure', 'range', 'record', + 'register', 'reject', 'return', 'rol', 'ror', 'select', + 'severity', 'signal', 'shared', 'sla', 'sli', 'sra', + 'srl', 'subtype', 'then', 'to', 'transport', 'type', + 'units', 'until', 'use', 'variable', 'wait', 'when', + 'while', 'with', 'xnor', 'xor'), suffix=r'\b'), + Keyword), + ], + 'numbers': [ + (r'\d{1,2}#[0-9a-f_]+#?', Number.Integer), + (r'\d+', Number.Integer), + (r'(\d+\.\d*|\.\d+|\d+)E[+-]?\d+', Number.Float), + (r'X"[0-9a-f_]+"', Number.Hex), + (r'O"[0-7_]+"', Number.Oct), + (r'B"[01_]+"', Number.Bin), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/html.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/html.py new file mode 100644 index 0000000000..8cf331d381 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/html.py @@ -0,0 +1,589 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.html + ~~~~~~~~~~~~~~~~~~~~ + + Lexers for HTML, XML and related markup. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, ExtendedRegexLexer, include, bygroups, \ + default, using +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Punctuation +from pygments.util import looks_like_xml, html_doctype_matches + +from pygments.lexers.javascript import JavascriptLexer +from pygments.lexers.jvm import ScalaLexer +from pygments.lexers.css import CssLexer, _indentation, _starts_block +from pygments.lexers.ruby import RubyLexer + +__all__ = ['HtmlLexer', 'DtdLexer', 'XmlLexer', 'XsltLexer', 'HamlLexer', + 'ScamlLexer', 'JadeLexer'] + + +class HtmlLexer(RegexLexer): + """ + For HTML 4 and XHTML 1 markup. Nested JavaScript and CSS is highlighted + by the appropriate lexer. + """ + + name = 'HTML' + aliases = ['html'] + filenames = ['*.html', '*.htm', '*.xhtml', '*.xslt'] + mimetypes = ['text/html', 'application/xhtml+xml'] + + flags = re.IGNORECASE | re.DOTALL + tokens = { + 'root': [ + ('[^<&]+', Text), + (r'&\S*?;', Name.Entity), + (r'\<\!\[CDATA\[.*?\]\]\>', Comment.Preproc), + ('', Comment, '#pop'), + ('-', Comment), + ], + 'tag': [ + (r'\s+', Text), + (r'([\w:-]+\s*=)(\s*)', bygroups(Name.Attribute, Text), 'attr'), + (r'[\w:-]+', Name.Attribute), + (r'/?\s*>', Name.Tag, '#pop'), + ], + 'script-content': [ + (r'<\s*/\s*script\s*>', Name.Tag, '#pop'), + (r'.+?(?=<\s*/\s*script\s*>)', using(JavascriptLexer)), + ], + 'style-content': [ + (r'<\s*/\s*style\s*>', Name.Tag, '#pop'), + (r'.+?(?=<\s*/\s*style\s*>)', using(CssLexer)), + ], + 'attr': [ + ('".*?"', String, '#pop'), + ("'.*?'", String, '#pop'), + (r'[^\s>]+', String, '#pop'), + ], + } + + def analyse_text(text): + if html_doctype_matches(text): + return 0.5 + + +class DtdLexer(RegexLexer): + """ + A lexer for DTDs (Document Type Definitions). + + .. versionadded:: 1.5 + """ + + flags = re.MULTILINE | re.DOTALL + + name = 'DTD' + aliases = ['dtd'] + filenames = ['*.dtd'] + mimetypes = ['application/xml-dtd'] + + tokens = { + 'root': [ + include('common'), + + (r'(\s]+)', + bygroups(Keyword, Text, Name.Tag)), + (r'PUBLIC|SYSTEM', Keyword.Constant), + (r'[\[\]>]', Keyword), + ], + + 'common': [ + (r'\s+', Text), + (r'(%|&)[^;]*;', Name.Entity), + ('', Comment, '#pop'), + ('-', Comment), + ], + + 'element': [ + include('common'), + (r'EMPTY|ANY|#PCDATA', Keyword.Constant), + (r'[^>\s|()?+*,]+', Name.Tag), + (r'>', Keyword, '#pop'), + ], + + 'attlist': [ + include('common'), + (r'CDATA|IDREFS|IDREF|ID|NMTOKENS|NMTOKEN|ENTITIES|ENTITY|NOTATION', + Keyword.Constant), + (r'#REQUIRED|#IMPLIED|#FIXED', Keyword.Constant), + (r'xml:space|xml:lang', Keyword.Reserved), + (r'[^>\s|()?+*,]+', Name.Attribute), + (r'>', Keyword, '#pop'), + ], + + 'entity': [ + include('common'), + (r'SYSTEM|PUBLIC|NDATA', Keyword.Constant), + (r'[^>\s|()?+*,]+', Name.Entity), + (r'>', Keyword, '#pop'), + ], + + 'notation': [ + include('common'), + (r'SYSTEM|PUBLIC', Keyword.Constant), + (r'[^>\s|()?+*,]+', Name.Attribute), + (r'>', Keyword, '#pop'), + ], + } + + def analyse_text(text): + if not looks_like_xml(text) and \ + ('', Comment.Preproc), + ('', Comment, '#pop'), + ('-', Comment), + ], + 'tag': [ + (r'\s+', Text), + (r'[\w.:-]+\s*=', Name.Attribute, 'attr'), + (r'/?\s*>', Name.Tag, '#pop'), + ], + 'attr': [ + ('\s+', Text), + ('".*?"', String, '#pop'), + ("'.*?'", String, '#pop'), + (r'[^\s>]+', String, '#pop'), + ], + } + + def analyse_text(text): + if looks_like_xml(text): + return 0.45 # less than HTML + + +class XsltLexer(XmlLexer): + """ + A lexer for XSLT. + + .. versionadded:: 0.10 + """ + + name = 'XSLT' + aliases = ['xslt'] + filenames = ['*.xsl', '*.xslt', '*.xpl'] # xpl is XProc + mimetypes = ['application/xsl+xml', 'application/xslt+xml'] + + EXTRA_KEYWORDS = set(( + 'apply-imports', 'apply-templates', 'attribute', + 'attribute-set', 'call-template', 'choose', 'comment', + 'copy', 'copy-of', 'decimal-format', 'element', 'fallback', + 'for-each', 'if', 'import', 'include', 'key', 'message', + 'namespace-alias', 'number', 'otherwise', 'output', 'param', + 'preserve-space', 'processing-instruction', 'sort', + 'strip-space', 'stylesheet', 'template', 'text', 'transform', + 'value-of', 'variable', 'when', 'with-param' + )) + + def get_tokens_unprocessed(self, text): + for index, token, value in XmlLexer.get_tokens_unprocessed(self, text): + m = re.match(']*)/?>?', value) + + if token is Name.Tag and m and m.group(1) in self.EXTRA_KEYWORDS: + yield index, Keyword, value + else: + yield index, token, value + + def analyse_text(text): + if looks_like_xml(text) and ']{1,2}(?=[ \t=])', Punctuation), + include('eval-or-plain'), + ], + + 'plain': [ + (r'([^#\n]|#[^{\n]|(\\\\)*\\#\{)+', Text), + (r'(#\{)(' + _dot + '*?)(\})', + bygroups(String.Interpol, using(RubyLexer), String.Interpol)), + (r'\n', Text, 'root'), + ], + + 'html-attributes': [ + (r'\s+', Text), + (r'[\w:-]+[ \t]*=', Name.Attribute, 'html-attribute-value'), + (r'[\w:-]+', Name.Attribute), + (r'\)', Text, '#pop'), + ], + + 'html-attribute-value': [ + (r'[ \t]+', Text), + (r'\w+', Name.Variable, '#pop'), + (r'@\w+', Name.Variable.Instance, '#pop'), + (r'\$\w+', Name.Variable.Global, '#pop'), + (r"'(\\\\|\\'|[^'\n])*'", String, '#pop'), + (r'"(\\\\|\\"|[^"\n])*"', String, '#pop'), + ], + + 'html-comment-block': [ + (_dot + '+', Comment), + (r'\n', Text, 'root'), + ], + + 'haml-comment-block': [ + (_dot + '+', Comment.Preproc), + (r'\n', Text, 'root'), + ], + + 'filter-block': [ + (r'([^#\n]|#[^{\n]|(\\\\)*\\#\{)+', Name.Decorator), + (r'(#\{)(' + _dot + '*?)(\})', + bygroups(String.Interpol, using(RubyLexer), String.Interpol)), + (r'\n', Text, 'root'), + ], + } + + +class ScamlLexer(ExtendedRegexLexer): + """ + For `Scaml markup `_. Scaml is Haml for Scala. + + .. versionadded:: 1.4 + """ + + name = 'Scaml' + aliases = ['scaml'] + filenames = ['*.scaml'] + mimetypes = ['text/x-scaml'] + + flags = re.IGNORECASE + # Scaml does not yet support the " |\n" notation to + # wrap long lines. Once it does, use the custom faux + # dot instead. + # _dot = r'(?: \|\n(?=.* \|)|.)' + _dot = r'.' + + tokens = { + 'root': [ + (r'[ \t]*\n', Text), + (r'[ \t]*', _indentation), + ], + + 'css': [ + (r'\.[\w:-]+', Name.Class, 'tag'), + (r'\#[\w:-]+', Name.Function, 'tag'), + ], + + 'eval-or-plain': [ + (r'[&!]?==', Punctuation, 'plain'), + (r'([&!]?[=~])(' + _dot + r'*\n)', + bygroups(Punctuation, using(ScalaLexer)), + 'root'), + default('plain'), + ], + + 'content': [ + include('css'), + (r'%[\w:-]+', Name.Tag, 'tag'), + (r'!!!' + _dot + r'*\n', Name.Namespace, '#pop'), + (r'(/)(\[' + _dot + '*?\])(' + _dot + r'*\n)', + bygroups(Comment, Comment.Special, Comment), + '#pop'), + (r'/' + _dot + r'*\n', _starts_block(Comment, 'html-comment-block'), + '#pop'), + (r'-#' + _dot + r'*\n', _starts_block(Comment.Preproc, + 'scaml-comment-block'), '#pop'), + (r'(-@\s*)(import)?(' + _dot + r'*\n)', + bygroups(Punctuation, Keyword, using(ScalaLexer)), + '#pop'), + (r'(-)(' + _dot + r'*\n)', + bygroups(Punctuation, using(ScalaLexer)), + '#pop'), + (r':' + _dot + r'*\n', _starts_block(Name.Decorator, 'filter-block'), + '#pop'), + include('eval-or-plain'), + ], + + 'tag': [ + include('css'), + (r'\{(,\n|' + _dot + ')*?\}', using(ScalaLexer)), + (r'\[' + _dot + '*?\]', using(ScalaLexer)), + (r'\(', Text, 'html-attributes'), + (r'/[ \t]*\n', Punctuation, '#pop:2'), + (r'[<>]{1,2}(?=[ \t=])', Punctuation), + include('eval-or-plain'), + ], + + 'plain': [ + (r'([^#\n]|#[^{\n]|(\\\\)*\\#\{)+', Text), + (r'(#\{)(' + _dot + '*?)(\})', + bygroups(String.Interpol, using(ScalaLexer), String.Interpol)), + (r'\n', Text, 'root'), + ], + + 'html-attributes': [ + (r'\s+', Text), + (r'[\w:-]+[ \t]*=', Name.Attribute, 'html-attribute-value'), + (r'[\w:-]+', Name.Attribute), + (r'\)', Text, '#pop'), + ], + + 'html-attribute-value': [ + (r'[ \t]+', Text), + (r'\w+', Name.Variable, '#pop'), + (r'@\w+', Name.Variable.Instance, '#pop'), + (r'\$\w+', Name.Variable.Global, '#pop'), + (r"'(\\\\|\\'|[^'\n])*'", String, '#pop'), + (r'"(\\\\|\\"|[^"\n])*"', String, '#pop'), + ], + + 'html-comment-block': [ + (_dot + '+', Comment), + (r'\n', Text, 'root'), + ], + + 'scaml-comment-block': [ + (_dot + '+', Comment.Preproc), + (r'\n', Text, 'root'), + ], + + 'filter-block': [ + (r'([^#\n]|#[^{\n]|(\\\\)*\\#\{)+', Name.Decorator), + (r'(#\{)(' + _dot + '*?)(\})', + bygroups(String.Interpol, using(ScalaLexer), String.Interpol)), + (r'\n', Text, 'root'), + ], + } + + +class JadeLexer(ExtendedRegexLexer): + """ + For Jade markup. + Jade is a variant of Scaml, see: + http://scalate.fusesource.org/documentation/scaml-reference.html + + .. versionadded:: 1.4 + """ + + name = 'Jade' + aliases = ['jade'] + filenames = ['*.jade'] + mimetypes = ['text/x-jade'] + + flags = re.IGNORECASE + _dot = r'.' + + tokens = { + 'root': [ + (r'[ \t]*\n', Text), + (r'[ \t]*', _indentation), + ], + + 'css': [ + (r'\.[\w:-]+', Name.Class, 'tag'), + (r'\#[\w:-]+', Name.Function, 'tag'), + ], + + 'eval-or-plain': [ + (r'[&!]?==', Punctuation, 'plain'), + (r'([&!]?[=~])(' + _dot + r'*\n)', + bygroups(Punctuation, using(ScalaLexer)), 'root'), + default('plain'), + ], + + 'content': [ + include('css'), + (r'!!!' + _dot + r'*\n', Name.Namespace, '#pop'), + (r'(/)(\[' + _dot + '*?\])(' + _dot + r'*\n)', + bygroups(Comment, Comment.Special, Comment), + '#pop'), + (r'/' + _dot + r'*\n', _starts_block(Comment, 'html-comment-block'), + '#pop'), + (r'-#' + _dot + r'*\n', _starts_block(Comment.Preproc, + 'scaml-comment-block'), '#pop'), + (r'(-@\s*)(import)?(' + _dot + r'*\n)', + bygroups(Punctuation, Keyword, using(ScalaLexer)), + '#pop'), + (r'(-)(' + _dot + r'*\n)', + bygroups(Punctuation, using(ScalaLexer)), + '#pop'), + (r':' + _dot + r'*\n', _starts_block(Name.Decorator, 'filter-block'), + '#pop'), + (r'[\w:-]+', Name.Tag, 'tag'), + (r'\|', Text, 'eval-or-plain'), + ], + + 'tag': [ + include('css'), + (r'\{(,\n|' + _dot + ')*?\}', using(ScalaLexer)), + (r'\[' + _dot + '*?\]', using(ScalaLexer)), + (r'\(', Text, 'html-attributes'), + (r'/[ \t]*\n', Punctuation, '#pop:2'), + (r'[<>]{1,2}(?=[ \t=])', Punctuation), + include('eval-or-plain'), + ], + + 'plain': [ + (r'([^#\n]|#[^{\n]|(\\\\)*\\#\{)+', Text), + (r'(#\{)(' + _dot + '*?)(\})', + bygroups(String.Interpol, using(ScalaLexer), String.Interpol)), + (r'\n', Text, 'root'), + ], + + 'html-attributes': [ + (r'\s+', Text), + (r'[\w:-]+[ \t]*=', Name.Attribute, 'html-attribute-value'), + (r'[\w:-]+', Name.Attribute), + (r'\)', Text, '#pop'), + ], + + 'html-attribute-value': [ + (r'[ \t]+', Text), + (r'\w+', Name.Variable, '#pop'), + (r'@\w+', Name.Variable.Instance, '#pop'), + (r'\$\w+', Name.Variable.Global, '#pop'), + (r"'(\\\\|\\'|[^'\n])*'", String, '#pop'), + (r'"(\\\\|\\"|[^"\n])*"', String, '#pop'), + ], + + 'html-comment-block': [ + (_dot + '+', Comment), + (r'\n', Text, 'root'), + ], + + 'scaml-comment-block': [ + (_dot + '+', Comment.Preproc), + (r'\n', Text, 'root'), + ], + + 'filter-block': [ + (r'([^#\n]|#[^{\n]|(\\\\)*\\#\{)+', Name.Decorator), + (r'(#\{)(' + _dot + '*?)(\})', + bygroups(String.Interpol, using(ScalaLexer), String.Interpol)), + (r'\n', Text, 'root'), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/idl.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/idl.py new file mode 100644 index 0000000000..7941028c41 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/idl.py @@ -0,0 +1,262 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.idl + ~~~~~~~~~~~~~~~~~~~ + + Lexers for IDL. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, words +from pygments.token import Text, Comment, Operator, Keyword, Name, Number + +__all__ = ['IDLLexer'] + + +class IDLLexer(RegexLexer): + """ + Pygments Lexer for IDL (Interactive Data Language). + + .. versionadded:: 1.6 + """ + name = 'IDL' + aliases = ['idl'] + filenames = ['*.pro'] + mimetypes = ['text/idl'] + + flags = re.IGNORECASE | re.MULTILINE + + _RESERVED = ( + 'and', 'begin', 'break', 'case', 'common', 'compile_opt', + 'continue', 'do', 'else', 'end', 'endcase', 'elseelse', + 'endfor', 'endforeach', 'endif', 'endrep', 'endswitch', + 'endwhile', 'eq', 'for', 'foreach', 'forward_function', + 'function', 'ge', 'goto', 'gt', 'if', 'inherits', 'le', + 'lt', 'mod', 'ne', 'not', 'of', 'on_ioerror', 'or', 'pro', + 'repeat', 'switch', 'then', 'until', 'while', 'xor') + """Reserved words from: http://www.exelisvis.com/docs/reswords.html""" + + _BUILTIN_LIB = ( + 'abs', 'acos', 'adapt_hist_equal', 'alog', 'alog10', + 'amoeba', 'annotate', 'app_user_dir', 'app_user_dir_query', + 'arg_present', 'array_equal', 'array_indices', 'arrow', + 'ascii_template', 'asin', 'assoc', 'atan', 'axis', + 'a_correlate', 'bandpass_filter', 'bandreject_filter', + 'barplot', 'bar_plot', 'beseli', 'beselj', 'beselk', + 'besely', 'beta', 'bilinear', 'binary_template', 'bindgen', + 'binomial', 'bin_date', 'bit_ffs', 'bit_population', + 'blas_axpy', 'blk_con', 'box_cursor', 'breakpoint', + 'broyden', 'butterworth', 'bytarr', 'byte', 'byteorder', + 'bytscl', 'caldat', 'calendar', 'call_external', + 'call_function', 'call_method', 'call_procedure', 'canny', + 'catch', 'cd', 'cdf_\w*', 'ceil', 'chebyshev', + 'check_math', + 'chisqr_cvf', 'chisqr_pdf', 'choldc', 'cholsol', 'cindgen', + 'cir_3pnt', 'close', 'cluster', 'cluster_tree', 'clust_wts', + 'cmyk_convert', 'colorbar', 'colorize_sample', + 'colormap_applicable', 'colormap_gradient', + 'colormap_rotation', 'colortable', 'color_convert', + 'color_exchange', 'color_quan', 'color_range_map', 'comfit', + 'command_line_args', 'complex', 'complexarr', 'complexround', + 'compute_mesh_normals', 'cond', 'congrid', 'conj', + 'constrained_min', 'contour', 'convert_coord', 'convol', + 'convol_fft', 'coord2to3', 'copy_lun', 'correlate', 'cos', + 'cosh', 'cpu', 'cramer', 'create_cursor', 'create_struct', + 'create_view', 'crossp', 'crvlength', 'cti_test', + 'ct_luminance', 'cursor', 'curvefit', 'cvttobm', 'cv_coord', + 'cw_animate', 'cw_animate_getp', 'cw_animate_load', + 'cw_animate_run', 'cw_arcball', 'cw_bgroup', 'cw_clr_index', + 'cw_colorsel', 'cw_defroi', 'cw_field', 'cw_filesel', + 'cw_form', 'cw_fslider', 'cw_light_editor', + 'cw_light_editor_get', 'cw_light_editor_set', 'cw_orient', + 'cw_palette_editor', 'cw_palette_editor_get', + 'cw_palette_editor_set', 'cw_pdmenu', 'cw_rgbslider', + 'cw_tmpl', 'cw_zoom', 'c_correlate', 'dblarr', 'db_exists', + 'dcindgen', 'dcomplex', 'dcomplexarr', 'define_key', + 'define_msgblk', 'define_msgblk_from_file', 'defroi', + 'defsysv', 'delvar', 'dendrogram', 'dendro_plot', 'deriv', + 'derivsig', 'determ', 'device', 'dfpmin', 'diag_matrix', + 'dialog_dbconnect', 'dialog_message', 'dialog_pickfile', + 'dialog_printersetup', 'dialog_printjob', + 'dialog_read_image', 'dialog_write_image', 'digital_filter', + 'dilate', 'dindgen', 'dissolve', 'dist', 'distance_measure', + 'dlm_load', 'dlm_register', 'doc_library', 'double', + 'draw_roi', 'edge_dog', 'efont', 'eigenql', 'eigenvec', + 'ellipse', 'elmhes', 'emboss', 'empty', 'enable_sysrtn', + 'eof', 'eos_\w*', 'erase', 'erf', 'erfc', 'erfcx', + 'erode', 'errorplot', 'errplot', 'estimator_filter', + 'execute', 'exit', 'exp', 'expand', 'expand_path', 'expint', + 'extrac', 'extract_slice', 'factorial', 'fft', 'filepath', + 'file_basename', 'file_chmod', 'file_copy', 'file_delete', + 'file_dirname', 'file_expand_path', 'file_info', + 'file_lines', 'file_link', 'file_mkdir', 'file_move', + 'file_poll_input', 'file_readlink', 'file_same', + 'file_search', 'file_test', 'file_which', 'findgen', + 'finite', 'fix', 'flick', 'float', 'floor', 'flow3', + 'fltarr', 'flush', 'format_axis_values', 'free_lun', + 'fstat', 'fulstr', 'funct', 'fv_test', 'fx_root', + 'fz_roots', 'f_cvf', 'f_pdf', 'gamma', 'gamma_ct', + 'gauss2dfit', 'gaussfit', 'gaussian_function', 'gaussint', + 'gauss_cvf', 'gauss_pdf', 'gauss_smooth', 'getenv', + 'getwindows', 'get_drive_list', 'get_dxf_objects', + 'get_kbrd', 'get_login_info', 'get_lun', 'get_screen_size', + 'greg2jul', 'grib_\w*', 'grid3', 'griddata', + 'grid_input', 'grid_tps', 'gs_iter', + 'h5[adfgirst]_\w*', 'h5_browser', 'h5_close', + 'h5_create', 'h5_get_libversion', 'h5_open', 'h5_parse', + 'hanning', 'hash', 'hdf_\w*', 'heap_free', + 'heap_gc', 'heap_nosave', 'heap_refcount', 'heap_save', + 'help', 'hilbert', 'histogram', 'hist_2d', 'hist_equal', + 'hls', 'hough', 'hqr', 'hsv', 'h_eq_ct', 'h_eq_int', + 'i18n_multibytetoutf8', 'i18n_multibytetowidechar', + 'i18n_utf8tomultibyte', 'i18n_widechartomultibyte', + 'ibeta', 'icontour', 'iconvertcoord', 'idelete', 'identity', + 'idlexbr_assistant', 'idlitsys_createtool', 'idl_base64', + 'idl_validname', 'iellipse', 'igamma', 'igetcurrent', + 'igetdata', 'igetid', 'igetproperty', 'iimage', 'image', + 'image_cont', 'image_statistics', 'imaginary', 'imap', + 'indgen', 'intarr', 'interpol', 'interpolate', + 'interval_volume', 'int_2d', 'int_3d', 'int_tabulated', + 'invert', 'ioctl', 'iopen', 'iplot', 'ipolygon', + 'ipolyline', 'iputdata', 'iregister', 'ireset', 'iresolve', + 'irotate', 'ir_filter', 'isa', 'isave', 'iscale', + 'isetcurrent', 'isetproperty', 'ishft', 'isocontour', + 'isosurface', 'isurface', 'itext', 'itranslate', 'ivector', + 'ivolume', 'izoom', 'i_beta', 'journal', 'json_parse', + 'json_serialize', 'jul2greg', 'julday', 'keyword_set', + 'krig2d', 'kurtosis', 'kw_test', 'l64indgen', 'label_date', + 'label_region', 'ladfit', 'laguerre', 'laplacian', + 'la_choldc', 'la_cholmprove', 'la_cholsol', 'la_determ', + 'la_eigenproblem', 'la_eigenql', 'la_eigenvec', 'la_elmhes', + 'la_gm_linear_model', 'la_hqr', 'la_invert', + 'la_least_squares', 'la_least_square_equality', + 'la_linear_equation', 'la_ludc', 'la_lumprove', 'la_lusol', + 'la_svd', 'la_tridc', 'la_trimprove', 'la_triql', + 'la_trired', 'la_trisol', 'least_squares_filter', 'leefilt', + 'legend', 'legendre', 'linbcg', 'lindgen', 'linfit', + 'linkimage', 'list', 'll_arc_distance', 'lmfit', 'lmgr', + 'lngamma', 'lnp_test', 'loadct', 'locale_get', + 'logical_and', 'logical_or', 'logical_true', 'lon64arr', + 'lonarr', 'long', 'long64', 'lsode', 'ludc', 'lumprove', + 'lusol', 'lu_complex', 'machar', 'make_array', 'make_dll', + 'make_rt', 'map', 'mapcontinents', 'mapgrid', 'map_2points', + 'map_continents', 'map_grid', 'map_image', 'map_patch', + 'map_proj_forward', 'map_proj_image', 'map_proj_info', + 'map_proj_init', 'map_proj_inverse', 'map_set', + 'matrix_multiply', 'matrix_power', 'max', 'md_test', + 'mean', 'meanabsdev', 'mean_filter', 'median', 'memory', + 'mesh_clip', 'mesh_decimate', 'mesh_issolid', 'mesh_merge', + 'mesh_numtriangles', 'mesh_obj', 'mesh_smooth', + 'mesh_surfacearea', 'mesh_validate', 'mesh_volume', + 'message', 'min', 'min_curve_surf', 'mk_html_help', + 'modifyct', 'moment', 'morph_close', 'morph_distance', + 'morph_gradient', 'morph_hitormiss', 'morph_open', + 'morph_thin', 'morph_tophat', 'multi', 'm_correlate', + 'ncdf_\w*', 'newton', 'noise_hurl', 'noise_pick', + 'noise_scatter', 'noise_slur', 'norm', 'n_elements', + 'n_params', 'n_tags', 'objarr', 'obj_class', 'obj_destroy', + 'obj_hasmethod', 'obj_isa', 'obj_new', 'obj_valid', + 'online_help', 'on_error', 'open', 'oplot', 'oploterr', + 'parse_url', 'particle_trace', 'path_cache', 'path_sep', + 'pcomp', 'plot', 'plot3d', 'ploterr', 'plots', 'plot_3dbox', + 'plot_field', 'pnt_line', 'point_lun', 'polarplot', + 'polar_contour', 'polar_surface', 'poly', 'polyfill', + 'polyfillv', 'polygon', 'polyline', 'polyshade', 'polywarp', + 'poly_2d', 'poly_area', 'poly_fit', 'popd', 'powell', + 'pref_commit', 'pref_get', 'pref_set', 'prewitt', 'primes', + 'print', 'printd', 'product', 'profile', 'profiler', + 'profiles', 'project_vol', 'psafm', 'pseudo', + 'ps_show_fonts', 'ptrarr', 'ptr_free', 'ptr_new', + 'ptr_valid', 'pushd', 'p_correlate', 'qgrid3', 'qhull', + 'qromb', 'qromo', 'qsimp', 'query_ascii', 'query_bmp', + 'query_csv', 'query_dicom', 'query_gif', 'query_image', + 'query_jpeg', 'query_jpeg2000', 'query_mrsid', 'query_pict', + 'query_png', 'query_ppm', 'query_srf', 'query_tiff', + 'query_wav', 'radon', 'randomn', 'randomu', 'ranks', + 'rdpix', 'read', 'reads', 'readu', 'read_ascii', + 'read_binary', 'read_bmp', 'read_csv', 'read_dicom', + 'read_gif', 'read_image', 'read_interfile', 'read_jpeg', + 'read_jpeg2000', 'read_mrsid', 'read_pict', 'read_png', + 'read_ppm', 'read_spr', 'read_srf', 'read_sylk', + 'read_tiff', 'read_wav', 'read_wave', 'read_x11_bitmap', + 'read_xwd', 'real_part', 'rebin', 'recall_commands', + 'recon3', 'reduce_colors', 'reform', 'region_grow', + 'register_cursor', 'regress', 'replicate', + 'replicate_inplace', 'resolve_all', 'resolve_routine', + 'restore', 'retall', 'return', 'reverse', 'rk4', 'roberts', + 'rot', 'rotate', 'round', 'routine_filepath', + 'routine_info', 'rs_test', 'r_correlate', 'r_test', + 'save', 'savgol', 'scale3', 'scale3d', 'scope_level', + 'scope_traceback', 'scope_varfetch', 'scope_varname', + 'search2d', 'search3d', 'sem_create', 'sem_delete', + 'sem_lock', 'sem_release', 'setenv', 'set_plot', + 'set_shading', 'sfit', 'shade_surf', 'shade_surf_irr', + 'shade_volume', 'shift', 'shift_diff', 'shmdebug', 'shmmap', + 'shmunmap', 'shmvar', 'show3', 'showfont', 'simplex', 'sin', + 'sindgen', 'sinh', 'size', 'skewness', 'skip_lun', + 'slicer3', 'slide_image', 'smooth', 'sobel', 'socket', + 'sort', 'spawn', 'spher_harm', 'sph_4pnt', 'sph_scat', + 'spline', 'spline_p', 'spl_init', 'spl_interp', 'sprsab', + 'sprsax', 'sprsin', 'sprstp', 'sqrt', 'standardize', + 'stddev', 'stop', 'strarr', 'strcmp', 'strcompress', + 'streamline', 'stregex', 'stretch', 'string', 'strjoin', + 'strlen', 'strlowcase', 'strmatch', 'strmessage', 'strmid', + 'strpos', 'strput', 'strsplit', 'strtrim', 'struct_assign', + 'struct_hide', 'strupcase', 'surface', 'surfr', 'svdc', + 'svdfit', 'svsol', 'swap_endian', 'swap_endian_inplace', + 'symbol', 'systime', 's_test', 't3d', 'tag_names', 'tan', + 'tanh', 'tek_color', 'temporary', 'tetra_clip', + 'tetra_surface', 'tetra_volume', 'text', 'thin', 'threed', + 'timegen', 'time_test2', 'tm_test', 'total', 'trace', + 'transpose', 'triangulate', 'trigrid', 'triql', 'trired', + 'trisol', 'tri_surf', 'truncate_lun', 'ts_coef', 'ts_diff', + 'ts_fcast', 'ts_smooth', 'tv', 'tvcrs', 'tvlct', 'tvrd', + 'tvscl', 'typename', 't_cvt', 't_pdf', 'uindgen', 'uint', + 'uintarr', 'ul64indgen', 'ulindgen', 'ulon64arr', 'ulonarr', + 'ulong', 'ulong64', 'uniq', 'unsharp_mask', 'usersym', + 'value_locate', 'variance', 'vector', 'vector_field', 'vel', + 'velovect', 'vert_t3d', 'voigt', 'voronoi', 'voxel_proj', + 'wait', 'warp_tri', 'watershed', 'wdelete', 'wf_draw', + 'where', 'widget_base', 'widget_button', 'widget_combobox', + 'widget_control', 'widget_displaycontextmen', 'widget_draw', + 'widget_droplist', 'widget_event', 'widget_info', + 'widget_label', 'widget_list', 'widget_propertysheet', + 'widget_slider', 'widget_tab', 'widget_table', + 'widget_text', 'widget_tree', 'widget_tree_move', + 'widget_window', 'wiener_filter', 'window', 'writeu', + 'write_bmp', 'write_csv', 'write_gif', 'write_image', + 'write_jpeg', 'write_jpeg2000', 'write_nrif', 'write_pict', + 'write_png', 'write_ppm', 'write_spr', 'write_srf', + 'write_sylk', 'write_tiff', 'write_wav', 'write_wave', + 'wset', 'wshow', 'wtn', 'wv_applet', 'wv_cwt', + 'wv_cw_wavelet', 'wv_denoise', 'wv_dwt', 'wv_fn_coiflet', + 'wv_fn_daubechies', 'wv_fn_gaussian', 'wv_fn_haar', + 'wv_fn_morlet', 'wv_fn_paul', 'wv_fn_symlet', + 'wv_import_data', 'wv_import_wavelet', 'wv_plot3d_wps', + 'wv_plot_multires', 'wv_pwt', 'wv_tool_denoise', + 'xbm_edit', 'xdisplayfile', 'xdxf', 'xfont', + 'xinteranimate', 'xloadct', 'xmanager', 'xmng_tmpl', + 'xmtool', 'xobjview', 'xobjview_rotate', + 'xobjview_write_image', 'xpalette', 'xpcolor', 'xplot3d', + 'xregistered', 'xroi', 'xsq_test', 'xsurface', 'xvaredit', + 'xvolume', 'xvolume_rotate', 'xvolume_write_image', + 'xyouts', 'zoom', 'zoom_24') + """Functions from: http://www.exelisvis.com/docs/routines-1.html""" + + tokens = { + 'root': [ + (r'^\s*;.*?\n', Comment.Singleline), + (words(_RESERVED, prefix=r'\b', suffix=r'\b'), Keyword), + (words(_BUILTIN_LIB, prefix=r'\b', suffix=r'\b'), Name.Builtin), + (r'\+=|-=|\^=|\*=|/=|#=|##=|<=|>=|=', Operator), + (r'\+\+|--|->|\+|-|##|#|\*|/|<|>|&&|\^|~|\|\|\?|:', Operator), + (r'\b(mod=|lt=|le=|eq=|ne=|ge=|gt=|not=|and=|or=|xor=)', Operator), + (r'\b(mod|lt|le|eq|ne|ge|gt|not|and|or|xor)\b', Operator), + (r'\b[0-9](L|B|S|UL|ULL|LL)?\b', Number), + (r'.', Text), + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/igor.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/igor.py new file mode 100644 index 0000000000..dcf9770f57 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/igor.py @@ -0,0 +1,279 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.igor + ~~~~~~~~~~~~~~~~~~~~ + + Lexers for Igor Pro. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, words +from pygments.token import Text, Comment, Keyword, Name, String + +__all__ = ['IgorLexer'] + + +class IgorLexer(RegexLexer): + """ + Pygments Lexer for Igor Pro procedure files (.ipf). + See http://www.wavemetrics.com/ and http://www.igorexchange.com/. + + .. versionadded:: 2.0 + """ + + name = 'Igor' + aliases = ['igor', 'igorpro'] + filenames = ['*.ipf'] + mimetypes = ['text/ipf'] + + flags = re.IGNORECASE | re.MULTILINE + + flowControl = ( + 'if', 'else', 'elseif', 'endif', 'for', 'endfor', 'strswitch', 'switch', + 'case', 'default', 'endswitch', 'do', 'while', 'try', 'catch', 'endtry', + 'break', 'continue', 'return', + ) + types = ( + 'variable', 'string', 'constant', 'strconstant', 'NVAR', 'SVAR', 'WAVE', + 'STRUCT', 'dfref' + ) + keywords = ( + 'override', 'ThreadSafe', 'static', 'FuncFit', 'Proc', 'Picture', + 'Prompt', 'DoPrompt', 'macro', 'window', 'graph', 'function', 'end', + 'Structure', 'EndStructure', 'EndMacro', 'Menu', 'SubMenu', + ) + operations = ( + 'Abort', 'AddFIFOData', 'AddFIFOVectData', 'AddMovieAudio', + 'AddMovieFrame', 'APMath', 'Append', 'AppendImage', + 'AppendLayoutObject', 'AppendMatrixContour', 'AppendText', + 'AppendToGraph', 'AppendToLayout', 'AppendToTable', 'AppendXYZContour', + 'AutoPositionWindow', 'BackgroundInfo', 'Beep', 'BoundingBall', + 'BrowseURL', 'BuildMenu', 'Button', 'cd', 'Chart', 'CheckBox', + 'CheckDisplayed', 'ChooseColor', 'Close', 'CloseMovie', 'CloseProc', + 'ColorScale', 'ColorTab2Wave', 'Concatenate', 'ControlBar', + 'ControlInfo', 'ControlUpdate', 'ConvexHull', 'Convolve', 'CopyFile', + 'CopyFolder', 'CopyScales', 'Correlate', 'CreateAliasShortcut', 'Cross', + 'CtrlBackground', 'CtrlFIFO', 'CtrlNamedBackground', 'Cursor', + 'CurveFit', 'CustomControl', 'CWT', 'Debugger', 'DebuggerOptions', + 'DefaultFont', 'DefaultGuiControls', 'DefaultGuiFont', 'DefineGuide', + 'DelayUpdate', 'DeleteFile', 'DeleteFolder', 'DeletePoints', + 'Differentiate', 'dir', 'Display', 'DisplayHelpTopic', + 'DisplayProcedure', 'DoAlert', 'DoIgorMenu', 'DoUpdate', 'DoWindow', + 'DoXOPIdle', 'DrawAction', 'DrawArc', 'DrawBezier', 'DrawLine', + 'DrawOval', 'DrawPICT', 'DrawPoly', 'DrawRect', 'DrawRRect', 'DrawText', + 'DSPDetrend', 'DSPPeriodogram', 'Duplicate', 'DuplicateDataFolder', + 'DWT', 'EdgeStats', 'Edit', 'ErrorBars', 'Execute', 'ExecuteScriptText', + 'ExperimentModified', 'Extract', 'FastGaussTransform', 'FastOp', + 'FBinRead', 'FBinWrite', 'FFT', 'FIFO2Wave', 'FIFOStatus', 'FilterFIR', + 'FilterIIR', 'FindLevel', 'FindLevels', 'FindPeak', 'FindPointsInPoly', + 'FindRoots', 'FindSequence', 'FindValue', 'FPClustering', 'fprintf', + 'FReadLine', 'FSetPos', 'FStatus', 'FTPDelete', 'FTPDownload', + 'FTPUpload', 'FuncFit', 'FuncFitMD', 'GetAxis', 'GetFileFolderInfo', + 'GetLastUserMenuInfo', 'GetMarquee', 'GetSelection', 'GetWindow', + 'GraphNormal', 'GraphWaveDraw', 'GraphWaveEdit', 'Grep', 'GroupBox', + 'Hanning', 'HideIgorMenus', 'HideInfo', 'HideProcedures', 'HideTools', + 'HilbertTransform', 'Histogram', 'IFFT', 'ImageAnalyzeParticles', + 'ImageBlend', 'ImageBoundaryToMask', 'ImageEdgeDetection', + 'ImageFileInfo', 'ImageFilter', 'ImageFocus', 'ImageGenerateROIMask', + 'ImageHistModification', 'ImageHistogram', 'ImageInterpolate', + 'ImageLineProfile', 'ImageLoad', 'ImageMorphology', 'ImageRegistration', + 'ImageRemoveBackground', 'ImageRestore', 'ImageRotate', 'ImageSave', + 'ImageSeedFill', 'ImageSnake', 'ImageStats', 'ImageThreshold', + 'ImageTransform', 'ImageUnwrapPhase', 'ImageWindow', 'IndexSort', + 'InsertPoints', 'Integrate', 'IntegrateODE', 'Interp3DPath', + 'Interpolate3D', 'KillBackground', 'KillControl', 'KillDataFolder', + 'KillFIFO', 'KillFreeAxis', 'KillPath', 'KillPICTs', 'KillStrings', + 'KillVariables', 'KillWaves', 'KillWindow', 'KMeans', 'Label', 'Layout', + 'Legend', 'LinearFeedbackShiftRegister', 'ListBox', 'LoadData', + 'LoadPackagePreferences', 'LoadPICT', 'LoadWave', 'Loess', + 'LombPeriodogram', 'Make', 'MakeIndex', 'MarkPerfTestTime', + 'MatrixConvolve', 'MatrixCorr', 'MatrixEigenV', 'MatrixFilter', + 'MatrixGaussJ', 'MatrixInverse', 'MatrixLinearSolve', + 'MatrixLinearSolveTD', 'MatrixLLS', 'MatrixLUBkSub', 'MatrixLUD', + 'MatrixMultiply', 'MatrixOP', 'MatrixSchur', 'MatrixSolve', + 'MatrixSVBkSub', 'MatrixSVD', 'MatrixTranspose', 'MeasureStyledText', + 'Modify', 'ModifyContour', 'ModifyControl', 'ModifyControlList', + 'ModifyFreeAxis', 'ModifyGraph', 'ModifyImage', 'ModifyLayout', + 'ModifyPanel', 'ModifyTable', 'ModifyWaterfall', 'MoveDataFolder', + 'MoveFile', 'MoveFolder', 'MoveString', 'MoveSubwindow', 'MoveVariable', + 'MoveWave', 'MoveWindow', 'NeuralNetworkRun', 'NeuralNetworkTrain', + 'NewDataFolder', 'NewFIFO', 'NewFIFOChan', 'NewFreeAxis', 'NewImage', + 'NewLayout', 'NewMovie', 'NewNotebook', 'NewPanel', 'NewPath', + 'NewWaterfall', 'Note', 'Notebook', 'NotebookAction', 'Open', + 'OpenNotebook', 'Optimize', 'ParseOperationTemplate', 'PathInfo', + 'PauseForUser', 'PauseUpdate', 'PCA', 'PlayMovie', 'PlayMovieAction', + 'PlaySnd', 'PlaySound', 'PopupContextualMenu', 'PopupMenu', + 'Preferences', 'PrimeFactors', 'Print', 'printf', 'PrintGraphs', + 'PrintLayout', 'PrintNotebook', 'PrintSettings', 'PrintTable', + 'Project', 'PulseStats', 'PutScrapText', 'pwd', 'Quit', + 'RatioFromNumber', 'Redimension', 'Remove', 'RemoveContour', + 'RemoveFromGraph', 'RemoveFromLayout', 'RemoveFromTable', 'RemoveImage', + 'RemoveLayoutObjects', 'RemovePath', 'Rename', 'RenameDataFolder', + 'RenamePath', 'RenamePICT', 'RenameWindow', 'ReorderImages', + 'ReorderTraces', 'ReplaceText', 'ReplaceWave', 'Resample', + 'ResumeUpdate', 'Reverse', 'Rotate', 'Save', 'SaveData', + 'SaveExperiment', 'SaveGraphCopy', 'SaveNotebook', + 'SavePackagePreferences', 'SavePICT', 'SaveTableCopy', + 'SetActiveSubwindow', 'SetAxis', 'SetBackground', 'SetDashPattern', + 'SetDataFolder', 'SetDimLabel', 'SetDrawEnv', 'SetDrawLayer', + 'SetFileFolderInfo', 'SetFormula', 'SetIgorHook', 'SetIgorMenuMode', + 'SetIgorOption', 'SetMarquee', 'SetProcessSleep', 'SetRandomSeed', + 'SetScale', 'SetVariable', 'SetWaveLock', 'SetWindow', 'ShowIgorMenus', + 'ShowInfo', 'ShowTools', 'Silent', 'Sleep', 'Slider', 'Smooth', + 'SmoothCustom', 'Sort', 'SoundInRecord', 'SoundInSet', + 'SoundInStartChart', 'SoundInStatus', 'SoundInStopChart', + 'SphericalInterpolate', 'SphericalTriangulate', 'SplitString', + 'sprintf', 'sscanf', 'Stack', 'StackWindows', + 'StatsAngularDistanceTest', 'StatsANOVA1Test', 'StatsANOVA2NRTest', + 'StatsANOVA2RMTest', 'StatsANOVA2Test', 'StatsChiTest', + 'StatsCircularCorrelationTest', 'StatsCircularMeans', + 'StatsCircularMoments', 'StatsCircularTwoSampleTest', + 'StatsCochranTest', 'StatsContingencyTable', 'StatsDIPTest', + 'StatsDunnettTest', 'StatsFriedmanTest', 'StatsFTest', + 'StatsHodgesAjneTest', 'StatsJBTest', 'StatsKendallTauTest', + 'StatsKSTest', 'StatsKWTest', 'StatsLinearCorrelationTest', + 'StatsLinearRegression', 'StatsMultiCorrelationTest', + 'StatsNPMCTest', 'StatsNPNominalSRTest', 'StatsQuantiles', + 'StatsRankCorrelationTest', 'StatsResample', 'StatsSample', + 'StatsScheffeTest', 'StatsSignTest', 'StatsSRTest', 'StatsTTest', + 'StatsTukeyTest', 'StatsVariancesTest', 'StatsWatsonUSquaredTest', + 'StatsWatsonWilliamsTest', 'StatsWheelerWatsonTest', + 'StatsWilcoxonRankTest', 'StatsWRCorrelationTest', 'String', + 'StructGet', 'StructPut', 'TabControl', 'Tag', 'TextBox', 'Tile', + 'TileWindows', 'TitleBox', 'ToCommandLine', 'ToolsGrid', + 'Triangulate3d', 'Unwrap', 'ValDisplay', 'Variable', 'WaveMeanStdv', + 'WaveStats', 'WaveTransform', 'wfprintf', 'WignerTransform', + 'WindowFunction', + ) + functions = ( + 'abs', 'acos', 'acosh', 'AiryA', 'AiryAD', 'AiryB', 'AiryBD', 'alog', + 'area', 'areaXY', 'asin', 'asinh', 'atan', 'atan2', 'atanh', + 'AxisValFromPixel', 'Besseli', 'Besselj', 'Besselk', 'Bessely', 'bessi', + 'bessj', 'bessk', 'bessy', 'beta', 'betai', 'BinarySearch', + 'BinarySearchInterp', 'binomial', 'binomialln', 'binomialNoise', 'cabs', + 'CaptureHistoryStart', 'ceil', 'cequal', 'char2num', 'chebyshev', + 'chebyshevU', 'CheckName', 'cmplx', 'cmpstr', 'conj', 'ContourZ', 'cos', + 'cosh', 'cot', 'CountObjects', 'CountObjectsDFR', 'cpowi', + 'CreationDate', 'csc', 'DataFolderExists', 'DataFolderRefsEqual', + 'DataFolderRefStatus', 'date2secs', 'datetime', 'DateToJulian', + 'Dawson', 'DDEExecute', 'DDEInitiate', 'DDEPokeString', 'DDEPokeWave', + 'DDERequestWave', 'DDEStatus', 'DDETerminate', 'deltax', 'digamma', + 'DimDelta', 'DimOffset', 'DimSize', 'ei', 'enoise', 'equalWaves', 'erf', + 'erfc', 'exists', 'exp', 'expInt', 'expNoise', 'factorial', 'fakedata', + 'faverage', 'faverageXY', 'FindDimLabel', 'FindListItem', 'floor', + 'FontSizeHeight', 'FontSizeStringWidth', 'FresnelCos', 'FresnelSin', + 'gamma', 'gammaInc', 'gammaNoise', 'gammln', 'gammp', 'gammq', 'Gauss', + 'Gauss1D', 'Gauss2D', 'gcd', 'GetDefaultFontSize', + 'GetDefaultFontStyle', 'GetKeyState', 'GetRTError', 'gnoise', + 'GrepString', 'hcsr', 'hermite', 'hermiteGauss', 'HyperG0F1', + 'HyperG1F1', 'HyperG2F1', 'HyperGNoise', 'HyperGPFQ', 'IgorVersion', + 'ilim', 'imag', 'Inf', 'Integrate1D', 'interp', 'Interp2D', 'Interp3D', + 'inverseERF', 'inverseERFC', 'ItemsInList', 'jlim', 'Laguerre', + 'LaguerreA', 'LaguerreGauss', 'leftx', 'LegendreA', 'limit', 'ln', + 'log', 'logNormalNoise', 'lorentzianNoise', 'magsqr', 'MandelbrotPoint', + 'MarcumQ', 'MatrixDet', 'MatrixDot', 'MatrixRank', 'MatrixTrace', 'max', + 'mean', 'min', 'mod', 'ModDate', 'NaN', 'norm', 'NumberByKey', + 'numpnts', 'numtype', 'NumVarOrDefault', 'NVAR_Exists', 'p2rect', + 'ParamIsDefault', 'pcsr', 'Pi', 'PixelFromAxisVal', 'pnt2x', + 'poissonNoise', 'poly', 'poly2D', 'PolygonArea', 'qcsr', 'r2polar', + 'real', 'rightx', 'round', 'sawtooth', 'ScreenResolution', 'sec', + 'SelectNumber', 'sign', 'sin', 'sinc', 'sinh', 'SphericalBessJ', + 'SphericalBessJD', 'SphericalBessY', 'SphericalBessYD', + 'SphericalHarmonics', 'sqrt', 'StartMSTimer', 'StatsBetaCDF', + 'StatsBetaPDF', 'StatsBinomialCDF', 'StatsBinomialPDF', + 'StatsCauchyCDF', 'StatsCauchyPDF', 'StatsChiCDF', 'StatsChiPDF', + 'StatsCMSSDCDF', 'StatsCorrelation', 'StatsDExpCDF', 'StatsDExpPDF', + 'StatsErlangCDF', 'StatsErlangPDF', 'StatsErrorPDF', 'StatsEValueCDF', + 'StatsEValuePDF', 'StatsExpCDF', 'StatsExpPDF', 'StatsFCDF', + 'StatsFPDF', 'StatsFriedmanCDF', 'StatsGammaCDF', 'StatsGammaPDF', + 'StatsGeometricCDF', 'StatsGeometricPDF', 'StatsHyperGCDF', + 'StatsHyperGPDF', 'StatsInvBetaCDF', 'StatsInvBinomialCDF', + 'StatsInvCauchyCDF', 'StatsInvChiCDF', 'StatsInvCMSSDCDF', + 'StatsInvDExpCDF', 'StatsInvEValueCDF', 'StatsInvExpCDF', + 'StatsInvFCDF', 'StatsInvFriedmanCDF', 'StatsInvGammaCDF', + 'StatsInvGeometricCDF', 'StatsInvKuiperCDF', 'StatsInvLogisticCDF', + 'StatsInvLogNormalCDF', 'StatsInvMaxwellCDF', 'StatsInvMooreCDF', + 'StatsInvNBinomialCDF', 'StatsInvNCChiCDF', 'StatsInvNCFCDF', + 'StatsInvNormalCDF', 'StatsInvParetoCDF', 'StatsInvPoissonCDF', + 'StatsInvPowerCDF', 'StatsInvQCDF', 'StatsInvQpCDF', + 'StatsInvRayleighCDF', 'StatsInvRectangularCDF', 'StatsInvSpearmanCDF', + 'StatsInvStudentCDF', 'StatsInvTopDownCDF', 'StatsInvTriangularCDF', + 'StatsInvUsquaredCDF', 'StatsInvVonMisesCDF', 'StatsInvWeibullCDF', + 'StatsKuiperCDF', 'StatsLogisticCDF', 'StatsLogisticPDF', + 'StatsLogNormalCDF', 'StatsLogNormalPDF', 'StatsMaxwellCDF', + 'StatsMaxwellPDF', 'StatsMedian', 'StatsMooreCDF', 'StatsNBinomialCDF', + 'StatsNBinomialPDF', 'StatsNCChiCDF', 'StatsNCChiPDF', 'StatsNCFCDF', + 'StatsNCFPDF', 'StatsNCTCDF', 'StatsNCTPDF', 'StatsNormalCDF', + 'StatsNormalPDF', 'StatsParetoCDF', 'StatsParetoPDF', 'StatsPermute', + 'StatsPoissonCDF', 'StatsPoissonPDF', 'StatsPowerCDF', + 'StatsPowerNoise', 'StatsPowerPDF', 'StatsQCDF', 'StatsQpCDF', + 'StatsRayleighCDF', 'StatsRayleighPDF', 'StatsRectangularCDF', + 'StatsRectangularPDF', 'StatsRunsCDF', 'StatsSpearmanRhoCDF', + 'StatsStudentCDF', 'StatsStudentPDF', 'StatsTopDownCDF', + 'StatsTriangularCDF', 'StatsTriangularPDF', 'StatsTrimmedMean', + 'StatsUSquaredCDF', 'StatsVonMisesCDF', 'StatsVonMisesNoise', + 'StatsVonMisesPDF', 'StatsWaldCDF', 'StatsWaldPDF', 'StatsWeibullCDF', + 'StatsWeibullPDF', 'StopMSTimer', 'str2num', 'stringCRC', 'stringmatch', + 'strlen', 'strsearch', 'StudentA', 'StudentT', 'sum', 'SVAR_Exists', + 'TagVal', 'tan', 'tanh', 'ThreadGroupCreate', 'ThreadGroupRelease', + 'ThreadGroupWait', 'ThreadProcessorCount', 'ThreadReturnValue', 'ticks', + 'trunc', 'Variance', 'vcsr', 'WaveCRC', 'WaveDims', 'WaveExists', + 'WaveMax', 'WaveMin', 'WaveRefsEqual', 'WaveType', 'WhichListItem', + 'WinType', 'WNoise', 'x', 'x2pnt', 'xcsr', 'y', 'z', 'zcsr', 'ZernikeR', + ) + functions += ( + 'AddListItem', 'AnnotationInfo', 'AnnotationList', 'AxisInfo', + 'AxisList', 'CaptureHistory', 'ChildWindowList', 'CleanupName', + 'ContourInfo', 'ContourNameList', 'ControlNameList', 'CsrInfo', + 'CsrWave', 'CsrXWave', 'CTabList', 'DataFolderDir', 'date', + 'DDERequestString', 'FontList', 'FuncRefInfo', 'FunctionInfo', + 'FunctionList', 'FunctionPath', 'GetDataFolder', 'GetDefaultFont', + 'GetDimLabel', 'GetErrMessage', 'GetFormula', + 'GetIndependentModuleName', 'GetIndexedObjName', 'GetIndexedObjNameDFR', + 'GetRTErrMessage', 'GetRTStackInfo', 'GetScrapText', 'GetUserData', + 'GetWavesDataFolder', 'GrepList', 'GuideInfo', 'GuideNameList', 'Hash', + 'IgorInfo', 'ImageInfo', 'ImageNameList', 'IndexedDir', 'IndexedFile', + 'JulianToDate', 'LayoutInfo', 'ListMatch', 'LowerStr', 'MacroList', + 'NameOfWave', 'note', 'num2char', 'num2istr', 'num2str', + 'OperationList', 'PadString', 'ParseFilePath', 'PathList', 'PICTInfo', + 'PICTList', 'PossiblyQuoteName', 'ProcedureText', 'RemoveByKey', + 'RemoveEnding', 'RemoveFromList', 'RemoveListItem', + 'ReplaceNumberByKey', 'ReplaceString', 'ReplaceStringByKey', + 'Secs2Date', 'Secs2Time', 'SelectString', 'SortList', + 'SpecialCharacterInfo', 'SpecialCharacterList', 'SpecialDirPath', + 'StringByKey', 'StringFromList', 'StringList', 'StrVarOrDefault', + 'TableInfo', 'TextFile', 'ThreadGroupGetDF', 'time', 'TraceFromPixel', + 'TraceInfo', 'TraceNameList', 'UniqueName', 'UnPadString', 'UpperStr', + 'VariableList', 'WaveInfo', 'WaveList', 'WaveName', 'WaveUnits', + 'WinList', 'WinName', 'WinRecreation', 'XWaveName', + 'ContourNameToWaveRef', 'CsrWaveRef', 'CsrXWaveRef', + 'ImageNameToWaveRef', 'NewFreeWave', 'TagWaveRef', 'TraceNameToWaveRef', + 'WaveRefIndexed', 'XWaveRefFromTrace', 'GetDataFolderDFR', + 'GetWavesDataFolderDFR', 'NewFreeDataFolder', 'ThreadGroupGetDFR', + ) + + tokens = { + 'root': [ + (r'//.*$', Comment.Single), + (r'"([^"\\]|\\.)*"', String), + # Flow Control. + (words(flowControl, prefix=r'\b', suffix=r'\b'), Keyword), + # Types. + (words(types, prefix=r'\b', suffix=r'\b'), Keyword.Type), + # Keywords. + (words(keywords, prefix=r'\b', suffix=r'\b'), Keyword.Reserved), + # Built-in operations. + (words(operations, prefix=r'\b', suffix=r'\b'), Name.Class), + # Built-in functions. + (words(functions, prefix=r'\b', suffix=r'\b'), Name.Function), + # Compiler directives. + (r'^#(include|pragma|define|ifdef|ifndef|endif)', + Name.Decorator), + (r'[^a-z"/]+$', Text), + (r'.', Text), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/inferno.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/inferno.py new file mode 100644 index 0000000000..706be0c94a --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/inferno.py @@ -0,0 +1,96 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.inferno + ~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Inferno os and all the related stuff. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, default +from pygments.token import Punctuation, Text, Comment, Operator, Keyword, \ + Name, String, Number + +__all__ = ['LimboLexer'] + + +class LimboLexer(RegexLexer): + """ + Lexer for `Limbo programming language `_ + + TODO: + - maybe implement better var declaration highlighting + - some simple syntax error highlighting + + .. versionadded:: 2.0 + """ + name = 'Limbo' + aliases = ['limbo'] + filenames = ['*.b'] + mimetypes = ['text/limbo'] + + tokens = { + 'whitespace': [ + (r'^(\s*)([a-zA-Z_]\w*:(\s*)\n)', + bygroups(Text, Name.Label)), + (r'\n', Text), + (r'\s+', Text), + (r'#(\n|(.|\n)*?[^\\]\n)', Comment.Single), + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|' + r'u[a-fA-F0-9]{4}|U[a-fA-F0-9]{8}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\', String), # stray backslash + ], + 'statements': [ + (r'"', String, 'string'), + (r"'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+[fF])', Number.Float), + (r'16r[0-9a-fA-F]+', Number.Hex), + (r'8r[0-7]+', Number.Oct), + (r'((([1-3]\d)|([2-9]))r)?(\d+)', Number.Integer), + (r'[()\[\],.]', Punctuation), + (r'[~!%^&*+=|?:<>/-]|(->)|(<-)|(=>)|(::)', Operator), + (r'(alt|break|case|continue|cyclic|do|else|exit' + r'for|hd|if|implement|import|include|len|load|or' + r'pick|return|spawn|tagof|tl|to|while)\b', Keyword), + (r'(byte|int|big|real|string|array|chan|list|adt' + r'|fn|ref|of|module|self|type)\b', Keyword.Type), + (r'(con|iota|nil)\b', Keyword.Constant), + ('[a-zA-Z_]\w*', Name), + ], + 'statement' : [ + include('whitespace'), + include('statements'), + ('[{}]', Punctuation), + (';', Punctuation, '#pop'), + ], + 'root': [ + include('whitespace'), + default('statement'), + ], + } + + def analyse_text(text): + # Any limbo module implements something + if re.search(r'^implement \w+;', text, re.MULTILINE): + return 0.7 + +# TODO: +# - Make lexers for: +# - asm sources +# - man pages +# - mkfiles +# - module definitions +# - namespace definitions +# - shell scripts +# - maybe keyfiles and fonts +# they all seem to be quite similar to their equivalents +# from unix world, so there should not be a lot of problems diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/installers.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/installers.py new file mode 100644 index 0000000000..769bce6293 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/installers.py @@ -0,0 +1,322 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.installers + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for installer/packager DSLs and formats. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, using, this, default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Punctuation, Generic, Number, Whitespace + +__all__ = ['NSISLexer', 'RPMSpecLexer', 'SourcesListLexer', + 'DebianControlLexer'] + + +class NSISLexer(RegexLexer): + """ + For `NSIS `_ scripts. + + .. versionadded:: 1.6 + """ + name = 'NSIS' + aliases = ['nsis', 'nsi', 'nsh'] + filenames = ['*.nsi', '*.nsh'] + mimetypes = ['text/x-nsis'] + + flags = re.IGNORECASE + + tokens = { + 'root': [ + (r'[;#].*\n', Comment), + (r"'.*?'", String.Single), + (r'"', String.Double, 'str_double'), + (r'`', String.Backtick, 'str_backtick'), + include('macro'), + include('interpol'), + include('basic'), + (r'\$\{[a-z_|][\w|]*\}', Keyword.Pseudo), + (r'/[a-z_]\w*', Name.Attribute), + ('.', Text), + ], + 'basic': [ + (r'(\n)(Function)(\s+)([._a-z][.\w]*)\b', + bygroups(Text, Keyword, Text, Name.Function)), + (r'\b([_a-z]\w*)(::)([a-z][a-z0-9]*)\b', + bygroups(Keyword.Namespace, Punctuation, Name.Function)), + (r'\b([_a-z]\w*)(:)', bygroups(Name.Label, Punctuation)), + (r'(\b[ULS]|\B)([!<>=]?=|\<\>?|\>)\B', Operator), + (r'[|+-]', Operator), + (r'\\', Punctuation), + (r'\b(Abort|Add(?:BrandingImage|Size)|' + r'Allow(?:RootDirInstall|SkipFiles)|AutoCloseWindow|' + r'BG(?:Font|Gradient)|BrandingText|BringToFront|Call(?:InstDLL)?|' + r'(?:Sub)?Caption|ChangeUI|CheckBitmap|ClearErrors|CompletedText|' + r'ComponentText|CopyFiles|CRCCheck|' + r'Create(?:Directory|Font|Shortcut)|Delete(?:INI(?:Sec|Str)|' + r'Reg(?:Key|Value))?|DetailPrint|DetailsButtonText|' + r'Dir(?:Show|Text|Var|Verify)|(?:Disabled|Enabled)Bitmap|' + r'EnableWindow|EnumReg(?:Key|Value)|Exch|Exec(?:Shell|Wait)?|' + r'ExpandEnvStrings|File(?:BufSize|Close|ErrorText|Open|' + r'Read(?:Byte)?|Seek|Write(?:Byte)?)?|' + r'Find(?:Close|First|Next|Window)|FlushINI|Function(?:End)?|' + r'Get(?:CurInstType|CurrentAddress|DlgItem|DLLVersion(?:Local)?|' + r'ErrorLevel|FileTime(?:Local)?|FullPathName|FunctionAddress|' + r'InstDirError|LabelAddress|TempFileName)|' + r'Goto|HideWindow|Icon|' + r'If(?:Abort|Errors|FileExists|RebootFlag|Silent)|' + r'InitPluginsDir|Install(?:ButtonText|Colors|Dir(?:RegKey)?)|' + r'Inst(?:ProgressFlags|Type(?:[GS]etText)?)|Int(?:CmpU?|Fmt|Op)|' + r'IsWindow|LangString(?:UP)?|' + r'License(?:BkColor|Data|ForceSelection|LangString|Text)|' + r'LoadLanguageFile|LockWindow|Log(?:Set|Text)|MessageBox|' + r'MiscButtonText|Name|Nop|OutFile|(?:Uninst)?Page(?:Ex(?:End)?)?|' + r'PluginDir|Pop|Push|Quit|Read(?:(?:Env|INI|Reg)Str|RegDWORD)|' + r'Reboot|(?:Un)?RegDLL|Rename|RequestExecutionLevel|ReserveFile|' + r'Return|RMDir|SearchPath|Section(?:Divider|End|' + r'(?:(?:Get|Set)(?:Flags|InstTypes|Size|Text))|Group(?:End)?|In)?|' + r'SendMessage|Set(?:AutoClose|BrandingImage|Compress(?:ionLevel|' + r'or(?:DictSize)?)?|CtlColors|CurInstType|DatablockOptimize|' + r'DateSave|Details(?:Print|View)|Error(?:s|Level)|FileAttributes|' + r'Font|OutPath|Overwrite|PluginUnload|RebootFlag|ShellVarContext|' + r'Silent|StaticBkColor)|' + r'Show(?:(?:I|Uni)nstDetails|Window)|Silent(?:Un)?Install|Sleep|' + r'SpaceTexts|Str(?:CmpS?|Cpy|Len)|SubSection(?:End)?|' + r'Uninstall(?:ButtonText|(?:Sub)?Caption|EXEName|Icon|Text)|' + r'UninstPage|Var|VI(?:AddVersionKey|ProductVersion)|WindowIcon|' + r'Write(?:INIStr|Reg(:?Bin|DWORD|(?:Expand)?Str)|Uninstaller)|' + r'XPStyle)\b', Keyword), + (r'\b(CUR|END|(?:FILE_ATTRIBUTE_)?' + r'(?:ARCHIVE|HIDDEN|NORMAL|OFFLINE|READONLY|SYSTEM|TEMPORARY)|' + r'HK(CC|CR|CU|DD|LM|PD|U)|' + r'HKEY_(?:CLASSES_ROOT|CURRENT_(?:CONFIG|USER)|DYN_DATA|' + r'LOCAL_MACHINE|PERFORMANCE_DATA|USERS)|' + r'ID(?:ABORT|CANCEL|IGNORE|NO|OK|RETRY|YES)|' + r'MB_(?:ABORTRETRYIGNORE|DEFBUTTON[1-4]|' + r'ICON(?:EXCLAMATION|INFORMATION|QUESTION|STOP)|' + r'OK(?:CANCEL)?|RETRYCANCEL|RIGHT|SETFOREGROUND|TOPMOST|USERICON|' + r'YESNO(?:CANCEL)?)|SET|SHCTX|' + r'SW_(?:HIDE|SHOW(?:MAXIMIZED|MINIMIZED|NORMAL))|' + r'admin|all|auto|both|bottom|bzip2|checkbox|colored|current|false|' + r'force|hide|highest|if(?:diff|newer)|lastused|leave|left|' + r'listonly|lzma|nevershow|none|normal|off|on|pop|push|' + r'radiobuttons|right|show|silent|silentlog|smooth|textonly|top|' + r'true|try|user|zlib)\b', Name.Constant), + ], + 'macro': [ + (r'\!(addincludedir(?:dir)?|addplugindir|appendfile|cd|define|' + r'delfilefile|echo(?:message)?|else|endif|error|execute|' + r'if(?:macro)?n?(?:def)?|include|insertmacro|macro(?:end)?|packhdr|' + r'search(?:parse|replace)|system|tempfilesymbol|undef|verbose|' + r'warning)\b', Comment.Preproc), + ], + 'interpol': [ + (r'\$(R?[0-9])', Name.Builtin.Pseudo), # registers + (r'\$(ADMINTOOLS|APPDATA|CDBURN_AREA|COOKIES|COMMONFILES(?:32|64)|' + r'DESKTOP|DOCUMENTS|EXE(?:DIR|FILE|PATH)|FAVORITES|FONTS|HISTORY|' + r'HWNDPARENT|INTERNET_CACHE|LOCALAPPDATA|MUSIC|NETHOOD|PICTURES|' + r'PLUGINSDIR|PRINTHOOD|PROFILE|PROGRAMFILES(?:32|64)|QUICKLAUNCH|' + r'RECENT|RESOURCES(?:_LOCALIZED)?|SENDTO|SM(?:PROGRAMS|STARTUP)|' + r'STARTMENU|SYSDIR|TEMP(?:LATES)?|VIDEOS|WINDIR|\{NSISDIR\})', + Name.Builtin), + (r'\$(CMDLINE|INSTDIR|OUTDIR|LANGUAGE)', Name.Variable.Global), + (r'\$[a-z_]\w*', Name.Variable), + ], + 'str_double': [ + (r'"', String, '#pop'), + (r'\$(\\[nrt"]|\$)', String.Escape), + include('interpol'), + (r'.', String.Double), + ], + 'str_backtick': [ + (r'`', String, '#pop'), + (r'\$(\\[nrt"]|\$)', String.Escape), + include('interpol'), + (r'.', String.Double), + ], + } + + +class RPMSpecLexer(RegexLexer): + """ + For RPM ``.spec`` files. + + .. versionadded:: 1.6 + """ + + name = 'RPMSpec' + aliases = ['spec'] + filenames = ['*.spec'] + mimetypes = ['text/x-rpm-spec'] + + _directives = ('(?:package|prep|build|install|clean|check|pre[a-z]*|' + 'post[a-z]*|trigger[a-z]*|files)') + + tokens = { + 'root': [ + (r'#.*\n', Comment), + include('basic'), + ], + 'description': [ + (r'^(%' + _directives + ')(.*)$', + bygroups(Name.Decorator, Text), '#pop'), + (r'\n', Text), + (r'.', Text), + ], + 'changelog': [ + (r'\*.*\n', Generic.Subheading), + (r'^(%' + _directives + ')(.*)$', + bygroups(Name.Decorator, Text), '#pop'), + (r'\n', Text), + (r'.', Text), + ], + 'string': [ + (r'"', String.Double, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + include('interpol'), + (r'.', String.Double), + ], + 'basic': [ + include('macro'), + (r'(?i)^(Name|Version|Release|Epoch|Summary|Group|License|Packager|' + r'Vendor|Icon|URL|Distribution|Prefix|Patch[0-9]*|Source[0-9]*|' + r'Requires\(?[a-z]*\)?|[a-z]+Req|Obsoletes|Suggests|Provides|Conflicts|' + r'Build[a-z]+|[a-z]+Arch|Auto[a-z]+)(:)(.*)$', + bygroups(Generic.Heading, Punctuation, using(this))), + (r'^%description', Name.Decorator, 'description'), + (r'^%changelog', Name.Decorator, 'changelog'), + (r'^(%' + _directives + ')(.*)$', bygroups(Name.Decorator, Text)), + (r'%(attr|defattr|dir|doc(?:dir)?|setup|config(?:ure)?|' + r'make(?:install)|ghost|patch[0-9]+|find_lang|exclude|verify)', + Keyword), + include('interpol'), + (r"'.*?'", String.Single), + (r'"', String.Double, 'string'), + (r'.', Text), + ], + 'macro': [ + (r'%define.*\n', Comment.Preproc), + (r'%\{\!\?.*%define.*\}', Comment.Preproc), + (r'(%(?:if(?:n?arch)?|else(?:if)?|endif))(.*)$', + bygroups(Comment.Preproc, Text)), + ], + 'interpol': [ + (r'%\{?__[a-z_]+\}?', Name.Function), + (r'%\{?_([a-z_]+dir|[a-z_]+path|prefix)\}?', Keyword.Pseudo), + (r'%\{\?\w+\}', Name.Variable), + (r'\$\{?RPM_[A-Z0-9_]+\}?', Name.Variable.Global), + (r'%\{[a-zA-Z]\w+\}', Keyword.Constant), + ] + } + + +class SourcesListLexer(RegexLexer): + """ + Lexer that highlights debian sources.list files. + + .. versionadded:: 0.7 + """ + + name = 'Debian Sourcelist' + aliases = ['sourceslist', 'sources.list', 'debsources'] + filenames = ['sources.list'] + mimetype = ['application/x-debian-sourceslist'] + + tokens = { + 'root': [ + (r'\s+', Text), + (r'#.*?$', Comment), + (r'^(deb(?:-src)?)(\s+)', + bygroups(Keyword, Text), 'distribution') + ], + 'distribution': [ + (r'#.*?$', Comment, '#pop'), + (r'\$\(ARCH\)', Name.Variable), + (r'[^\s$[]+', String), + (r'\[', String.Other, 'escaped-distribution'), + (r'\$', String), + (r'\s+', Text, 'components') + ], + 'escaped-distribution': [ + (r'\]', String.Other, '#pop'), + (r'\$\(ARCH\)', Name.Variable), + (r'[^\]$]+', String.Other), + (r'\$', String.Other) + ], + 'components': [ + (r'#.*?$', Comment, '#pop:2'), + (r'$', Text, '#pop:2'), + (r'\s+', Text), + (r'\S+', Keyword.Pseudo), + ] + } + + def analyse_text(text): + for line in text.splitlines(): + line = line.strip() + if line.startswith('deb ') or line.startswith('deb-src '): + return True + + +class DebianControlLexer(RegexLexer): + """ + Lexer for Debian ``control`` files and ``apt-cache show `` outputs. + + .. versionadded:: 0.9 + """ + name = 'Debian Control file' + aliases = ['control', 'debcontrol'] + filenames = ['control'] + + tokens = { + 'root': [ + (r'^(Description)', Keyword, 'description'), + (r'^(Maintainer)(:\s*)', bygroups(Keyword, Text), 'maintainer'), + (r'^((Build-)?Depends)', Keyword, 'depends'), + (r'^((?:Python-)?Version)(:\s*)(\S+)$', + bygroups(Keyword, Text, Number)), + (r'^((?:Installed-)?Size)(:\s*)(\S+)$', + bygroups(Keyword, Text, Number)), + (r'^(MD5Sum|SHA1|SHA256)(:\s*)(\S+)$', + bygroups(Keyword, Text, Number)), + (r'^([a-zA-Z\-0-9\.]*?)(:\s*)(.*?)$', + bygroups(Keyword, Whitespace, String)), + ], + 'maintainer': [ + (r'<[^>]+>', Generic.Strong), + (r'<[^>]+>$', Generic.Strong, '#pop'), + (r',\n?', Text), + (r'.', Text), + ], + 'description': [ + (r'(.*)(Homepage)(: )(\S+)', + bygroups(Text, String, Name, Name.Class)), + (r':.*\n', Generic.Strong), + (r' .*\n', Text), + default('#pop'), + ], + 'depends': [ + (r':\s*', Text), + (r'(\$)(\{)(\w+\s*:\s*\w+)', bygroups(Operator, Text, Name.Entity)), + (r'\(', Text, 'depend_vers'), + (r',', Text), + (r'\|', Operator), + (r'[\s]+', Text), + (r'[})]\s*$', Text, '#pop'), + (r'\}', Text), + (r'[^,]$', Name.Function, '#pop'), + (r'([+.a-zA-Z0-9-])(\s*)', bygroups(Name.Function, Text)), + (r'\[.*?\]', Name.Entity), + ], + 'depend_vers': [ + (r'\),', Text, '#pop'), + (r'\)[^,]', Text, '#pop:2'), + (r'([><=]+)(\s*)([^)]+)', bygroups(Operator, Text, Number)) + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/int_fiction.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/int_fiction.py new file mode 100644 index 0000000000..7b004c2e74 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/int_fiction.py @@ -0,0 +1,1342 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.int_fiction + ~~~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for interactive fiction languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, using, \ + this, default, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error, Generic + +__all__ = ['Inform6Lexer', 'Inform6TemplateLexer', 'Inform7Lexer', + 'Tads3Lexer'] + + +class Inform6Lexer(RegexLexer): + """ + For `Inform 6 `_ source code. + + .. versionadded:: 2.0 + """ + + name = 'Inform 6' + aliases = ['inform6', 'i6'] + filenames = ['*.inf'] + + flags = re.MULTILINE | re.DOTALL | re.UNICODE + + _name = r'[a-zA-Z_]\w*' + + # Inform 7 maps these four character classes to their ASCII + # equivalents. To support Inform 6 inclusions within Inform 7, + # Inform6Lexer maps them too. + _dash = u'\\-\u2010-\u2014' + _dquote = u'"\u201c\u201d' + _squote = u"'\u2018\u2019" + _newline = u'\\n\u0085\u2028\u2029' + + tokens = { + 'root': [ + (r'\A(!%%[^%s]*[%s])+' % (_newline, _newline), Comment.Preproc, + 'directive'), + default('directive') + ], + '_whitespace': [ + (r'\s+', Text), + (r'![^%s]*' % _newline, Comment.Single) + ], + 'default': [ + include('_whitespace'), + (r'\[', Punctuation, 'many-values'), # Array initialization + (r':|(?=;)', Punctuation, '#pop'), + (r'<', Punctuation), # Second angle bracket in an action statement + default(('expression', '_expression')) + ], + + # Expressions + '_expression': [ + include('_whitespace'), + (r'(?=sp\b)', Text, '#pop'), + (r'(?=[%s%s$0-9#a-zA-Z_])' % (_dquote, _squote), Text, + ('#pop', 'value')), + (r'\+\+|[%s]{1,2}(?!>)|~~?' % _dash, Operator), + (r'(?=[()\[%s,?@{:;])' % _dash, Text, '#pop') + ], + 'expression': [ + include('_whitespace'), + (r'\(', Punctuation, ('expression', '_expression')), + (r'\)', Punctuation, '#pop'), + (r'\[', Punctuation, ('#pop', 'statements', 'locals')), + (r'>(?=(\s+|(![^%s]*))*[>;])' % _newline, Punctuation), + (r'\+\+|[%s]{2}(?!>)' % _dash, Operator), + (r',', Punctuation, '_expression'), + (r'&&?|\|\|?|[=~><]?=|[%s]{1,2}>?|\.\.?[&#]?|::|[<>+*/%%]' % _dash, + Operator, '_expression'), + (r'(has|hasnt|in|notin|ofclass|or|provides)\b', Operator.Word, + '_expression'), + (r'sp\b', Name), + (r'\?~?', Name.Label, 'label?'), + (r'[@{]', Error), + default('#pop') + ], + '_assembly-expression': [ + (r'\(', Punctuation, ('#push', '_expression')), + (r'[\[\]]', Punctuation), + (r'[%s]>' % _dash, Punctuation, '_expression'), + (r'sp\b', Keyword.Pseudo), + (r';', Punctuation, '#pop:3'), + include('expression') + ], + '_for-expression': [ + (r'\)', Punctuation, '#pop:2'), + (r':', Punctuation, '#pop'), + include('expression') + ], + '_keyword-expression': [ + (r'(from|near|to)\b', Keyword, '_expression'), + include('expression') + ], + '_list-expression': [ + (r',', Punctuation, '#pop'), + include('expression') + ], + '_object-expression': [ + (r'has\b', Keyword.Declaration, '#pop'), + include('_list-expression') + ], + + # Values + 'value': [ + include('_whitespace'), + # Strings + (r'[%s][^@][%s]' % (_squote, _squote), String.Char, '#pop'), + (r'([%s])(@\{[0-9a-fA-F]{1,4}\})([%s])' % (_squote, _squote), + bygroups(String.Char, String.Escape, String.Char), '#pop'), + (r'([%s])(@.{2})([%s])' % (_squote, _squote), + bygroups(String.Char, String.Escape, String.Char), '#pop'), + (r'[%s]' % _squote, String.Single, ('#pop', 'dictionary-word')), + (r'[%s]' % _dquote, String.Double, ('#pop', 'string')), + # Numbers + (r'\$[+%s][0-9]*\.?[0-9]*([eE][+%s]?[0-9]+)?' % (_dash, _dash), + Number.Float, '#pop'), + (r'\$[0-9a-fA-F]+', Number.Hex, '#pop'), + (r'\$\$[01]+', Number.Bin, '#pop'), + (r'[0-9]+', Number.Integer, '#pop'), + # Values prefixed by hashes + (r'(##|#a\$)(%s)' % _name, bygroups(Operator, Name), '#pop'), + (r'(#g\$)(%s)' % _name, + bygroups(Operator, Name.Variable.Global), '#pop'), + (r'#[nw]\$', Operator, ('#pop', 'obsolete-dictionary-word')), + (r'(#r\$)(%s)' % _name, bygroups(Operator, Name.Function), '#pop'), + (r'#', Name.Builtin, ('#pop', 'system-constant')), + # System functions + (words(( + 'child', 'children', 'elder', 'eldest', 'glk', 'indirect', 'metaclass', + 'parent', 'random', 'sibling', 'younger', 'youngest'), suffix=r'\b'), + Name.Builtin, '#pop'), + # Metaclasses + (r'(?i)(Class|Object|Routine|String)\b', Name.Builtin, '#pop'), + # Veneer routines + (words(( + 'Box__Routine', 'CA__Pr', 'CDefArt', 'CInDefArt', 'Cl__Ms', + 'Copy__Primitive', 'CP__Tab', 'DA__Pr', 'DB__Pr', 'DefArt', 'Dynam__String', + 'EnglishNumber', 'Glk__Wrap', 'IA__Pr', 'IB__Pr', 'InDefArt', 'Main__', + 'Meta__class', 'OB__Move', 'OB__Remove', 'OC__Cl', 'OP__Pr', 'Print__Addr', + 'Print__PName', 'PrintShortName', 'RA__Pr', 'RA__Sc', 'RL__Pr', 'R_Process', + 'RT__ChG', 'RT__ChGt', 'RT__ChLDB', 'RT__ChLDW', 'RT__ChPR', 'RT__ChPrintA', + 'RT__ChPrintC', 'RT__ChPrintO', 'RT__ChPrintS', 'RT__ChPS', 'RT__ChR', + 'RT__ChSTB', 'RT__ChSTW', 'RT__ChT', 'RT__Err', 'RT__TrPS', 'RV__Pr', + 'Symb__Tab', 'Unsigned__Compare', 'WV__Pr', 'Z__Region'), + prefix='(?i)', suffix=r'\b'), + Name.Builtin, '#pop'), + # Other built-in symbols + (words(( + 'call', 'copy', 'create', 'DEBUG', 'destroy', 'DICT_CHAR_SIZE', + 'DICT_ENTRY_BYTES', 'DICT_IS_UNICODE', 'DICT_WORD_SIZE', 'false', + 'FLOAT_INFINITY', 'FLOAT_NAN', 'FLOAT_NINFINITY', 'GOBJFIELD_CHAIN', + 'GOBJFIELD_CHILD', 'GOBJFIELD_NAME', 'GOBJFIELD_PARENT', + 'GOBJFIELD_PROPTAB', 'GOBJFIELD_SIBLING', 'GOBJ_EXT_START', + 'GOBJ_TOTAL_LENGTH', 'Grammar__Version', 'INDIV_PROP_START', 'INFIX', + 'infix__watching', 'MODULE_MODE', 'name', 'nothing', 'NUM_ATTR_BYTES', 'print', + 'print_to_array', 'recreate', 'remaining', 'self', 'sender', 'STRICT_MODE', + 'sw__var', 'sys__glob0', 'sys__glob1', 'sys__glob2', 'sys_statusline_flag', + 'TARGET_GLULX', 'TARGET_ZCODE', 'temp__global2', 'temp__global3', + 'temp__global4', 'temp_global', 'true', 'USE_MODULES', 'WORDSIZE'), + prefix='(?i)', suffix=r'\b'), + Name.Builtin, '#pop'), + # Other values + (_name, Name, '#pop') + ], + # Strings + 'dictionary-word': [ + (r'[~^]+', String.Escape), + (r'[^~^\\@({%s]+' % _squote, String.Single), + (r'[({]', String.Single), + (r'@\{[0-9a-fA-F]{,4}\}', String.Escape), + (r'@.{2}', String.Escape), + (r'[%s]' % _squote, String.Single, '#pop') + ], + 'string': [ + (r'[~^]+', String.Escape), + (r'[^~^\\@({%s]+' % _dquote, String.Double), + (r'[({]', String.Double), + (r'\\', String.Escape), + (r'@(\\\s*[%s]\s*)*@((\\\s*[%s]\s*)*[0-9])*' % + (_newline, _newline), String.Escape), + (r'@(\\\s*[%s]\s*)*\{((\\\s*[%s]\s*)*[0-9a-fA-F]){,4}' + r'(\\\s*[%s]\s*)*\}' % (_newline, _newline, _newline), + String.Escape), + (r'@(\\\s*[%s]\s*)*.(\\\s*[%s]\s*)*.' % (_newline, _newline), + String.Escape), + (r'[%s]' % _dquote, String.Double, '#pop') + ], + 'plain-string': [ + (r'[^~^\\({\[\]%s]+' % _dquote, String.Double), + (r'[~^({\[\]]', String.Double), + (r'\\', String.Escape), + (r'[%s]' % _dquote, String.Double, '#pop') + ], + # Names + '_constant': [ + include('_whitespace'), + (_name, Name.Constant, '#pop'), + include('value') + ], + '_global': [ + include('_whitespace'), + (_name, Name.Variable.Global, '#pop'), + include('value') + ], + 'label?': [ + include('_whitespace'), + (_name, Name.Label, '#pop'), + default('#pop') + ], + 'variable?': [ + include('_whitespace'), + (_name, Name.Variable, '#pop'), + default('#pop') + ], + # Values after hashes + 'obsolete-dictionary-word': [ + (r'\S\w*', String.Other, '#pop') + ], + 'system-constant': [ + include('_whitespace'), + (_name, Name.Builtin, '#pop') + ], + + # Directives + 'directive': [ + include('_whitespace'), + (r'#', Punctuation), + (r';', Punctuation, '#pop'), + (r'\[', Punctuation, + ('default', 'statements', 'locals', 'routine-name?')), + (words(( + 'abbreviate', 'endif', 'dictionary', 'ifdef', 'iffalse', 'ifndef', 'ifnot', + 'iftrue', 'ifv3', 'ifv5', 'release', 'serial', 'switches', 'system_file', + 'version'), prefix='(?i)', suffix=r'\b'), + Keyword, 'default'), + (r'(?i)(array|global)\b', Keyword, + ('default', 'directive-keyword?', '_global')), + (r'(?i)attribute\b', Keyword, ('default', 'alias?', '_constant')), + (r'(?i)class\b', Keyword, + ('object-body', 'duplicates', 'class-name')), + (r'(?i)(constant|default)\b', Keyword, + ('default', 'expression', '_constant')), + (r'(?i)(end\b)(.*)', bygroups(Keyword, Text)), + (r'(?i)(extend|verb)\b', Keyword, 'grammar'), + (r'(?i)fake_action\b', Keyword, ('default', '_constant')), + (r'(?i)import\b', Keyword, 'manifest'), + (r'(?i)(include|link)\b', Keyword, + ('default', 'before-plain-string')), + (r'(?i)(lowstring|undef)\b', Keyword, ('default', '_constant')), + (r'(?i)message\b', Keyword, ('default', 'diagnostic')), + (r'(?i)(nearby|object)\b', Keyword, + ('object-body', '_object-head')), + (r'(?i)property\b', Keyword, + ('default', 'alias?', '_constant', 'property-keyword*')), + (r'(?i)replace\b', Keyword, + ('default', 'routine-name?', 'routine-name?')), + (r'(?i)statusline\b', Keyword, ('default', 'directive-keyword?')), + (r'(?i)stub\b', Keyword, ('default', 'routine-name?')), + (r'(?i)trace\b', Keyword, + ('default', 'trace-keyword?', 'trace-keyword?')), + (r'(?i)zcharacter\b', Keyword, + ('default', 'directive-keyword?', 'directive-keyword?')), + (_name, Name.Class, ('object-body', '_object-head')) + ], + # [, Replace, Stub + 'routine-name?': [ + include('_whitespace'), + (_name, Name.Function, '#pop'), + default('#pop') + ], + 'locals': [ + include('_whitespace'), + (r';', Punctuation, '#pop'), + (r'\*', Punctuation), + (_name, Name.Variable) + ], + # Array + 'many-values': [ + include('_whitespace'), + (r';', Punctuation), + (r'\]', Punctuation, '#pop'), + (r':', Error), + default(('expression', '_expression')) + ], + # Attribute, Property + 'alias?': [ + include('_whitespace'), + (r'alias\b', Keyword, ('#pop', '_constant')), + default('#pop') + ], + # Class, Object, Nearby + 'class-name': [ + include('_whitespace'), + (r'(?=[,;]|(class|has|private|with)\b)', Text, '#pop'), + (_name, Name.Class, '#pop') + ], + 'duplicates': [ + include('_whitespace'), + (r'\(', Punctuation, ('#pop', 'expression', '_expression')), + default('#pop') + ], + '_object-head': [ + (r'[%s]>' % _dash, Punctuation), + (r'(class|has|private|with)\b', Keyword.Declaration, '#pop'), + include('_global') + ], + 'object-body': [ + include('_whitespace'), + (r';', Punctuation, '#pop:2'), + (r',', Punctuation), + (r'class\b', Keyword.Declaration, 'class-segment'), + (r'(has|private|with)\b', Keyword.Declaration), + (r':', Error), + default(('_object-expression', '_expression')) + ], + 'class-segment': [ + include('_whitespace'), + (r'(?=[,;]|(class|has|private|with)\b)', Text, '#pop'), + (_name, Name.Class), + default('value') + ], + # Extend, Verb + 'grammar': [ + include('_whitespace'), + (r'=', Punctuation, ('#pop', 'default')), + (r'\*', Punctuation, ('#pop', 'grammar-line')), + default('_directive-keyword') + ], + 'grammar-line': [ + include('_whitespace'), + (r';', Punctuation, '#pop'), + (r'[/*]', Punctuation), + (r'[%s]>' % _dash, Punctuation, 'value'), + (r'(noun|scope)\b', Keyword, '=routine'), + default('_directive-keyword') + ], + '=routine': [ + include('_whitespace'), + (r'=', Punctuation, 'routine-name?'), + default('#pop') + ], + # Import + 'manifest': [ + include('_whitespace'), + (r';', Punctuation, '#pop'), + (r',', Punctuation), + (r'(?i)global\b', Keyword, '_global'), + default('_global') + ], + # Include, Link, Message + 'diagnostic': [ + include('_whitespace'), + (r'[%s]' % _dquote, String.Double, ('#pop', 'message-string')), + default(('#pop', 'before-plain-string', 'directive-keyword?')) + ], + 'before-plain-string': [ + include('_whitespace'), + (r'[%s]' % _dquote, String.Double, ('#pop', 'plain-string')) + ], + 'message-string': [ + (r'[~^]+', String.Escape), + include('plain-string') + ], + + # Keywords used in directives + '_directive-keyword!': [ + include('_whitespace'), + (words(( + 'additive', 'alias', 'buffer', 'class', 'creature', 'data', 'error', 'fatalerror', + 'first', 'has', 'held', 'initial', 'initstr', 'last', 'long', 'meta', 'multi', + 'multiexcept', 'multiheld', 'multiinside', 'noun', 'number', 'only', 'private', + 'replace', 'reverse', 'scope', 'score', 'special', 'string', 'table', 'terminating', + 'time', 'topic', 'warning', 'with'), suffix=r'\b'), + Keyword, '#pop'), + (r'[%s]{1,2}>|[+=]' % _dash, Punctuation, '#pop') + ], + '_directive-keyword': [ + include('_directive-keyword!'), + include('value') + ], + 'directive-keyword?': [ + include('_directive-keyword!'), + default('#pop') + ], + 'property-keyword*': [ + include('_whitespace'), + (r'(additive|long)\b', Keyword), + default('#pop') + ], + 'trace-keyword?': [ + include('_whitespace'), + (words(( + 'assembly', 'dictionary', 'expressions', 'lines', 'linker', + 'objects', 'off', 'on', 'symbols', 'tokens', 'verbs'), suffix=r'\b'), + Keyword, '#pop'), + default('#pop') + ], + + # Statements + 'statements': [ + include('_whitespace'), + (r'\]', Punctuation, '#pop'), + (r'[;{}]', Punctuation), + (words(( + 'box', 'break', 'continue', 'default', 'give', 'inversion', + 'new_line', 'quit', 'read', 'remove', 'return', 'rfalse', 'rtrue', + 'spaces', 'string', 'until'), suffix=r'\b'), + Keyword, 'default'), + (r'(do|else)\b', Keyword), + (r'(font|style)\b', Keyword, + ('default', 'miscellaneous-keyword?')), + (r'for\b', Keyword, ('for', '(?')), + (r'(if|switch|while)', Keyword, + ('expression', '_expression', '(?')), + (r'(jump|save|restore)\b', Keyword, ('default', 'label?')), + (r'objectloop\b', Keyword, + ('_keyword-expression', 'variable?', '(?')), + (r'print(_ret)?\b|(?=[%s])' % _dquote, Keyword, 'print-list'), + (r'\.', Name.Label, 'label?'), + (r'@', Keyword, 'opcode'), + (r'#(?![agrnw]\$|#)', Punctuation, 'directive'), + (r'<', Punctuation, 'default'), + (r'move\b', Keyword, + ('default', '_keyword-expression', '_expression')), + default(('default', '_keyword-expression', '_expression')) + ], + 'miscellaneous-keyword?': [ + include('_whitespace'), + (r'(bold|fixed|from|near|off|on|reverse|roman|to|underline)\b', + Keyword, '#pop'), + (r'(a|A|an|address|char|name|number|object|property|string|the|' + r'The)\b(?=(\s+|(![^%s]*))*\))' % _newline, Keyword.Pseudo, + '#pop'), + (r'%s(?=(\s+|(![^%s]*))*\))' % (_name, _newline), Name.Function, + '#pop'), + default('#pop') + ], + '(?': [ + include('_whitespace'), + (r'\(', Punctuation, '#pop'), + default('#pop') + ], + 'for': [ + include('_whitespace'), + (r';', Punctuation, ('_for-expression', '_expression')), + default(('_for-expression', '_expression')) + ], + 'print-list': [ + include('_whitespace'), + (r';', Punctuation, '#pop'), + (r':', Error), + default(('_list-expression', '_expression', '_list-expression', 'form')) + ], + 'form': [ + include('_whitespace'), + (r'\(', Punctuation, ('#pop', 'miscellaneous-keyword?')), + default('#pop') + ], + + # Assembly + 'opcode': [ + include('_whitespace'), + (r'[%s]' % _dquote, String.Double, ('operands', 'plain-string')), + (_name, Keyword, 'operands') + ], + 'operands': [ + (r':', Error), + default(('_assembly-expression', '_expression')) + ] + } + + def get_tokens_unprocessed(self, text): + # 'in' is either a keyword or an operator. + # If the token two tokens after 'in' is ')', 'in' is a keyword: + # objectloop(a in b) + # Otherwise, it is an operator: + # objectloop(a in b && true) + objectloop_queue = [] + objectloop_token_count = -1 + previous_token = None + for index, token, value in RegexLexer.get_tokens_unprocessed(self, + text): + if previous_token is Name.Variable and value == 'in': + objectloop_queue = [[index, token, value]] + objectloop_token_count = 2 + elif objectloop_token_count > 0: + if token not in Comment and token not in Text: + objectloop_token_count -= 1 + objectloop_queue.append((index, token, value)) + else: + if objectloop_token_count == 0: + if objectloop_queue[-1][2] == ')': + objectloop_queue[0][1] = Keyword + while objectloop_queue: + yield objectloop_queue.pop(0) + objectloop_token_count = -1 + yield index, token, value + if token not in Comment and token not in Text: + previous_token = token + while objectloop_queue: + yield objectloop_queue.pop(0) + + +class Inform7Lexer(RegexLexer): + """ + For `Inform 7 `_ source code. + + .. versionadded:: 2.0 + """ + + name = 'Inform 7' + aliases = ['inform7', 'i7'] + filenames = ['*.ni', '*.i7x'] + + flags = re.MULTILINE | re.DOTALL | re.UNICODE + + _dash = Inform6Lexer._dash + _dquote = Inform6Lexer._dquote + _newline = Inform6Lexer._newline + _start = r'\A|(?<=[%s])' % _newline + + # There are three variants of Inform 7, differing in how to + # interpret at signs and braces in I6T. In top-level inclusions, at + # signs in the first column are inweb syntax. In phrase definitions + # and use options, tokens in braces are treated as I7. Use options + # also interpret "{N}". + tokens = {} + token_variants = ['+i6t-not-inline', '+i6t-inline', '+i6t-use-option'] + + for level in token_variants: + tokens[level] = { + '+i6-root': list(Inform6Lexer.tokens['root']), + '+i6t-root': [ # For Inform6TemplateLexer + (r'[^%s]*' % Inform6Lexer._newline, Comment.Preproc, + ('directive', '+p')) + ], + 'root': [ + (r'(\|?\s)+', Text), + (r'\[', Comment.Multiline, '+comment'), + (r'[%s]' % _dquote, Generic.Heading, + ('+main', '+titling', '+titling-string')), + default(('+main', '+heading?')) + ], + '+titling-string': [ + (r'[^%s]+' % _dquote, Generic.Heading), + (r'[%s]' % _dquote, Generic.Heading, '#pop') + ], + '+titling': [ + (r'\[', Comment.Multiline, '+comment'), + (r'[^%s.;:|%s]+' % (_dquote, _newline), Generic.Heading), + (r'[%s]' % _dquote, Generic.Heading, '+titling-string'), + (r'[%s]{2}|(?<=[\s%s])\|[\s%s]' % (_newline, _dquote, _dquote), + Text, ('#pop', '+heading?')), + (r'[.;:]|(?<=[\s%s])\|' % _dquote, Text, '#pop'), + (r'[|%s]' % _newline, Generic.Heading) + ], + '+main': [ + (r'(?i)[^%s:a\[(|%s]+' % (_dquote, _newline), Text), + (r'[%s]' % _dquote, String.Double, '+text'), + (r':', Text, '+phrase-definition'), + (r'(?i)\bas\b', Text, '+use-option'), + (r'\[', Comment.Multiline, '+comment'), + (r'(\([%s])(.*?)([%s]\))' % (_dash, _dash), + bygroups(Punctuation, + using(this, state=('+i6-root', 'directive'), + i6t='+i6t-not-inline'), Punctuation)), + (r'(%s|(?<=[\s;:.%s]))\|\s|[%s]{2,}' % + (_start, _dquote, _newline), Text, '+heading?'), + (r'(?i)[a(|%s]' % _newline, Text) + ], + '+phrase-definition': [ + (r'\s+', Text), + (r'\[', Comment.Multiline, '+comment'), + (r'(\([%s])(.*?)([%s]\))' % (_dash, _dash), + bygroups(Punctuation, + using(this, state=('+i6-root', 'directive', + 'default', 'statements'), + i6t='+i6t-inline'), Punctuation), '#pop'), + default('#pop') + ], + '+use-option': [ + (r'\s+', Text), + (r'\[', Comment.Multiline, '+comment'), + (r'(\([%s])(.*?)([%s]\))' % (_dash, _dash), + bygroups(Punctuation, + using(this, state=('+i6-root', 'directive'), + i6t='+i6t-use-option'), Punctuation), '#pop'), + default('#pop') + ], + '+comment': [ + (r'[^\[\]]+', Comment.Multiline), + (r'\[', Comment.Multiline, '#push'), + (r'\]', Comment.Multiline, '#pop') + ], + '+text': [ + (r'[^\[%s]+' % _dquote, String.Double), + (r'\[.*?\]', String.Interpol), + (r'[%s]' % _dquote, String.Double, '#pop') + ], + '+heading?': [ + (r'(\|?\s)+', Text), + (r'\[', Comment.Multiline, '+comment'), + (r'[%s]{4}\s+' % _dash, Text, '+documentation-heading'), + (r'[%s]{1,3}' % _dash, Text), + (r'(?i)(volume|book|part|chapter|section)\b[^%s]*' % _newline, + Generic.Heading, '#pop'), + default('#pop') + ], + '+documentation-heading': [ + (r'\s+', Text), + (r'\[', Comment.Multiline, '+comment'), + (r'(?i)documentation\s+', Text, '+documentation-heading2'), + default('#pop') + ], + '+documentation-heading2': [ + (r'\s+', Text), + (r'\[', Comment.Multiline, '+comment'), + (r'[%s]{4}\s' % _dash, Text, '+documentation'), + default('#pop:2') + ], + '+documentation': [ + (r'(?i)(%s)\s*(chapter|example)\s*:[^%s]*' % + (_start, _newline), Generic.Heading), + (r'(?i)(%s)\s*section\s*:[^%s]*' % (_start, _newline), + Generic.Subheading), + (r'((%s)\t.*?[%s])+' % (_start, _newline), + using(this, state='+main')), + (r'[^%s\[]+|[%s\[]' % (_newline, _newline), Text), + (r'\[', Comment.Multiline, '+comment'), + ], + '+i6t-not-inline': [ + (r'(%s)@c( .*?)?([%s]|\Z)' % (_start, _newline), + Comment.Preproc), + (r'(%s)@([%s]+|Purpose:)[^%s]*' % (_start, _dash, _newline), + Comment.Preproc), + (r'(%s)@p( .*?)?([%s]|\Z)' % (_start, _newline), + Generic.Heading, '+p') + ], + '+i6t-use-option': [ + include('+i6t-not-inline'), + (r'(\{)(N)(\})', bygroups(Punctuation, Text, Punctuation)) + ], + '+i6t-inline': [ + (r'(\{)(\S[^}]*)?(\})', + bygroups(Punctuation, using(this, state='+main'), + Punctuation)) + ], + '+i6t': [ + (r'(\{[%s])(![^}]*)(\}?)' % _dash, + bygroups(Punctuation, Comment.Single, Punctuation)), + (r'(\{[%s])(lines)(:)([^}]*)(\}?)' % _dash, + bygroups(Punctuation, Keyword, Punctuation, Text, + Punctuation), '+lines'), + (r'(\{[%s])([^:}]*)(:?)([^}]*)(\}?)' % _dash, + bygroups(Punctuation, Keyword, Punctuation, Text, + Punctuation)), + (r'(\(\+)(.*?)(\+\)|\Z)', + bygroups(Punctuation, using(this, state='+main'), + Punctuation)) + ], + '+p': [ + (r'[^@]+', Comment.Preproc), + (r'(%s)@c( .*?)?([%s]|\Z)' % (_start, _newline), + Comment.Preproc, '#pop'), + (r'(%s)@([%s]|Purpose:)' % (_start, _dash), Comment.Preproc), + (r'(%s)@p( .*?)?([%s]|\Z)' % (_start, _newline), + Generic.Heading), + (r'@', Comment.Preproc) + ], + '+lines': [ + (r'(%s)@c( .*?)?([%s]|\Z)' % (_start, _newline), + Comment.Preproc), + (r'(%s)@([%s]|Purpose:)[^%s]*' % (_start, _dash, _newline), + Comment.Preproc), + (r'(%s)@p( .*?)?([%s]|\Z)' % (_start, _newline), + Generic.Heading, '+p'), + (r'(%s)@\w*[ %s]' % (_start, _newline), Keyword), + (r'![^%s]*' % _newline, Comment.Single), + (r'(\{)([%s]endlines)(\})' % _dash, + bygroups(Punctuation, Keyword, Punctuation), '#pop'), + (r'[^@!{]+?([%s]|\Z)|.' % _newline, Text) + ] + } + # Inform 7 can include snippets of Inform 6 template language, + # so all of Inform6Lexer's states are copied here, with + # modifications to account for template syntax. Inform7Lexer's + # own states begin with '+' to avoid name conflicts. Some of + # Inform6Lexer's states begin with '_': these are not modified. + # They deal with template syntax either by including modified + # states, or by matching r'' then pushing to modified states. + for token in Inform6Lexer.tokens: + if token == 'root': + continue + tokens[level][token] = list(Inform6Lexer.tokens[token]) + if not token.startswith('_'): + tokens[level][token][:0] = [include('+i6t'), include(level)] + + def __init__(self, **options): + level = options.get('i6t', '+i6t-not-inline') + if level not in self._all_tokens: + self._tokens = self.__class__.process_tokendef(level) + else: + self._tokens = self._all_tokens[level] + RegexLexer.__init__(self, **options) + + +class Inform6TemplateLexer(Inform7Lexer): + """ + For `Inform 6 template + `_ code. + + .. versionadded:: 2.0 + """ + + name = 'Inform 6 template' + aliases = ['i6t'] + filenames = ['*.i6t'] + + def get_tokens_unprocessed(self, text, stack=('+i6t-root',)): + return Inform7Lexer.get_tokens_unprocessed(self, text, stack) + + +class Tads3Lexer(RegexLexer): + """ + For `TADS 3 `_ source code. + """ + + name = 'TADS 3' + aliases = ['tads3'] + filenames = ['*.t'] + + flags = re.DOTALL | re.MULTILINE + + _comment_single = r'(?://(?:[^\\\n]|\\+[\w\W])*$)' + _comment_multiline = r'(?:/\*(?:[^*]|\*(?!/))*\*/)' + _escape = (r'(?:\\(?:[\n\\<>"\'^v bnrt]|u[\da-fA-F]{,4}|x[\da-fA-F]{,2}|' + r'[0-3]?[0-7]{1,2}))') + _name = r'(?:[_a-zA-Z]\w*)' + _no_quote = r'(?=\s|\\?>)' + _operator = (r'(?:&&|\|\||\+\+|--|\?\?|::|[.,@\[\]~]|' + r'(?:[=+\-*/%!&|^]|<>?>?)=?)') + _ws = r'(?:\\|\s|%s|%s)' % (_comment_single, _comment_multiline) + _ws_pp = r'(?:\\\n|[^\S\n]|%s|%s)' % (_comment_single, _comment_multiline) + + def _make_string_state(triple, double, verbatim=None, _escape=_escape): + if verbatim: + verbatim = ''.join(['(?:%s|%s)' % (re.escape(c.lower()), + re.escape(c.upper())) + for c in verbatim]) + char = r'"' if double else r"'" + token = String.Double if double else String.Single + escaped_quotes = r'+|%s(?!%s{2})' % (char, char) if triple else r'' + prefix = '%s%s' % ('t' if triple else '', 'd' if double else 's') + tag_state_name = '%sqt' % prefix + state = [] + if triple: + state += [ + (r'%s{3,}' % char, token, '#pop'), + (r'\\%s+' % char, String.Escape), + (char, token) + ] + else: + state.append((char, token, '#pop')) + state += [ + include('s/verbatim'), + (r'[^\\<&{}%s]+' % char, token) + ] + if verbatim: + # This regex can't use `(?i)` because escape sequences are + # case-sensitive. `<\XMP>` works; `<\xmp>` doesn't. + state.append((r'\\?<(/|\\\\|(?!%s)\\)%s(?=[\s=>])' % + (_escape, verbatim), + Name.Tag, ('#pop', '%sqs' % prefix, tag_state_name))) + else: + state += [ + (r'\\?<\\%s]|<(?!<)|\\%s%s|%s|\\.)*>?' % + (char, char, escaped_quotes, _escape), Comment.Multiline), + (r'(?i)\\?]|\\>)', Name.Tag, + ('#pop', '%sqs/listing' % prefix, tag_state_name)), + (r'(?i)\\?]|\\>)', Name.Tag, + ('#pop', '%sqs/xmp' % prefix, tag_state_name)), + (r'\\?<([^\s=><\\%s]|<(?!<)|\\%s%s|%s|\\.)*' % + (char, char, escaped_quotes, _escape), Name.Tag, + tag_state_name), + include('s/entity') + ] + state += [ + include('s/escape'), + (r'\{([^}<\\%s]|<(?!<)|\\%s%s|%s|\\.)*\}' % + (char, char, escaped_quotes, _escape), String.Interpol), + (r'[\\&{}<]', token) + ] + return state + + def _make_tag_state(triple, double, _escape=_escape): + char = r'"' if double else r"'" + quantifier = r'{3,}' if triple else r'' + state_name = '%s%sqt' % ('t' if triple else '', 'd' if double else 's') + token = String.Double if double else String.Single + escaped_quotes = r'+|%s(?!%s{2})' % (char, char) if triple else r'' + return [ + (r'%s%s' % (char, quantifier), token, '#pop:2'), + (r'(\s|\\\n)+', Text), + (r'(=)(\\?")', bygroups(Punctuation, String.Double), + 'dqs/%s' % state_name), + (r"(=)(\\?')", bygroups(Punctuation, String.Single), + 'sqs/%s' % state_name), + (r'=', Punctuation, 'uqs/%s' % state_name), + (r'\\?>', Name.Tag, '#pop'), + (r'\{([^}<\\%s]|<(?!<)|\\%s%s|%s|\\.)*\}' % + (char, char, escaped_quotes, _escape), String.Interpol), + (r'([^\s=><\\%s]|<(?!<)|\\%s%s|%s|\\.)+' % + (char, char, escaped_quotes, _escape), Name.Attribute), + include('s/escape'), + include('s/verbatim'), + include('s/entity'), + (r'[\\{}&]', Name.Attribute) + ] + + def _make_attribute_value_state(terminator, host_triple, host_double, + _escape=_escape): + token = (String.Double if terminator == r'"' else + String.Single if terminator == r"'" else String.Other) + host_char = r'"' if host_double else r"'" + host_quantifier = r'{3,}' if host_triple else r'' + host_token = String.Double if host_double else String.Single + escaped_quotes = (r'+|%s(?!%s{2})' % (host_char, host_char) + if host_triple else r'') + return [ + (r'%s%s' % (host_char, host_quantifier), host_token, '#pop:3'), + (r'%s%s' % (r'' if token is String.Other else r'\\?', terminator), + token, '#pop'), + include('s/verbatim'), + include('s/entity'), + (r'\{([^}<\\%s]|<(?!<)|\\%s%s|%s|\\.)*\}' % + (host_char, host_char, escaped_quotes, _escape), String.Interpol), + (r'([^\s"\'<%s{}\\&])+' % (r'>' if token is String.Other else r''), + token), + include('s/escape'), + (r'["\'\s&{<}\\]', token) + ] + + tokens = { + 'root': [ + (u'\ufeff', Text), + (r'\{', Punctuation, 'object-body'), + (r';+', Punctuation), + (r'(?=(argcount|break|case|catch|continue|default|definingobj|' + r'delegated|do|else|for|foreach|finally|goto|if|inherited|' + r'invokee|local|nil|new|operator|replaced|return|self|switch|' + r'targetobj|targetprop|throw|true|try|while)\b)', Text, 'block'), + (r'(%s)(%s*)(\()' % (_name, _ws), + bygroups(Name.Function, using(this, state='whitespace'), + Punctuation), + ('block?/root', 'more/parameters', 'main/parameters')), + include('whitespace'), + (r'\++', Punctuation), + (r'[^\s!"%-(*->@-_a-z{-~]+', Error), # Averts an infinite loop + (r'(?!\Z)', Text, 'main/root') + ], + 'main/root': [ + include('main/basic'), + default(('#pop', 'object-body/no-braces', 'classes', 'class')) + ], + 'object-body/no-braces': [ + (r';', Punctuation, '#pop'), + (r'\{', Punctuation, ('#pop', 'object-body')), + include('object-body') + ], + 'object-body': [ + (r';', Punctuation), + (r'\{', Punctuation, '#push'), + (r'\}', Punctuation, '#pop'), + (r':', Punctuation, ('classes', 'class')), + (r'(%s?)(%s*)(\()' % (_name, _ws), + bygroups(Name.Function, using(this, state='whitespace'), + Punctuation), + ('block?', 'more/parameters', 'main/parameters')), + (r'(%s)(%s*)(\{)' % (_name, _ws), + bygroups(Name.Function, using(this, state='whitespace'), + Punctuation), 'block'), + (r'(%s)(%s*)(:)' % (_name, _ws), + bygroups(Name.Variable, using(this, state='whitespace'), + Punctuation), + ('object-body/no-braces', 'classes', 'class')), + include('whitespace'), + (r'->|%s' % _operator, Punctuation, 'main'), + default('main/object-body') + ], + 'main/object-body': [ + include('main/basic'), + (r'(%s)(%s*)(=?)' % (_name, _ws), + bygroups(Name.Variable, using(this, state='whitespace'), + Punctuation), ('#pop', 'more', 'main')), + default('#pop:2') + ], + 'block?/root': [ + (r'\{', Punctuation, ('#pop', 'block')), + include('whitespace'), + (r'(?=[[\'"<(:])', Text, # It might be a VerbRule macro. + ('#pop', 'object-body/no-braces', 'grammar', 'grammar-rules')), + # It might be a macro like DefineAction. + default(('#pop', 'object-body/no-braces')) + ], + 'block?': [ + (r'\{', Punctuation, ('#pop', 'block')), + include('whitespace'), + default('#pop') + ], + 'block/basic': [ + (r'[;:]+', Punctuation), + (r'\{', Punctuation, '#push'), + (r'\}', Punctuation, '#pop'), + (r'default\b', Keyword.Reserved), + (r'(%s)(%s*)(:)' % (_name, _ws), + bygroups(Name.Label, using(this, state='whitespace'), + Punctuation)), + include('whitespace') + ], + 'block': [ + include('block/basic'), + (r'(?!\Z)', Text, ('more', 'main')) + ], + 'block/embed': [ + (r'>>', String.Interpol, '#pop'), + include('block/basic'), + (r'(?!\Z)', Text, ('more/embed', 'main')) + ], + 'main/basic': [ + include('whitespace'), + (r'\(', Punctuation, ('#pop', 'more', 'main')), + (r'\[', Punctuation, ('#pop', 'more/list', 'main')), + (r'\{', Punctuation, ('#pop', 'more/inner', 'main/inner', + 'more/parameters', 'main/parameters')), + (r'\*|\.{3}', Punctuation, '#pop'), + (r'(?i)0x[\da-f]+', Number.Hex, '#pop'), + (r'(\d+\.(?!\.)\d*|\.\d+)([eE][-+]?\d+)?|\d+[eE][-+]?\d+', + Number.Float, '#pop'), + (r'0[0-7]+', Number.Oct, '#pop'), + (r'\d+', Number.Integer, '#pop'), + (r'"""', String.Double, ('#pop', 'tdqs')), + (r"'''", String.Single, ('#pop', 'tsqs')), + (r'"', String.Double, ('#pop', 'dqs')), + (r"'", String.Single, ('#pop', 'sqs')), + (r'R"""', String.Regex, ('#pop', 'tdqr')), + (r"R'''", String.Regex, ('#pop', 'tsqr')), + (r'R"', String.Regex, ('#pop', 'dqr')), + (r"R'", String.Regex, ('#pop', 'sqr')), + # Two-token keywords + (r'(extern)(%s+)(object\b)' % _ws, + bygroups(Keyword.Reserved, using(this, state='whitespace'), + Keyword.Reserved)), + (r'(function|method)(%s*)(\()' % _ws, + bygroups(Keyword.Reserved, using(this, state='whitespace'), + Punctuation), + ('#pop', 'block?', 'more/parameters', 'main/parameters')), + (r'(modify)(%s+)(grammar\b)' % _ws, + bygroups(Keyword.Reserved, using(this, state='whitespace'), + Keyword.Reserved), + ('#pop', 'object-body/no-braces', ':', 'grammar')), + (r'(new)(%s+(?=(?:function|method)\b))' % _ws, + bygroups(Keyword.Reserved, using(this, state='whitespace'))), + (r'(object)(%s+)(template\b)' % _ws, + bygroups(Keyword.Reserved, using(this, state='whitespace'), + Keyword.Reserved), ('#pop', 'template')), + (r'(string)(%s+)(template\b)' % _ws, + bygroups(Keyword, using(this, state='whitespace'), + Keyword.Reserved), ('#pop', 'function-name')), + # Keywords + (r'(argcount|definingobj|invokee|replaced|targetobj|targetprop)\b', + Name.Builtin, '#pop'), + (r'(break|continue|goto)\b', Keyword.Reserved, ('#pop', 'label')), + (r'(case|extern|if|intrinsic|return|static|while)\b', + Keyword.Reserved), + (r'catch\b', Keyword.Reserved, ('#pop', 'catch')), + (r'class\b', Keyword.Reserved, + ('#pop', 'object-body/no-braces', 'class')), + (r'(default|do|else|finally|try)\b', Keyword.Reserved, '#pop'), + (r'(dictionary|property)\b', Keyword.Reserved, + ('#pop', 'constants')), + (r'enum\b', Keyword.Reserved, ('#pop', 'enum')), + (r'export\b', Keyword.Reserved, ('#pop', 'main')), + (r'(for|foreach)\b', Keyword.Reserved, + ('#pop', 'more/inner', 'main/inner')), + (r'(function|method)\b', Keyword.Reserved, + ('#pop', 'block?', 'function-name')), + (r'grammar\b', Keyword.Reserved, + ('#pop', 'object-body/no-braces', 'grammar')), + (r'inherited\b', Keyword.Reserved, ('#pop', 'inherited')), + (r'local\b', Keyword.Reserved, + ('#pop', 'more/local', 'main/local')), + (r'(modify|replace|switch|throw|transient)\b', Keyword.Reserved, + '#pop'), + (r'new\b', Keyword.Reserved, ('#pop', 'class')), + (r'(nil|true)\b', Keyword.Constant, '#pop'), + (r'object\b', Keyword.Reserved, ('#pop', 'object-body/no-braces')), + (r'operator\b', Keyword.Reserved, ('#pop', 'operator')), + (r'propertyset\b', Keyword.Reserved, + ('#pop', 'propertyset', 'main')), + (r'self\b', Name.Builtin.Pseudo, '#pop'), + (r'template\b', Keyword.Reserved, ('#pop', 'template')), + # Operators + (r'(__objref|defined)(%s*)(\()' % _ws, + bygroups(Operator.Word, using(this, state='whitespace'), + Operator), ('#pop', 'more/__objref', 'main')), + (r'delegated\b', Operator.Word), + # Compiler-defined macros and built-in properties + (r'(__DATE__|__DEBUG|__LINE__|__FILE__|' + r'__TADS_MACRO_FORMAT_VERSION|__TADS_SYS_\w*|__TADS_SYSTEM_NAME|' + r'__TADS_VERSION_MAJOR|__TADS_VERSION_MINOR|__TADS3|__TIME__|' + r'construct|finalize|grammarInfo|grammarTag|lexicalParent|' + r'miscVocab|sourceTextGroup|sourceTextGroupName|' + r'sourceTextGroupOrder|sourceTextOrder)\b', Name.Builtin, '#pop') + ], + 'main': [ + include('main/basic'), + (_name, Name, '#pop'), + default('#pop') + ], + 'more/basic': [ + (r'\(', Punctuation, ('more/list', 'main')), + (r'\[', Punctuation, ('more', 'main')), + (r'\.{3}', Punctuation), + (r'->|\.\.', Punctuation, 'main'), + (r'(?=;)|[:)\]]', Punctuation, '#pop'), + include('whitespace'), + (_operator, Operator, 'main'), + (r'\?', Operator, ('main', 'more/conditional', 'main')), + (r'(is|not)(%s+)(in\b)' % _ws, + bygroups(Operator.Word, using(this, state='whitespace'), + Operator.Word)), + (r'[^\s!"%-_a-z{-~]+', Error) # Averts an infinite loop + ], + 'more': [ + include('more/basic'), + default('#pop') + ], + # Then expression (conditional operator) + 'more/conditional': [ + (r':(?!:)', Operator, '#pop'), + include('more') + ], + # Embedded expressions + 'more/embed': [ + (r'>>', String.Interpol, '#pop:2'), + include('more') + ], + # For/foreach loop initializer or short-form anonymous function + 'main/inner': [ + (r'\(', Punctuation, ('#pop', 'more/inner', 'main/inner')), + (r'local\b', Keyword.Reserved, ('#pop', 'main/local')), + include('main') + ], + 'more/inner': [ + (r'\}', Punctuation, '#pop'), + (r',', Punctuation, 'main/inner'), + (r'(in|step)\b', Keyword, 'main/inner'), + include('more') + ], + # Local + 'main/local': [ + (_name, Name.Variable, '#pop'), + include('whitespace') + ], + 'more/local': [ + (r',', Punctuation, 'main/local'), + include('more') + ], + # List + 'more/list': [ + (r'[,:]', Punctuation, 'main'), + include('more') + ], + # Parameter list + 'main/parameters': [ + (r'(%s)(%s*)(?=:)' % (_name, _ws), + bygroups(Name.Variable, using(this, state='whitespace')), '#pop'), + (r'(%s)(%s+)(%s)' % (_name, _ws, _name), + bygroups(Name.Class, using(this, state='whitespace'), + Name.Variable), '#pop'), + (r'\[+', Punctuation), + include('main/basic'), + (_name, Name.Variable, '#pop'), + default('#pop') + ], + 'more/parameters': [ + (r'(:)(%s*(?=[?=,:)]))' % _ws, + bygroups(Punctuation, using(this, state='whitespace'))), + (r'[?\]]+', Punctuation), + (r'[:)]', Punctuation, ('#pop', 'multimethod?')), + (r',', Punctuation, 'main/parameters'), + (r'=', Punctuation, ('more/parameter', 'main')), + include('more') + ], + 'more/parameter': [ + (r'(?=[,)])', Text, '#pop'), + include('more') + ], + 'multimethod?': [ + (r'multimethod\b', Keyword, '#pop'), + include('whitespace'), + default('#pop') + ], + + # Statements and expressions + 'more/__objref': [ + (r',', Punctuation, 'mode'), + (r'\)', Operator, '#pop'), + include('more') + ], + 'mode': [ + (r'(error|warn)\b', Keyword, '#pop'), + include('whitespace') + ], + 'catch': [ + (r'\(+', Punctuation), + (_name, Name.Exception, ('#pop', 'variables')), + include('whitespace') + ], + 'enum': [ + include('whitespace'), + (r'token\b', Keyword, ('#pop', 'constants')), + default(('#pop', 'constants')) + ], + 'grammar': [ + (r'\)+', Punctuation), + (r'\(', Punctuation, 'grammar-tag'), + (r':', Punctuation, 'grammar-rules'), + (_name, Name.Class), + include('whitespace') + ], + 'grammar-tag': [ + include('whitespace'), + (r'"""([^\\"<]|""?(?!")|\\"+|\\.|<(?!<))+("{3,}|<<)|' + r'R"""([^\\"]|""?(?!")|\\"+|\\.)+"{3,}|' + r"'''([^\\'<]|''?(?!')|\\'+|\\.|<(?!<))+('{3,}|<<)|" + r"R'''([^\\']|''?(?!')|\\'+|\\.)+'{3,}|" + r'"([^\\"<]|\\.|<(?!<))+("|<<)|R"([^\\"]|\\.)+"|' + r"'([^\\'<]|\\.|<(?!<))+('|<<)|R'([^\\']|\\.)+'|" + r"([^)\s\\/]|/(?![/*]))+|\)", String.Other, '#pop') + ], + 'grammar-rules': [ + include('string'), + include('whitespace'), + (r'(\[)(%s*)(badness)' % _ws, + bygroups(Punctuation, using(this, state='whitespace'), Keyword), + 'main'), + (r'->|%s|[()]' % _operator, Punctuation), + (_name, Name.Constant), + default('#pop:2') + ], + ':': [ + (r':', Punctuation, '#pop') + ], + 'function-name': [ + (r'(<<([^>]|>>>|>(?!>))*>>)+', String.Interpol), + (r'(?=%s?%s*[({])' % (_name, _ws), Text, '#pop'), + (_name, Name.Function, '#pop'), + include('whitespace') + ], + 'inherited': [ + (r'<', Punctuation, ('#pop', 'classes', 'class')), + include('whitespace'), + (_name, Name.Class, '#pop'), + default('#pop') + ], + 'operator': [ + (r'negate\b', Operator.Word, '#pop'), + include('whitespace'), + (_operator, Operator), + default('#pop') + ], + 'propertyset': [ + (r'\(', Punctuation, ('more/parameters', 'main/parameters')), + (r'\{', Punctuation, ('#pop', 'object-body')), + include('whitespace') + ], + 'template': [ + (r'(?=;)', Text, '#pop'), + include('string'), + (r'inherited\b', Keyword.Reserved), + include('whitespace'), + (r'->|\?|%s' % _operator, Punctuation), + (_name, Name.Variable) + ], + + # Identifiers + 'class': [ + (r'\*|\.{3}', Punctuation, '#pop'), + (r'object\b', Keyword.Reserved, '#pop'), + (r'transient\b', Keyword.Reserved), + (_name, Name.Class, '#pop'), + include('whitespace'), + default('#pop') + ], + 'classes': [ + (r'[:,]', Punctuation, 'class'), + include('whitespace'), + (r'>', Punctuation, '#pop'), + default('#pop') + ], + 'constants': [ + (r',+', Punctuation), + (r';', Punctuation, '#pop'), + (r'property\b', Keyword.Reserved), + (_name, Name.Constant), + include('whitespace') + ], + 'label': [ + (_name, Name.Label, '#pop'), + include('whitespace'), + default('#pop') + ], + 'variables': [ + (r',+', Punctuation), + (r'\)', Punctuation, '#pop'), + include('whitespace'), + (_name, Name.Variable) + ], + + # Whitespace and comments + 'whitespace': [ + (r'^%s*#(%s|[^\n]|(?<=\\)\n)*\n?' % (_ws_pp, _comment_multiline), + Comment.Preproc), + (_comment_single, Comment.Single), + (_comment_multiline, Comment.Multiline), + (r'\\+\n+%s*#?|\n+|([^\S\n]|\\)+' % _ws_pp, Text) + ], + + # Strings + 'string': [ + (r'"""', String.Double, 'tdqs'), + (r"'''", String.Single, 'tsqs'), + (r'"', String.Double, 'dqs'), + (r"'", String.Single, 'sqs') + ], + 's/escape': [ + (r'\{\{|\}\}|%s' % _escape, String.Escape) + ], + 's/verbatim': [ + (r'<<\s*(as\s+decreasingly\s+likely\s+outcomes|cycling|else|end|' + r'first\s+time|one\s+of|only|or|otherwise|' + r'(sticky|(then\s+)?(purely\s+)?at)\s+random|stopping|' + r'(then\s+)?(half\s+)?shuffled|\|\|)\s*>>', String.Interpol), + (r'<<(%%(_(%s|\\?.)|[\-+ ,#]|\[\d*\]?)*\d*\.?\d*(%s|\\?.)|' + r'\s*((else|otherwise)\s+)?(if|unless)\b)?' % (_escape, _escape), + String.Interpol, ('block/embed', 'more/embed', 'main')) + ], + 's/entity': [ + (r'(?i)&(#(x[\da-f]+|\d+)|[a-z][\da-z]*);?', Name.Entity) + ], + 'tdqs': _make_string_state(True, True), + 'tsqs': _make_string_state(True, False), + 'dqs': _make_string_state(False, True), + 'sqs': _make_string_state(False, False), + 'tdqs/listing': _make_string_state(True, True, 'listing'), + 'tsqs/listing': _make_string_state(True, False, 'listing'), + 'dqs/listing': _make_string_state(False, True, 'listing'), + 'sqs/listing': _make_string_state(False, False, 'listing'), + 'tdqs/xmp': _make_string_state(True, True, 'xmp'), + 'tsqs/xmp': _make_string_state(True, False, 'xmp'), + 'dqs/xmp': _make_string_state(False, True, 'xmp'), + 'sqs/xmp': _make_string_state(False, False, 'xmp'), + + # Tags + 'tdqt': _make_tag_state(True, True), + 'tsqt': _make_tag_state(True, False), + 'dqt': _make_tag_state(False, True), + 'sqt': _make_tag_state(False, False), + 'dqs/tdqt': _make_attribute_value_state(r'"', True, True), + 'dqs/tsqt': _make_attribute_value_state(r'"', True, False), + 'dqs/dqt': _make_attribute_value_state(r'"', False, True), + 'dqs/sqt': _make_attribute_value_state(r'"', False, False), + 'sqs/tdqt': _make_attribute_value_state(r"'", True, True), + 'sqs/tsqt': _make_attribute_value_state(r"'", True, False), + 'sqs/dqt': _make_attribute_value_state(r"'", False, True), + 'sqs/sqt': _make_attribute_value_state(r"'", False, False), + 'uqs/tdqt': _make_attribute_value_state(_no_quote, True, True), + 'uqs/tsqt': _make_attribute_value_state(_no_quote, True, False), + 'uqs/dqt': _make_attribute_value_state(_no_quote, False, True), + 'uqs/sqt': _make_attribute_value_state(_no_quote, False, False), + + # Regular expressions + 'tdqr': [ + (r'[^\\"]+', String.Regex), + (r'\\"*', String.Regex), + (r'"{3,}', String.Regex, '#pop'), + (r'"', String.Regex) + ], + 'tsqr': [ + (r"[^\\']+", String.Regex), + (r"\\'*", String.Regex), + (r"'{3,}", String.Regex, '#pop'), + (r"'", String.Regex) + ], + 'dqr': [ + (r'[^\\"]+', String.Regex), + (r'\\"?', String.Regex), + (r'"', String.Regex, '#pop') + ], + 'sqr': [ + (r"[^\\']+", String.Regex), + (r"\\'?", String.Regex), + (r"'", String.Regex, '#pop') + ] + } + + def get_tokens_unprocessed(self, text, **kwargs): + pp = r'^%s*#%s*' % (self._ws_pp, self._ws_pp) + if_false_level = 0 + for index, token, value in ( + RegexLexer.get_tokens_unprocessed(self, text, **kwargs)): + if if_false_level == 0: # Not in a false #if + if (token is Comment.Preproc and + re.match(r'%sif%s+(0|nil)%s*$\n?' % + (pp, self._ws_pp, self._ws_pp), value)): + if_false_level = 1 + else: # In a false #if + if token is Comment.Preproc: + if (if_false_level == 1 and + re.match(r'%sel(if|se)\b' % pp, value)): + if_false_level = 0 + elif re.match(r'%sif' % pp, value): + if_false_level += 1 + elif re.match(r'%sendif\b' % pp, value): + if_false_level -= 1 + else: + token = Comment + yield index, token, value diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/iolang.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/iolang.py new file mode 100644 index 0000000000..0bf86f567c --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/iolang.py @@ -0,0 +1,63 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.iolang + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for the Io language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number + +__all__ = ['IoLexer'] + + +class IoLexer(RegexLexer): + """ + For `Io `_ (a small, prototype-based + programming language) source. + + .. versionadded:: 0.10 + """ + name = 'Io' + filenames = ['*.io'] + aliases = ['io'] + mimetypes = ['text/x-iosrc'] + tokens = { + 'root': [ + (r'\n', Text), + (r'\s+', Text), + # Comments + (r'//(.*?)\n', Comment.Single), + (r'#(.*?)\n', Comment.Single), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + (r'/\+', Comment.Multiline, 'nestedcomment'), + # DoubleQuotedString + (r'"(\\\\|\\"|[^"])*"', String), + # Operators + (r'::=|:=|=|\(|\)|;|,|\*|-|\+|>|<|@|!|/|\||\^|\.|%|&|\[|\]|\{|\}', + Operator), + # keywords + (r'(clone|do|doFile|doString|method|for|if|else|elseif|then)\b', + Keyword), + # constants + (r'(nil|false|true)\b', Name.Constant), + # names + (r'(Object|list|List|Map|args|Sequence|Coroutine|File)\b', + Name.Builtin), + ('[a-zA-Z_]\w*', Name), + # numbers + (r'(\d+\.?\d*|\d*\.\d+)([eE][+-]?[0-9]+)?', Number.Float), + (r'\d+', Number.Integer) + ], + 'nestedcomment': [ + (r'[^+/]+', Comment.Multiline), + (r'/\+', Comment.Multiline, '#push'), + (r'\+/', Comment.Multiline, '#pop'), + (r'[+/]', Comment.Multiline), + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/javascript.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/javascript.py new file mode 100644 index 0000000000..404bcf965f --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/javascript.py @@ -0,0 +1,1199 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.javascript + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for JavaScript and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, default, using, this +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Other +from pygments.util import get_bool_opt, iteritems +import pygments.unistring as uni + +__all__ = ['JavascriptLexer', 'KalLexer', 'LiveScriptLexer', 'DartLexer', + 'TypeScriptLexer', 'LassoLexer', 'ObjectiveJLexer', + 'CoffeeScriptLexer', 'MaskLexer'] + +JS_IDENT_START = ('(?:[$_' + uni.combine('Lu', 'Ll', 'Lt', 'Lm', 'Lo', 'Nl') + + ']|\\\\u[a-fA-F0-9]{4})') +JS_IDENT_PART = ('(?:[$' + uni.combine('Lu', 'Ll', 'Lt', 'Lm', 'Lo', 'Nl', + 'Mn', 'Mc', 'Nd', 'Pc') + + u'\u200c\u200d]|\\\\u[a-fA-F0-9]{4})') +JS_IDENT = JS_IDENT_START + '(?:' + JS_IDENT_PART + ')*' + + +class JavascriptLexer(RegexLexer): + """ + For JavaScript source code. + """ + + name = 'JavaScript' + aliases = ['js', 'javascript'] + filenames = ['*.js', ] + mimetypes = ['application/javascript', 'application/x-javascript', + 'text/x-javascript', 'text/javascript', ] + + flags = re.DOTALL | re.UNICODE | re.MULTILINE + + tokens = { + 'commentsandwhitespace': [ + (r'\s+', Text), + (r')?', Other, 'delimiters'), + (r'\s+', Other), + default(('delimiters', 'lassofile')), + ], + 'delimiters': [ + (r'\[no_square_brackets\]', Comment.Preproc, 'nosquarebrackets'), + (r'\[noprocess\]', Comment.Preproc, 'noprocess'), + (r'\[', Comment.Preproc, 'squarebrackets'), + (r'<\?(LassoScript|lasso|=)', Comment.Preproc, 'anglebrackets'), + (r'<(!--.*?-->)?', Other), + (r'[^[<]+', Other), + ], + 'nosquarebrackets': [ + (r'<\?(LassoScript|lasso|=)', Comment.Preproc, 'anglebrackets'), + (r'<', Other), + (r'[^<]+', Other), + ], + 'noprocess': [ + (r'\[/noprocess\]', Comment.Preproc, '#pop'), + (r'\[', Other), + (r'[^[]', Other), + ], + 'squarebrackets': [ + (r'\]', Comment.Preproc, '#pop'), + include('lasso'), + ], + 'anglebrackets': [ + (r'\?>', Comment.Preproc, '#pop'), + include('lasso'), + ], + 'lassofile': [ + (r'\]|\?>', Comment.Preproc, '#pop'), + include('lasso'), + ], + 'whitespacecomments': [ + (r'\s+', Text), + (r'//.*?\n', Comment.Single), + (r'/\*\*!.*?\*/', String.Doc), + (r'/\*.*?\*/', Comment.Multiline), + ], + 'lasso': [ + # whitespace/comments + include('whitespacecomments'), + + # literals + (r'\d*\.\d+(e[+-]?\d+)?', Number.Float), + (r'0x[\da-f]+', Number.Hex), + (r'\d+', Number.Integer), + (r'([+-]?)(infinity|NaN)\b', bygroups(Operator, Number)), + (r"'", String.Single, 'singlestring'), + (r'"', String.Double, 'doublestring'), + (r'`[^`]*`', String.Backtick), + + # names + (r'\$[a-z_][\w.]*', Name.Variable), + (r'#([a-z_][\w.]*|\d+)', Name.Variable.Instance), + (r"(\.)('[a-z_][\w.]*')", + bygroups(Name.Builtin.Pseudo, Name.Variable.Class)), + (r"(self)(\s*->\s*)('[a-z_][\w.]*')", + bygroups(Name.Builtin.Pseudo, Operator, Name.Variable.Class)), + (r'(\.\.?)([a-z_][\w.]*(=(?!=))?)', + bygroups(Name.Builtin.Pseudo, Name.Other.Member)), + (r'(->\\?\s*|&\s*)([a-z_][\w.]*(=(?!=))?)', + bygroups(Operator, Name.Other.Member)), + (r'(self|inherited)\b', Name.Builtin.Pseudo), + (r'-[a-z_][\w.]*', Name.Attribute), + (r'::\s*[a-z_][\w.]*', Name.Label), + (r'(error_(code|msg)_\w+|Error_AddError|Error_ColumnRestriction|' + r'Error_DatabaseConnectionUnavailable|Error_DatabaseTimeout|' + r'Error_DeleteError|Error_FieldRestriction|Error_FileNotFound|' + r'Error_InvalidDatabase|Error_InvalidPassword|' + r'Error_InvalidUsername|Error_ModuleNotFound|' + r'Error_NoError|Error_NoPermission|Error_OutOfMemory|' + r'Error_ReqColumnMissing|Error_ReqFieldMissing|' + r'Error_RequiredColumnMissing|Error_RequiredFieldMissing|' + r'Error_UpdateError)\b', Name.Exception), + + # definitions + (r'(define)(\s+)([a-z_][\w.]*)(\s*=>\s*)(type|trait|thread)\b', + bygroups(Keyword.Declaration, Text, Name.Class, Operator, Keyword)), + (r'(define)(\s+)([a-z_][\w.]*)(\s*->\s*)([a-z_][\w.]*=?|[-+*/%])', + bygroups(Keyword.Declaration, Text, Name.Class, Operator, + Name.Function), 'signature'), + (r'(define)(\s+)([a-z_][\w.]*)', + bygroups(Keyword.Declaration, Text, Name.Function), 'signature'), + (r'(public|protected|private|provide)(\s+)(([a-z_][\w.]*=?|[-+*/%])' + r'(?=\s*\())', bygroups(Keyword, Text, Name.Function), + 'signature'), + (r'(public|protected|private|provide)(\s+)([a-z_][\w.]*)', + bygroups(Keyword, Text, Name.Function)), + + # keywords + (r'(true|false|none|minimal|full|all|void)\b', Keyword.Constant), + (r'(local|var|variable|global|data(?=\s))\b', Keyword.Declaration), + (r'(array|date|decimal|duration|integer|map|pair|string|tag|xml|' + r'null|bytes|list|queue|set|stack|staticarray|tie)\b', Keyword.Type), + (r'([a-z_][\w.]*)(\s+)(in)\b', bygroups(Name, Text, Keyword)), + (r'(let|into)(\s+)([a-z_][\w.]*)', bygroups(Keyword, Text, Name)), + (r'require\b', Keyword, 'requiresection'), + (r'(/?)(Namespace_Using)\b', bygroups(Punctuation, Keyword.Namespace)), + (r'(/?)(Cache|Database_Names|Database_SchemaNames|' + r'Database_TableNames|Define_Tag|Define_Type|Email_Batch|' + r'Encode_Set|HTML_Comment|Handle|Handle_Error|Header|If|Inline|' + r'Iterate|LJAX_Target|Link|Link_CurrentAction|Link_CurrentGroup|' + r'Link_CurrentRecord|Link_Detail|Link_FirstGroup|' + r'Link_FirstRecord|Link_LastGroup|Link_LastRecord|Link_NextGroup|' + r'Link_NextRecord|Link_PrevGroup|Link_PrevRecord|Log|Loop|' + r'NoProcess|Output_None|Portal|Private|Protect|Records|Referer|' + r'Referrer|Repeating|ResultSet|Rows|Search_Args|Search_Arguments|' + r'Select|Sort_Args|Sort_Arguments|Thread_Atomic|Value_List|While|' + r'Abort|Case|Else|If_Empty|If_False|If_Null|If_True|Loop_Abort|' + r'Loop_Continue|Loop_Count|Params|Params_Up|Return|Return_Value|' + r'Run_Children|SOAP_DefineTag|SOAP_LastRequest|SOAP_LastResponse|' + r'Tag_Name|ascending|average|by|define|descending|do|equals|' + r'frozen|group|handle_failure|import|in|into|join|let|match|max|' + r'min|on|order|parent|protected|provide|public|require|returnhome|' + r'skip|split_thread|sum|take|thread|to|trait|type|where|with|' + r'yield|yieldhome)\b', + bygroups(Punctuation, Keyword)), + + # other + (r',', Punctuation, 'commamember'), + (r'(and|or|not)\b', Operator.Word), + (r'([a-z_][\w.]*)(\s*::\s*[a-z_][\w.]*)?(\s*=(?!=))', + bygroups(Name, Name.Label, Operator)), + (r'(/?)([\w.]+)', bygroups(Punctuation, Name.Other)), + (r'(=)(n?bw|n?ew|n?cn|lte?|gte?|n?eq|n?rx|ft)\b', + bygroups(Operator, Operator.Word)), + (r':=|[-+*/%=<>&|!?\\]+', Operator), + (r'[{}():;,@^]', Punctuation), + ], + 'singlestring': [ + (r"'", String.Single, '#pop'), + (r"[^'\\]+", String.Single), + include('escape'), + (r"\\", String.Single), + ], + 'doublestring': [ + (r'"', String.Double, '#pop'), + (r'[^"\\]+', String.Double), + include('escape'), + (r'\\', String.Double), + ], + 'escape': [ + (r'\\(U[\da-f]{8}|u[\da-f]{4}|x[\da-f]{1,2}|[0-7]{1,3}|:[^:]+:|' + r'[abefnrtv?"\'\\]|$)', String.Escape), + ], + 'signature': [ + (r'=>', Operator, '#pop'), + (r'\)', Punctuation, '#pop'), + (r'[(,]', Punctuation, 'parameter'), + include('lasso'), + ], + 'parameter': [ + (r'\)', Punctuation, '#pop'), + (r'-?[a-z_][\w.]*', Name.Attribute, '#pop'), + (r'\.\.\.', Name.Builtin.Pseudo), + include('lasso'), + ], + 'requiresection': [ + (r'(([a-z_][\w.]*=?|[-+*/%])(?=\s*\())', Name, 'requiresignature'), + (r'(([a-z_][\w.]*=?|[-+*/%])(?=(\s*::\s*[\w.]+)?\s*,))', Name), + (r'[a-z_][\w.]*=?|[-+*/%]', Name, '#pop'), + (r'::\s*[a-z_][\w.]*', Name.Label), + (r',', Punctuation), + include('whitespacecomments'), + ], + 'requiresignature': [ + (r'(\)(?=(\s*::\s*[\w.]+)?\s*,))', Punctuation, '#pop'), + (r'\)', Punctuation, '#pop:2'), + (r'-?[a-z_][\w.]*', Name.Attribute), + (r'::\s*[a-z_][\w.]*', Name.Label), + (r'\.\.\.', Name.Builtin.Pseudo), + (r'[(,]', Punctuation), + include('whitespacecomments'), + ], + 'commamember': [ + (r'(([a-z_][\w.]*=?|[-+*/%])' + r'(?=\s*(\(([^()]*\([^()]*\))*[^)]*\)\s*)?(::[\w.\s]+)?=>))', + Name.Function, 'signature'), + include('whitespacecomments'), + default('#pop'), + ], + } + + def __init__(self, **options): + self.builtinshighlighting = get_bool_opt( + options, 'builtinshighlighting', True) + self.requiredelimiters = get_bool_opt( + options, 'requiredelimiters', False) + + self._builtins = set() + self._members = set() + if self.builtinshighlighting: + from pygments.lexers._lasso_builtins import BUILTINS, MEMBERS + for key, value in iteritems(BUILTINS): + self._builtins.update(value) + for key, value in iteritems(MEMBERS): + self._members.update(value) + RegexLexer.__init__(self, **options) + + def get_tokens_unprocessed(self, text): + stack = ['root'] + if self.requiredelimiters: + stack.append('delimiters') + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text, stack): + if (token is Name.Other and value.lower() in self._builtins or + token is Name.Other.Member and + value.lower().rstrip('=') in self._members): + yield index, Name.Builtin, value + continue + yield index, token, value + + def analyse_text(text): + rv = 0.0 + if 'bin/lasso9' in text: + rv += 0.8 + if re.search(r'<\?lasso', text, re.I): + rv += 0.4 + if re.search(r'local\(', text, re.I): + rv += 0.4 + return rv + + +class ObjectiveJLexer(RegexLexer): + """ + For Objective-J source code with preprocessor directives. + + .. versionadded:: 1.3 + """ + + name = 'Objective-J' + aliases = ['objective-j', 'objectivej', 'obj-j', 'objj'] + filenames = ['*.j'] + mimetypes = ['text/x-objective-j'] + + #: optional Comment or Whitespace + _ws = r'(?:\s|//.*?\n|/[*].*?[*]/)*' + + flags = re.DOTALL | re.MULTILINE + + tokens = { + 'root': [ + include('whitespace'), + + # function definition + (r'^(' + _ws + r'[+-]' + _ws + r')([(a-zA-Z_].*?[^(])(' + _ws + r'\{)', + bygroups(using(this), using(this, state='function_signature'), + using(this))), + + # class definition + (r'(@interface|@implementation)(\s+)', bygroups(Keyword, Text), + 'classname'), + (r'(@class|@protocol)(\s*)', bygroups(Keyword, Text), + 'forward_classname'), + (r'(\s*)(@end)(\s*)', bygroups(Text, Keyword, Text)), + + include('statements'), + ('[{()}]', Punctuation), + (';', Punctuation), + ], + 'whitespace': [ + (r'(@import)(\s+)("(?:\\\\|\\"|[^"])*")', + bygroups(Comment.Preproc, Text, String.Double)), + (r'(@import)(\s+)(<(?:\\\\|\\>|[^>])*>)', + bygroups(Comment.Preproc, Text, String.Double)), + (r'(#(?:include|import))(\s+)("(?:\\\\|\\"|[^"])*")', + bygroups(Comment.Preproc, Text, String.Double)), + (r'(#(?:include|import))(\s+)(<(?:\\\\|\\>|[^>])*>)', + bygroups(Comment.Preproc, Text, String.Double)), + + (r'#if\s+0', Comment.Preproc, 'if0'), + (r'#', Comment.Preproc, 'macro'), + + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuation + (r'//(\n|(.|\n)*?[^\\]\n)', Comment.Single), + (r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline), + (r'', Comment, '#pop'), + (r'[^\-]+|-', Comment), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/modeling.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/modeling.py new file mode 100644 index 0000000000..1552fbf877 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/modeling.py @@ -0,0 +1,356 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.modeling + ~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for modeling languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, using, default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +from pygments.lexers.html import HtmlLexer +from pygments.lexers import _stan_builtins + +__all__ = ['ModelicaLexer', 'BugsLexer', 'JagsLexer', 'StanLexer'] + + +class ModelicaLexer(RegexLexer): + """ + For `Modelica `_ source code. + + .. versionadded:: 1.1 + """ + name = 'Modelica' + aliases = ['modelica'] + filenames = ['*.mo'] + mimetypes = ['text/x-modelica'] + + flags = re.DOTALL | re.MULTILINE + + _name = r"(?:'(?:[^\\']|\\.)+'|[a-zA-Z_]\w*)" + + tokens = { + 'whitespace': [ + (u'[\\s\ufeff]+', Text), + (r'//[^\n]*\n?', Comment.Single), + (r'/\*.*?\*/', Comment.Multiline) + ], + 'root': [ + include('whitespace'), + (r'"', String.Double, 'string'), + (r'[()\[\]{},;]+', Punctuation), + (r'\.?[*^/+-]|\.|<>|[<>:=]=?', Operator), + (r'\d+(\.?\d*[eE][-+]?\d+|\.\d*)', Number.Float), + (r'\d+', Number.Integer), + (r'(abs|acos|actualStream|array|asin|assert|AssertionLevel|atan|' + r'atan2|backSample|Boolean|cardinality|cat|ceil|change|Clock|' + r'Connections|cos|cosh|cross|delay|diagonal|div|edge|exp|' + r'ExternalObject|fill|floor|getInstanceName|hold|homotopy|' + r'identity|inStream|integer|Integer|interval|inverse|isPresent|' + r'linspace|log|log10|matrix|max|min|mod|ndims|noClock|noEvent|' + r'ones|outerProduct|pre|previous|product|Real|reinit|rem|rooted|' + r'sample|scalar|semiLinear|shiftSample|sign|sin|sinh|size|skew|' + r'smooth|spatialDistribution|sqrt|StateSelect|String|subSample|' + r'sum|superSample|symmetric|tan|tanh|terminal|terminate|time|' + r'transpose|vector|zeros)\b', Name.Builtin), + (r'(algorithm|annotation|break|connect|constant|constrainedby|der|' + r'discrete|each|else|elseif|elsewhen|encapsulated|enumeration|' + r'equation|exit|expandable|extends|external|final|flow|for|if|' + r'import|impure|in|initial|inner|input|loop|nondiscrete|outer|' + r'output|parameter|partial|protected|public|pure|redeclare|' + r'replaceable|return|stream|then|when|while)\b', + Keyword.Reserved), + (r'(and|not|or)\b', Operator.Word), + (r'(block|class|connector|end|function|model|operator|package|' + r'record|type)\b', Keyword.Reserved, 'class'), + (r'(false|true)\b', Keyword.Constant), + (r'within\b', Keyword.Reserved, 'package-prefix'), + (_name, Name) + ], + 'class': [ + include('whitespace'), + (r'(function|record)\b', Keyword.Reserved), + (r'(if|for|when|while)\b', Keyword.Reserved, '#pop'), + (_name, Name.Class, '#pop'), + default('#pop') + ], + 'package-prefix': [ + include('whitespace'), + (_name, Name.Namespace, '#pop'), + default('#pop') + ], + 'string': [ + (r'"', String.Double, '#pop'), + (r'\\[\'"?\\abfnrtv]', String.Escape), + (r'(?i)<\s*html\s*>([^\\"]|\\.)+?(<\s*/\s*html\s*>|(?="))', + using(HtmlLexer)), + (r'<|\\?[^"\\<]+', String.Double) + ] + } + + +class BugsLexer(RegexLexer): + """ + Pygments Lexer for `OpenBugs `_ and WinBugs + models. + + .. versionadded:: 1.6 + """ + + name = 'BUGS' + aliases = ['bugs', 'winbugs', 'openbugs'] + filenames = ['*.bug'] + + _FUNCTIONS = ( + # Scalar functions + 'abs', 'arccos', 'arccosh', 'arcsin', 'arcsinh', 'arctan', 'arctanh', + 'cloglog', 'cos', 'cosh', 'cumulative', 'cut', 'density', 'deviance', + 'equals', 'expr', 'gammap', 'ilogit', 'icloglog', 'integral', 'log', + 'logfact', 'loggam', 'logit', 'max', 'min', 'phi', 'post.p.value', + 'pow', 'prior.p.value', 'probit', 'replicate.post', 'replicate.prior', + 'round', 'sin', 'sinh', 'solution', 'sqrt', 'step', 'tan', 'tanh', + 'trunc', + # Vector functions + 'inprod', 'interp.lin', 'inverse', 'logdet', 'mean', 'eigen.vals', + 'ode', 'prod', 'p.valueM', 'rank', 'ranked', 'replicate.postM', + 'sd', 'sort', 'sum', + # Special + 'D', 'I', 'F', 'T', 'C') + """ OpenBUGS built-in functions + + From http://www.openbugs.info/Manuals/ModelSpecification.html#ContentsAII + + This also includes + + - T, C, I : Truncation and censoring. + ``T`` and ``C`` are in OpenBUGS. ``I`` in WinBUGS. + - D : ODE + - F : Functional http://www.openbugs.info/Examples/Functionals.html + + """ + + _DISTRIBUTIONS = ('dbern', 'dbin', 'dcat', 'dnegbin', 'dpois', + 'dhyper', 'dbeta', 'dchisqr', 'ddexp', 'dexp', + 'dflat', 'dgamma', 'dgev', 'df', 'dggamma', 'dgpar', + 'dloglik', 'dlnorm', 'dlogis', 'dnorm', 'dpar', + 'dt', 'dunif', 'dweib', 'dmulti', 'ddirch', 'dmnorm', + 'dmt', 'dwish') + """ OpenBUGS built-in distributions + + Functions from + http://www.openbugs.info/Manuals/ModelSpecification.html#ContentsAI + """ + + tokens = { + 'whitespace': [ + (r"\s+", Text), + ], + 'comments': [ + # Comments + (r'#.*$', Comment.Single), + ], + 'root': [ + # Comments + include('comments'), + include('whitespace'), + # Block start + (r'(model)(\s+)(\{)', + bygroups(Keyword.Namespace, Text, Punctuation)), + # Reserved Words + (r'(for|in)(?![\w.])', Keyword.Reserved), + # Built-in Functions + (r'(%s)(?=\s*\()' + % r'|'.join(_FUNCTIONS + _DISTRIBUTIONS), + Name.Builtin), + # Regular variable names + (r'[A-Za-z][\w.]*', Name), + # Number Literals + (r'[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?', Number), + # Punctuation + (r'\[|\]|\(|\)|:|,|;', Punctuation), + # Assignment operators + # SLexer makes these tokens Operators. + (r'<-|~', Operator), + # Infix and prefix operators + (r'\+|-|\*|/', Operator), + # Block + (r'[{}]', Punctuation), + ] + } + + def analyse_text(text): + if re.search(r"^\s*model\s*{", text, re.M): + return 0.7 + else: + return 0.0 + + +class JagsLexer(RegexLexer): + """ + Pygments Lexer for JAGS. + + .. versionadded:: 1.6 + """ + + name = 'JAGS' + aliases = ['jags'] + filenames = ['*.jag', '*.bug'] + + # JAGS + _FUNCTIONS = ( + 'abs', 'arccos', 'arccosh', 'arcsin', 'arcsinh', 'arctan', 'arctanh', + 'cos', 'cosh', 'cloglog', + 'equals', 'exp', 'icloglog', 'ifelse', 'ilogit', 'log', 'logfact', + 'loggam', 'logit', 'phi', 'pow', 'probit', 'round', 'sin', 'sinh', + 'sqrt', 'step', 'tan', 'tanh', 'trunc', 'inprod', 'interp.lin', + 'logdet', 'max', 'mean', 'min', 'prod', 'sum', 'sd', 'inverse', + 'rank', 'sort', 't', 'acos', 'acosh', 'asin', 'asinh', 'atan', + # Truncation/Censoring (should I include) + 'T', 'I') + # Distributions with density, probability and quartile functions + _DISTRIBUTIONS = tuple('[dpq]%s' % x for x in + ('bern', 'beta', 'dchiqsqr', 'ddexp', 'dexp', + 'df', 'gamma', 'gen.gamma', 'logis', 'lnorm', + 'negbin', 'nchisqr', 'norm', 'par', 'pois', 'weib')) + # Other distributions without density and probability + _OTHER_DISTRIBUTIONS = ( + 'dt', 'dunif', 'dbetabin', 'dbern', 'dbin', 'dcat', 'dhyper', + 'ddirch', 'dmnorm', 'dwish', 'dmt', 'dmulti', 'dbinom', 'dchisq', + 'dnbinom', 'dweibull', 'ddirich') + + tokens = { + 'whitespace': [ + (r"\s+", Text), + ], + 'names': [ + # Regular variable names + (r'[a-zA-Z][\w.]*\b', Name), + ], + 'comments': [ + # do not use stateful comments + (r'(?s)/\*.*?\*/', Comment.Multiline), + # Comments + (r'#.*$', Comment.Single), + ], + 'root': [ + # Comments + include('comments'), + include('whitespace'), + # Block start + (r'(model|data)(\s+)(\{)', + bygroups(Keyword.Namespace, Text, Punctuation)), + (r'var(?![\w.])', Keyword.Declaration), + # Reserved Words + (r'(for|in)(?![\w.])', Keyword.Reserved), + # Builtins + # Need to use lookahead because . is a valid char + (r'(%s)(?=\s*\()' % r'|'.join(_FUNCTIONS + + _DISTRIBUTIONS + + _OTHER_DISTRIBUTIONS), + Name.Builtin), + # Names + include('names'), + # Number Literals + (r'[-+]?[0-9]*\.?[0-9]+([eE][-+]?[0-9]+)?', Number), + (r'\[|\]|\(|\)|:|,|;', Punctuation), + # Assignment operators + (r'<-|~', Operator), + # # JAGS includes many more than OpenBUGS + (r'\+|-|\*|\/|\|\|[&]{2}|[<>=]=?|\^|%.*?%', Operator), + (r'[{}]', Punctuation), + ] + } + + def analyse_text(text): + if re.search(r'^\s*model\s*\{', text, re.M): + if re.search(r'^\s*data\s*\{', text, re.M): + return 0.9 + elif re.search(r'^\s*var', text, re.M): + return 0.9 + else: + return 0.3 + else: + return 0 + + +class StanLexer(RegexLexer): + """Pygments Lexer for Stan models. + + The Stan modeling language is specified in the *Stan Modeling Language + User's Guide and Reference Manual, v2.4.0*, + `pdf `__. + + .. versionadded:: 1.6 + """ + + name = 'Stan' + aliases = ['stan'] + filenames = ['*.stan'] + + tokens = { + 'whitespace': [ + (r"\s+", Text), + ], + 'comments': [ + (r'(?s)/\*.*?\*/', Comment.Multiline), + # Comments + (r'(//|#).*$', Comment.Single), + ], + 'root': [ + # Stan is more restrictive on strings than this regex + (r'"[^"]*"', String), + # Comments + include('comments'), + # block start + include('whitespace'), + # Block start + (r'(%s)(\s*)(\{)' % + r'|'.join(('functions', 'data', r'transformed\s+?data', + 'parameters', r'transformed\s+parameters', + 'model', r'generated\s+quantities')), + bygroups(Keyword.Namespace, Text, Punctuation)), + # Reserved Words + (r'(%s)\b' % r'|'.join(_stan_builtins.KEYWORDS), Keyword), + # Truncation + (r'T(?=\s*\[)', Keyword), + # Data types + (r'(%s)\b' % r'|'.join(_stan_builtins.TYPES), Keyword.Type), + # Punctuation + (r"[;:,\[\]()]", Punctuation), + # Builtin + (r'(%s)(?=\s*\()' + % r'|'.join(_stan_builtins.FUNCTIONS + + _stan_builtins.DISTRIBUTIONS), + Name.Builtin), + # Special names ending in __, like lp__ + (r'[A-Za-z]\w*__\b', Name.Builtin.Pseudo), + (r'(%s)\b' % r'|'.join(_stan_builtins.RESERVED), Keyword.Reserved), + # Regular variable names + (r'[A-Za-z]\w*\b', Name), + # Real Literals + (r'-?[0-9]+(\.[0-9]+)?[eE]-?[0-9]+', Number.Float), + (r'-?[0-9]*\.[0-9]*', Number.Float), + # Integer Literals + (r'-?[0-9]+', Number.Integer), + # Assignment operators + # SLexer makes these tokens Operators. + (r'<-|~', Operator), + # Infix, prefix and postfix operators (and = ) + (r"\+|-|\.?\*|\.?/|\\|'|\^|==?|!=?|<=?|>=?|\|\||&&", Operator), + # Block delimiters + (r'[{}]', Punctuation), + ] + } + + def analyse_text(text): + if re.search(r'^\s*parameters\s*\{', text, re.M): + return 1.0 + else: + return 0.0 diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nimrod.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nimrod.py new file mode 100644 index 0000000000..de2eafb007 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nimrod.py @@ -0,0 +1,159 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.nimrod + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexer for the Nimrod language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error + +__all__ = ['NimrodLexer'] + + +class NimrodLexer(RegexLexer): + """ + For `Nimrod `_ source code. + + .. versionadded:: 1.5 + """ + + name = 'Nimrod' + aliases = ['nimrod', 'nim'] + filenames = ['*.nim', '*.nimrod'] + mimetypes = ['text/x-nimrod'] + + flags = re.MULTILINE | re.IGNORECASE | re.UNICODE + + def underscorize(words): + newWords = [] + new = "" + for word in words: + for ch in word: + new += (ch + "_?") + newWords.append(new) + new = "" + return "|".join(newWords) + + keywords = [ + 'addr', 'and', 'as', 'asm', 'atomic', 'bind', 'block', 'break', + 'case', 'cast', 'const', 'continue', 'converter', 'discard', + 'distinct', 'div', 'elif', 'else', 'end', 'enum', 'except', 'finally', + 'for', 'generic', 'if', 'implies', 'in', 'yield', + 'is', 'isnot', 'iterator', 'lambda', 'let', 'macro', 'method', + 'mod', 'not', 'notin', 'object', 'of', 'or', 'out', 'proc', + 'ptr', 'raise', 'ref', 'return', 'shl', 'shr', 'template', 'try', + 'tuple', 'type', 'when', 'while', 'with', 'without', 'xor' + ] + + keywordsPseudo = [ + 'nil', 'true', 'false' + ] + + opWords = [ + 'and', 'or', 'not', 'xor', 'shl', 'shr', 'div', 'mod', 'in', + 'notin', 'is', 'isnot' + ] + + types = [ + 'int', 'int8', 'int16', 'int32', 'int64', 'float', 'float32', 'float64', + 'bool', 'char', 'range', 'array', 'seq', 'set', 'string' + ] + + tokens = { + 'root': [ + (r'##.*$', String.Doc), + (r'#.*$', Comment), + (r'[*=><+\-/@$~&%!?|\\\[\]]', Operator), + (r'\.\.|\.|,|\[\.|\.\]|\{\.|\.\}|\(\.|\.\)|\{|\}|\(|\)|:|\^|`|;', + Punctuation), + + # Strings + (r'(?:[\w]+)"', String, 'rdqs'), + (r'"""', String, 'tdqs'), + ('"', String, 'dqs'), + + # Char + ("'", String.Char, 'chars'), + + # Keywords + (r'(%s)\b' % underscorize(opWords), Operator.Word), + (r'(p_?r_?o_?c_?\s)(?![(\[\]])', Keyword, 'funcname'), + (r'(%s)\b' % underscorize(keywords), Keyword), + (r'(%s)\b' % underscorize(['from', 'import', 'include']), + Keyword.Namespace), + (r'(v_?a_?r)\b', Keyword.Declaration), + (r'(%s)\b' % underscorize(types), Keyword.Type), + (r'(%s)\b' % underscorize(keywordsPseudo), Keyword.Pseudo), + # Identifiers + (r'\b((?![_\d])\w)(((?!_)\w)|(_(?!_)\w))*', Name), + # Numbers + (r'[0-9][0-9_]*(?=([e.]|\'f(32|64)))', + Number.Float, ('float-suffix', 'float-number')), + (r'0x[a-f0-9][a-f0-9_]*', Number.Hex, 'int-suffix'), + (r'0b[01][01_]*', Number.Bin, 'int-suffix'), + (r'0o[0-7][0-7_]*', Number.Oct, 'int-suffix'), + (r'[0-9][0-9_]*', Number.Integer, 'int-suffix'), + # Whitespace + (r'\s+', Text), + (r'.+$', Error), + ], + 'chars': [ + (r'\\([\\abcefnrtvl"\']|x[a-f0-9]{2}|[0-9]{1,3})', String.Escape), + (r"'", String.Char, '#pop'), + (r".", String.Char) + ], + 'strings': [ + (r'(?`_ source. + + .. versionadded:: 2.0 + """ + + name = 'Nit' + aliases = ['nit'] + filenames = ['*.nit'] + tokens = { + 'root': [ + (r'#.*?$', Comment.Single), + (words(( + 'package', 'module', 'import', 'class', 'abstract', 'interface', + 'universal', 'enum', 'end', 'fun', 'type', 'init', 'redef', + 'isa', 'do', 'readable', 'writable', 'var', 'intern', 'extern', + 'public', 'protected', 'private', 'intrude', 'if', 'then', + 'else', 'while', 'loop', 'for', 'in', 'and', 'or', 'not', + 'implies', 'return', 'continue', 'break', 'abort', 'assert', + 'new', 'is', 'once', 'super', 'self', 'true', 'false', 'nullable', + 'null', 'as', 'isset', 'label', '__debug__'), suffix=r'(?=[\r\n\t( ])'), + Keyword), + (r'[A-Z]\w*', Name.Class), + (r'"""(([^\'\\]|\\.)|\\r|\\n)*((\{\{?)?(""?\{\{?)*""""*)', String), # Simple long string + (r'\'\'\'(((\\.|[^\'\\])|\\r|\\n)|\'((\\.|[^\'\\])|\\r|\\n)|' + r'\'\'((\\.|[^\'\\])|\\r|\\n))*\'\'\'', String), # Simple long string alt + (r'"""(([^\'\\]|\\.)|\\r|\\n)*((""?)?(\{\{?""?)*\{\{\{\{*)', String), # Start long string + (r'\}\}\}(((\\.|[^\'\\])|\\r|\\n))*(""?)?(\{\{?""?)*\{\{\{\{*', String), # Mid long string + (r'\}\}\}(((\\.|[^\'\\])|\\r|\\n))*(\{\{?)?(""?\{\{?)*""""*', String), # End long string + (r'"(\\.|([^"}{\\]))*"', String), # Simple String + (r'"(\\.|([^"}{\\]))*\{', String), # Start string + (r'\}(\\.|([^"}{\\]))*\{', String), # Mid String + (r'\}(\\.|([^"}{\\]))*"', String), # End String + (r'(\'[^\'\\]\')|(\'\\.\')', String.Char), + (r'[0-9]+', Number.Integer), + (r'[0-9]*.[0-9]+', Number.Float), + (r'0(x|X)[0-9A-Fa-f]+', Number.Hex), + (r'[a-z]\w*', Name), + (r'_\w+', Name.Variable.Instance), + (r'==|!=|<==>|>=|>>|>|<=|<<|<|\+|-|=|/|\*|%|\+=|-=|!|@', Operator), + (r'\(|\)|\[|\]|,|\.\.\.|\.\.|\.|::|:', Punctuation), + (r'`\{[^`]*`\}', Text), # Extern blocks won't be Lexed by Nit + (r'[\r\n\t ]+', Text), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nix.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nix.py new file mode 100644 index 0000000000..1bf533ddcd --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/nix.py @@ -0,0 +1,136 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.nix + ~~~~~~~~~~~~~~~~~~~ + + Lexers for the NixOS Nix language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Literal + +__all__ = ['NixLexer'] + + +class NixLexer(RegexLexer): + """ + For the `Nix language `_. + + .. versionadded:: 2.0 + """ + + name = 'Nix' + aliases = ['nixos', 'nix'] + filenames = ['*.nix'] + mimetypes = ['text/x-nix'] + + flags = re.MULTILINE | re.UNICODE + + keywords = ['rec', 'with', 'let', 'in', 'inherit', 'assert', 'if', + 'else', 'then', '...'] + builtins = ['import', 'abort', 'baseNameOf', 'dirOf', 'isNull', 'builtins', + 'map', 'removeAttrs', 'throw', 'toString', 'derivation'] + operators = ['++', '+', '?', '.', '!', '//', '==', + '!=', '&&', '||', '->', '='] + + punctuations = ["(", ")", "[", "]", ";", "{", "}", ":", ",", "@"] + + tokens = { + 'root': [ + # comments starting with # + (r'#.*$', Comment.Single), + + # multiline comments + (r'/\*', Comment.Multiline, 'comment'), + + # whitespace + (r'\s+', Text), + + # keywords + ('(%s)' % '|'.join(re.escape(entry) + '\\b' for entry in keywords), Keyword), + + # highlight the builtins + ('(%s)' % '|'.join(re.escape(entry) + '\\b' for entry in builtins), + Name.Builtin), + + (r'\b(true|false|null)\b', Name.Constant), + + # operators + ('(%s)' % '|'.join(re.escape(entry) for entry in operators), + Operator), + + # word operators + (r'\b(or|and)\b', Operator.Word), + + # punctuations + ('(%s)' % '|'.join(re.escape(entry) for entry in punctuations), Punctuation), + + # integers + (r'[0-9]+', Number.Integer), + + # strings + (r'"', String.Double, 'doublequote'), + (r"''", String.Single, 'singlequote'), + + # paths + (r'[\w.+-]*(\/[\w.+-]+)+', Literal), + (r'\<[\w.+-]+(\/[\w.+-]+)*\>', Literal), + + # urls + (r'[a-zA-Z][a-zA-Z0-9\+\-\.]*\:[\w%/?:@&=+$,\\.!~*\'-]+', Literal), + + # names of variables + (r'[\w-]+\s*=', String.Symbol), + (r'[a-zA-Z_][\w\'-]*', Text), + + ], + 'comment': [ + (r'[^/*]+', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline), + ], + 'singlequote': [ + (r"'''", String.Escape), + (r"''\$\{", String.Escape), + (r"''\n", String.Escape), + (r"''\r", String.Escape), + (r"''\t", String.Escape), + (r"''", String.Single, '#pop'), + (r'\$\{', String.Interpol, 'antiquote'), + (r"[^']", String.Single), + ], + 'doublequote': [ + (r'\\', String.Escape), + (r'\\"', String.Escape), + (r'\\$\{', String.Escape), + (r'"', String.Double, '#pop'), + (r'\$\{', String.Interpol, 'antiquote'), + (r'[^"]', String.Double), + ], + 'antiquote': [ + (r"\}", String.Interpol, '#pop'), + # TODO: we should probably escape also here ''${ \${ + (r"\$\{", String.Interpol, '#push'), + include('root'), + ], + } + + def analyse_text(text): + rv = 0.0 + # TODO: let/in + if re.search(r'import.+?<[^>]+>', text): + rv += 0.4 + if re.search(r'mkDerivation\s+(\(|\{|rec)', text): + rv += 0.4 + if re.search(r'=\s+mkIf\s+', text): + rv += 0.4 + if re.search(r'\{[a-zA-Z,\s]+\}:', text): + rv += 0.1 + return rv diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/objective.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/objective.py new file mode 100644 index 0000000000..4e0ecf0950 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/objective.py @@ -0,0 +1,487 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.objective + ~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Objective-C family languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, using, this, words, \ + inherit, default +from pygments.token import Text, Keyword, Name, String, Operator, \ + Number, Punctuation, Literal, Comment + +from pygments.lexers.c_cpp import CLexer, CppLexer + +__all__ = ['ObjectiveCLexer', 'ObjectiveCppLexer', 'LogosLexer', 'SwiftLexer'] + + +def objective(baselexer): + """ + Generate a subclass of baselexer that accepts the Objective-C syntax + extensions. + """ + + # Have to be careful not to accidentally match JavaDoc/Doxygen syntax here, + # since that's quite common in ordinary C/C++ files. It's OK to match + # JavaDoc/Doxygen keywords that only apply to Objective-C, mind. + # + # The upshot of this is that we CANNOT match @class or @interface + _oc_keywords = re.compile(r'@(?:end|implementation|protocol)') + + # Matches [ ? identifier ( identifier ? ] | identifier? : ) + # (note the identifier is *optional* when there is a ':'!) + _oc_message = re.compile(r'\[\s*[a-zA-Z_]\w*\s+' + r'(?:[a-zA-Z_]\w*\s*\]|' + r'(?:[a-zA-Z_]\w*)?:)') + + class GeneratedObjectiveCVariant(baselexer): + """ + Implements Objective-C syntax on top of an existing C family lexer. + """ + + tokens = { + 'statements': [ + (r'@"', String, 'string'), + (r'@(YES|NO)', Number), + (r"@'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char), + (r'@(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?', Number.Float), + (r'@(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'@0x[0-9a-fA-F]+[Ll]?', Number.Hex), + (r'@0[0-7]+[Ll]?', Number.Oct), + (r'@\d+[Ll]?', Number.Integer), + (r'@\(', Literal, 'literal_number'), + (r'@\[', Literal, 'literal_array'), + (r'@\{', Literal, 'literal_dictionary'), + (words(( + '@selector', '@private', '@protected', '@public', '@encode', + '@synchronized', '@try', '@throw', '@catch', '@finally', + '@end', '@property', '@synthesize', '__bridge', '__bridge_transfer', + '__autoreleasing', '__block', '__weak', '__strong', 'weak', 'strong', + 'copy', 'retain', 'assign', 'unsafe_unretained', 'atomic', 'nonatomic', + 'readonly', 'readwrite', 'setter', 'getter', 'typeof', 'in', + 'out', 'inout', 'release', 'class', '@dynamic', '@optional', + '@required', '@autoreleasepool'), suffix=r'\b'), + Keyword), + (words(('id', 'instancetype', 'Class', 'IMP', 'SEL', 'BOOL', + 'IBOutlet', 'IBAction', 'unichar'), suffix=r'\b'), + Keyword.Type), + (r'@(true|false|YES|NO)\n', Name.Builtin), + (r'(YES|NO|nil|self|super)\b', Name.Builtin), + # Carbon types + (r'(Boolean|UInt8|SInt8|UInt16|SInt16|UInt32|SInt32)\b', Keyword.Type), + # Carbon built-ins + (r'(TRUE|FALSE)\b', Name.Builtin), + (r'(@interface|@implementation)(\s+)', bygroups(Keyword, Text), + ('#pop', 'oc_classname')), + (r'(@class|@protocol)(\s+)', bygroups(Keyword, Text), + ('#pop', 'oc_forward_classname')), + # @ can also prefix other expressions like @{...} or @(...) + (r'@', Punctuation), + inherit, + ], + 'oc_classname': [ + # interface definition that inherits + ('([a-zA-Z$_][\w$]*)(\s*:\s*)([a-zA-Z$_][\w$]*)?(\s*)(\{)', + bygroups(Name.Class, Text, Name.Class, Text, Punctuation), + ('#pop', 'oc_ivars')), + ('([a-zA-Z$_][\w$]*)(\s*:\s*)([a-zA-Z$_][\w$]*)?', + bygroups(Name.Class, Text, Name.Class), '#pop'), + # interface definition for a category + ('([a-zA-Z$_][\w$]*)(\s*)(\([a-zA-Z$_][\w$]*\))(\s*)(\{)', + bygroups(Name.Class, Text, Name.Label, Text, Punctuation), + ('#pop', 'oc_ivars')), + ('([a-zA-Z$_][\w$]*)(\s*)(\([a-zA-Z$_][\w$]*\))', + bygroups(Name.Class, Text, Name.Label), '#pop'), + # simple interface / implementation + ('([a-zA-Z$_][\w$]*)(\s*)(\{)', + bygroups(Name.Class, Text, Punctuation), ('#pop', 'oc_ivars')), + ('([a-zA-Z$_][\w$]*)', Name.Class, '#pop') + ], + 'oc_forward_classname': [ + ('([a-zA-Z$_][\w$]*)(\s*,\s*)', + bygroups(Name.Class, Text), 'oc_forward_classname'), + ('([a-zA-Z$_][\w$]*)(\s*;?)', + bygroups(Name.Class, Text), '#pop') + ], + 'oc_ivars': [ + include('whitespace'), + include('statements'), + (';', Punctuation), + (r'\{', Punctuation, '#push'), + (r'\}', Punctuation, '#pop'), + ], + 'root': [ + # methods + (r'^([-+])(\s*)' # method marker + r'(\(.*?\))?(\s*)' # return type + r'([a-zA-Z$_][\w$]*:?)', # begin of method name + bygroups(Punctuation, Text, using(this), + Text, Name.Function), + 'method'), + inherit, + ], + 'method': [ + include('whitespace'), + # TODO unsure if ellipses are allowed elsewhere, see + # discussion in Issue 789 + (r',', Punctuation), + (r'\.\.\.', Punctuation), + (r'(\(.*?\))(\s*)([a-zA-Z$_][\w$]*)', + bygroups(using(this), Text, Name.Variable)), + (r'[a-zA-Z$_][\w$]*:', Name.Function), + (';', Punctuation, '#pop'), + (r'\{', Punctuation, 'function'), + default('#pop'), + ], + 'literal_number': [ + (r'\(', Punctuation, 'literal_number_inner'), + (r'\)', Literal, '#pop'), + include('statement'), + ], + 'literal_number_inner': [ + (r'\(', Punctuation, '#push'), + (r'\)', Punctuation, '#pop'), + include('statement'), + ], + 'literal_array': [ + (r'\[', Punctuation, 'literal_array_inner'), + (r'\]', Literal, '#pop'), + include('statement'), + ], + 'literal_array_inner': [ + (r'\[', Punctuation, '#push'), + (r'\]', Punctuation, '#pop'), + include('statement'), + ], + 'literal_dictionary': [ + (r'\}', Literal, '#pop'), + include('statement'), + ], + } + + def analyse_text(text): + if _oc_keywords.search(text): + return 1.0 + elif '@"' in text: # strings + return 0.8 + elif re.search('@[0-9]+', text): + return 0.7 + elif _oc_message.search(text): + return 0.8 + return 0 + + def get_tokens_unprocessed(self, text): + from pygments.lexers._cocoa_builtins import COCOA_INTERFACES, \ + COCOA_PROTOCOLS, COCOA_PRIMITIVES + + for index, token, value in \ + baselexer.get_tokens_unprocessed(self, text): + if token is Name or token is Name.Class: + if value in COCOA_INTERFACES or value in COCOA_PROTOCOLS \ + or value in COCOA_PRIMITIVES: + token = Name.Builtin.Pseudo + + yield index, token, value + + return GeneratedObjectiveCVariant + + +class ObjectiveCLexer(objective(CLexer)): + """ + For Objective-C source code with preprocessor directives. + """ + + name = 'Objective-C' + aliases = ['objective-c', 'objectivec', 'obj-c', 'objc'] + filenames = ['*.m', '*.h'] + mimetypes = ['text/x-objective-c'] + priority = 0.05 # Lower than C + + +class ObjectiveCppLexer(objective(CppLexer)): + """ + For Objective-C++ source code with preprocessor directives. + """ + + name = 'Objective-C++' + aliases = ['objective-c++', 'objectivec++', 'obj-c++', 'objc++'] + filenames = ['*.mm', '*.hh'] + mimetypes = ['text/x-objective-c++'] + priority = 0.05 # Lower than C++ + + +class LogosLexer(ObjectiveCppLexer): + """ + For Logos + Objective-C source code with preprocessor directives. + + .. versionadded:: 1.6 + """ + + name = 'Logos' + aliases = ['logos'] + filenames = ['*.x', '*.xi', '*.xm', '*.xmi'] + mimetypes = ['text/x-logos'] + priority = 0.25 + + tokens = { + 'statements': [ + (r'(%orig|%log)\b', Keyword), + (r'(%c)\b(\()(\s*)([a-zA-Z$_][\w$]*)(\s*)(\))', + bygroups(Keyword, Punctuation, Text, Name.Class, Text, Punctuation)), + (r'(%init)\b(\()', + bygroups(Keyword, Punctuation), 'logos_init_directive'), + (r'(%init)(?=\s*;)', bygroups(Keyword)), + (r'(%hook|%group)(\s+)([a-zA-Z$_][\w$]+)', + bygroups(Keyword, Text, Name.Class), '#pop'), + (r'(%subclass)(\s+)', bygroups(Keyword, Text), + ('#pop', 'logos_classname')), + inherit, + ], + 'logos_init_directive': [ + ('\s+', Text), + (',', Punctuation, ('logos_init_directive', '#pop')), + ('([a-zA-Z$_][\w$]*)(\s*)(=)(\s*)([^);]*)', + bygroups(Name.Class, Text, Punctuation, Text, Text)), + ('([a-zA-Z$_][\w$]*)', Name.Class), + ('\)', Punctuation, '#pop'), + ], + 'logos_classname': [ + ('([a-zA-Z$_][\w$]*)(\s*:\s*)([a-zA-Z$_][\w$]*)?', + bygroups(Name.Class, Text, Name.Class), '#pop'), + ('([a-zA-Z$_][\w$]*)', Name.Class, '#pop') + ], + 'root': [ + (r'(%subclass)(\s+)', bygroups(Keyword, Text), + 'logos_classname'), + (r'(%hook|%group)(\s+)([a-zA-Z$_][\w$]+)', + bygroups(Keyword, Text, Name.Class)), + (r'(%config)(\s*\(\s*)(\w+)(\s*=\s*)(.*?)(\s*\)\s*)', + bygroups(Keyword, Text, Name.Variable, Text, String, Text)), + (r'(%ctor)(\s*)(\{)', bygroups(Keyword, Text, Punctuation), + 'function'), + (r'(%new)(\s*)(\()(\s*.*?\s*)(\))', + bygroups(Keyword, Text, Keyword, String, Keyword)), + (r'(\s*)(%end)(\s*)', bygroups(Text, Keyword, Text)), + inherit, + ], + } + + _logos_keywords = re.compile(r'%(?:hook|ctor|init|c\()') + + def analyse_text(text): + if LogosLexer._logos_keywords.search(text): + return 1.0 + return 0 + +class SwiftLexer(RegexLexer): + """ + For `Swift `_ source. + + .. versionadded:: 2.0 + """ + name = 'Swift' + filenames = ['*.swift'] + aliases = ['swift'] + mimetypes = ['text/x-swift'] + + tokens = { + 'root': [ + # Whitespace and Comments + (r'\n', Text), + (r'\s+', Text), + (r'//', Comment.Single, 'comment-single'), + (r'/\*', Comment.Multiline, 'comment-multi'), + (r'#(if|elseif|else|endif)\b', Comment.Preproc, 'preproc'), + + # Keywords + include('keywords'), + + # Global Types + (r'(Array|AutoreleasingUnsafeMutablePointer|BidirectionalReverseView' + r'|Bit|Bool|CFunctionPointer|COpaquePointer|CVaListPointer' + r'|Character|ClosedInterval|CollectionOfOne|ContiguousArray' + r'|Dictionary|DictionaryGenerator|DictionaryIndex|Double' + r'|EmptyCollection|EmptyGenerator|EnumerateGenerator' + r'|EnumerateSequence|FilterCollectionView' + r'|FilterCollectionViewIndex|FilterGenerator|FilterSequenceView' + r'|Float|Float80|FloatingPointClassification|GeneratorOf' + r'|GeneratorOfOne|GeneratorSequence|HalfOpenInterval|HeapBuffer' + r'|HeapBufferStorage|ImplicitlyUnwrappedOptional|IndexingGenerator' + r'|Int|Int16|Int32|Int64|Int8|LazyBidirectionalCollection' + r'|LazyForwardCollection|LazyRandomAccessCollection' + r'|LazySequence|MapCollectionView|MapSequenceGenerator' + r'|MapSequenceView|MirrorDisposition|ObjectIdentifier|OnHeap' + r'|Optional|PermutationGenerator|QuickLookObject' + r'|RandomAccessReverseView|Range|RangeGenerator|RawByte|Repeat' + r'|ReverseBidirectionalIndex|ReverseRandomAccessIndex|SequenceOf' + r'|SinkOf|Slice|StaticString|StrideThrough|StrideThroughGenerator' + r'|StrideTo|StrideToGenerator|String|UInt|UInt16|UInt32|UInt64' + r'|UInt8|UTF16|UTF32|UTF8|UnicodeDecodingResult|UnicodeScalar' + r'|Unmanaged|UnsafeBufferPointer|UnsafeBufferPointerGenerator' + r'|UnsafeMutableBufferPointer|UnsafeMutablePointer|UnsafePointer' + r'|Zip2|ZipGenerator2' + # Protocols + r'|AbsoluteValuable|AnyObject|ArrayLiteralConvertible' + r'|BidirectionalIndexType|BitwiseOperationsType' + r'|BooleanLiteralConvertible|BooleanType|CVarArgType' + r'|CollectionType|Comparable|DebugPrintable' + r'|DictionaryLiteralConvertible|Equatable' + r'|ExtendedGraphemeClusterLiteralConvertible' + r'|ExtensibleCollectionType|FloatLiteralConvertible' + r'|FloatingPointType|ForwardIndexType|GeneratorType|Hashable' + r'|IntegerArithmeticType|IntegerLiteralConvertible|IntegerType' + r'|IntervalType|MirrorType|MutableCollectionType|MutableSliceable' + r'|NilLiteralConvertible|OutputStreamType|Printable' + r'|RandomAccessIndexType|RangeReplaceableCollectionType' + r'|RawOptionSetType|RawRepresentable|Reflectable|SequenceType' + r'|SignedIntegerType|SignedNumberType|SinkType|Sliceable' + r'|Streamable|Strideable|StringInterpolationConvertible' + r'|StringLiteralConvertible|UnicodeCodecType' + r'|UnicodeScalarLiteralConvertible|UnsignedIntegerType' + r'|_ArrayBufferType|_BidirectionalIndexType|_CocoaStringType' + r'|_CollectionType|_Comparable|_ExtensibleCollectionType' + r'|_ForwardIndexType|_Incrementable|_IntegerArithmeticType' + r'|_IntegerType|_ObjectiveCBridgeable|_RandomAccessIndexType' + r'|_RawOptionSetType|_SequenceType|_Sequence_Type' + r'|_SignedIntegerType|_SignedNumberType|_Sliceable|_Strideable' + r'|_SwiftNSArrayRequiredOverridesType|_SwiftNSArrayType' + r'|_SwiftNSCopyingType|_SwiftNSDictionaryRequiredOverridesType' + r'|_SwiftNSDictionaryType|_SwiftNSEnumeratorType' + r'|_SwiftNSFastEnumerationType|_SwiftNSStringRequiredOverridesType' + r'|_SwiftNSStringType|_UnsignedIntegerType' + # Variables + r'|C_ARGC|C_ARGV|Process' + # Typealiases + r'|Any|AnyClass|BooleanLiteralType|CBool|CChar|CChar16|CChar32' + r'|CDouble|CFloat|CInt|CLong|CLongLong|CShort|CSignedChar' + r'|CUnsignedInt|CUnsignedLong|CUnsignedShort|CWideChar' + r'|ExtendedGraphemeClusterType|Float32|Float64|FloatLiteralType' + r'|IntMax|IntegerLiteralType|StringLiteralType|UIntMax|UWord' + r'|UnicodeScalarType|Void|Word' + # Foundation/Cocoa + r'|NSErrorPointer|NSObjectProtocol|Selector)\b', Name.Builtin), + # Functions + (r'(abs|advance|alignof|alignofValue|assert|assertionFailure' + r'|contains|count|countElements|debugPrint|debugPrintln|distance' + r'|dropFirst|dropLast|dump|enumerate|equal|extend|fatalError' + r'|filter|find|first|getVaList|indices|insert|isEmpty|join|last' + r'|lazy|lexicographicalCompare|map|max|maxElement|min|minElement' + r'|numericCast|overlaps|partition|precondition|preconditionFailure' + r'|prefix|print|println|reduce|reflect|removeAll|removeAtIndex' + r'|removeLast|removeRange|reverse|sizeof|sizeofValue|sort|sorted' + r'|splice|split|startsWith|stride|strideof|strideofValue|suffix' + r'|swap|toDebugString|toString|transcode|underestimateCount' + r'|unsafeAddressOf|unsafeBitCast|unsafeDowncast' + r'|withExtendedLifetime|withUnsafeMutablePointer' + r'|withUnsafeMutablePointers|withUnsafePointer|withUnsafePointers' + r'|withVaList)\b', Name.Builtin.Pseudo), + + # Implicit Block Variables + (r'\$\d+', Name.Variable), + + # Binary Literal + (r'0b[01_]+', Number.Bin), + # Octal Literal + (r'0o[0-7_]+', Number.Oct), + # Hexadecimal Literal + (r'0x[0-9a-fA-F_]+', Number.Hex), + # Decimal Literal + (r'[0-9][0-9_]*(\.[0-9_]+[eE][+\-]?[0-9_]+|' + r'\.[0-9_]*|[eE][+\-]?[0-9_]+)', Number.Float), + (r'[0-9][0-9_]*', Number.Integer), + # String Literal + (r'"', String, 'string'), + + # Operators and Punctuation + (r'[(){}\[\].,:;=@#`?]|->|[<&?](?=\w)|(?<=\w)[>!?]', Punctuation), + (r'[/=\-+!*%<>&|^?~]+', Operator), + + # Identifier + (r'[a-zA-Z_]\w*', Name) + ], + 'keywords': [ + (r'(break|case|continue|default|do|else|fallthrough|for|if|in' + r'|return|switch|where|while)\b', Keyword), + (r'@availability\([^)]+\)', Keyword.Reserved), + (r'(associativity|convenience|dynamic|didSet|final|get|infix|inout' + r'|lazy|left|mutating|none|nonmutating|optional|override|postfix' + r'|precedence|prefix|Protocol|required|right|set|Type|unowned|weak' + r'|willSet|@(availability|autoclosure|noreturn' + r'|NSApplicationMain|NSCopying|NSManaged|objc' + r'|UIApplicationMain|IBAction|IBDesignable|IBInspectable' + r'|IBOutlet))\b',Keyword.Reserved), + (r'(as|dynamicType|false|is|nil|self|Self|super|true|__COLUMN__' + r'|__FILE__|__FUNCTION__|__LINE__|_)\b', Keyword.Constant), + (r'import\b', Keyword.Declaration, 'module'), + (r'(class|enum|extension|struct|protocol)(\s+)([a-zA-Z_]\w*)', + bygroups(Keyword.Declaration, Text, Name.Class)), + (r'(func)(\s+)([a-zA-Z_]\w*)', + bygroups(Keyword.Declaration, Text, Name.Function)), + (r'(var|let)(\s+)([a-zA-Z_]\w*)', bygroups(Keyword.Declaration, + Text, Name.Variable)), + (r'(class|deinit|enum|extension|func|import|init|internal|let' + r'|operator|private|protocol|public|static|struct|subscript' + r'|typealias|var)\b', Keyword.Declaration) + ], + 'comment': [ + (r':param: [a-zA-Z_]\w*|:returns?:|(FIXME|MARK|TODO):', + Comment.Special) + ], + + # Nested + 'comment-single': [ + (r'\n', Text, '#pop'), + include('comment'), + (r'[^\n]', Comment.Single) + ], + 'comment-multi': [ + include('comment'), + (r'[^*/]', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline) + ], + 'module': [ + (r'\n', Text, '#pop'), + (r'[a-zA-Z_]\w*', Name.Class), + include('root') + ], + 'preproc': [ + (r'\n', Text, '#pop'), + include('keywords'), + (r'[A-Za-z]\w*', Comment.Preproc), + include('root') + ], + 'string': [ + (r'\\\(', String.Interpol, 'string-intp'), + (r'"', String, '#pop'), + (r"""\\['"\\nrt]|\\x[0-9a-fA-F]{2}|\\[0-7]{1,3}""" + r"""|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}""", String.Escape), + (r'[^\\"]+', String), + (r'\\', String) + ], + 'string-intp': [ + (r'\(', String.Interpol, '#push'), + (r'\)', String.Interpol, '#pop'), + include('root') + ] + } + + def get_tokens_unprocessed(self, text): + from pygments.lexers._cocoa_builtins import COCOA_INTERFACES, \ + COCOA_PROTOCOLS, COCOA_PRIMITIVES + + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text): + if token is Name or token is Name.Class: + if value in COCOA_INTERFACES or value in COCOA_PROTOCOLS \ + or value in COCOA_PRIMITIVES: + token = Name.Builtin.Pseudo + + yield index, token, value diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ooc.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ooc.py new file mode 100644 index 0000000000..b58d347248 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ooc.py @@ -0,0 +1,85 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.ooc + ~~~~~~~~~~~~~~~~~~~ + + Lexers for the Ooc language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, bygroups, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['OocLexer'] + + +class OocLexer(RegexLexer): + """ + For `Ooc `_ source code + + .. versionadded:: 1.2 + """ + name = 'Ooc' + aliases = ['ooc'] + filenames = ['*.ooc'] + mimetypes = ['text/x-ooc'] + + tokens = { + 'root': [ + (words(( + 'class', 'interface', 'implement', 'abstract', 'extends', 'from', + 'this', 'super', 'new', 'const', 'final', 'static', 'import', + 'use', 'extern', 'inline', 'proto', 'break', 'continue', + 'fallthrough', 'operator', 'if', 'else', 'for', 'while', 'do', + 'switch', 'case', 'as', 'in', 'version', 'return', 'true', + 'false', 'null'), prefix=r'\b', suffix=r'\b'), + Keyword), + (r'include\b', Keyword, 'include'), + (r'(cover)([ \t]+)(from)([ \t]+)(\w+[*@]?)', + bygroups(Keyword, Text, Keyword, Text, Name.Class)), + (r'(func)((?:[ \t]|\\\n)+)(~[a-z_]\w*)', + bygroups(Keyword, Text, Name.Function)), + (r'\bfunc\b', Keyword), + # Note: %= and ^= not listed on http://ooc-lang.org/syntax + (r'//.*', Comment), + (r'(?s)/\*.*?\*/', Comment.Multiline), + (r'(==?|\+=?|-[=>]?|\*=?|/=?|:=|!=?|%=?|\?|>{1,3}=?|<{1,3}=?|\.\.|' + r'&&?|\|\|?|\^=?)', Operator), + (r'(\.)([ \t]*)([a-z]\w*)', bygroups(Operator, Text, + Name.Function)), + (r'[A-Z][A-Z0-9_]+', Name.Constant), + (r'[A-Z]\w*([@*]|\[[ \t]*\])?', Name.Class), + + (r'([a-z]\w*(?:~[a-z]\w*)?)((?:[ \t]|\\\n)*)(?=\()', + bygroups(Name.Function, Text)), + (r'[a-z]\w*', Name.Variable), + + # : introduces types + (r'[:(){}\[\];,]', Punctuation), + + (r'0x[0-9a-fA-F]+', Number.Hex), + (r'0c[0-9]+', Number.Oct), + (r'0b[01]+', Number.Bin), + (r'[0-9_]\.[0-9_]*(?!\.)', Number.Float), + (r'[0-9_]+', Number.Decimal), + + (r'"(?:\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\"])*"', + String.Double), + (r"'(?:\\.|\\[0-9]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", + String.Char), + (r'@', Punctuation), # pointer dereference + (r'\.', Punctuation), # imports or chain operator + + (r'\\[ \t\n]', Text), + (r'[ \t]+', Text), + ], + 'include': [ + (r'[\w/]+', Name), + (r',', Punctuation), + (r'[ \t]', Text), + (r'[;\n]', Text, '#pop'), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/other.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/other.py new file mode 100644 index 0000000000..cde764a2b2 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/other.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.other + ~~~~~~~~~~~~~~~~~~~~~ + + Just export lexer classes previously contained in this module. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexers.sql import SqlLexer, MySqlLexer, SqliteConsoleLexer +from pygments.lexers.shell import BashLexer, BashSessionLexer, BatchLexer, \ + TcshLexer +from pygments.lexers.robotframework import RobotFrameworkLexer +from pygments.lexers.testing import GherkinLexer +from pygments.lexers.esoteric import BrainfuckLexer, BefungeLexer, RedcodeLexer +from pygments.lexers.prolog import LogtalkLexer +from pygments.lexers.snobol import SnobolLexer +from pygments.lexers.rebol import RebolLexer +from pygments.lexers.configs import KconfigLexer, Cfengine3Lexer +from pygments.lexers.modeling import ModelicaLexer +from pygments.lexers.scripting import AppleScriptLexer, MOOCodeLexer, \ + HybrisLexer +from pygments.lexers.graphics import PostScriptLexer, GnuplotLexer, \ + AsymptoteLexer, PovrayLexer +from pygments.lexers.business import ABAPLexer, OpenEdgeLexer, \ + GoodDataCLLexer, MaqlLexer +from pygments.lexers.automation import AutoItLexer, AutohotkeyLexer +from pygments.lexers.dsls import ProtoBufLexer, BroLexer, PuppetLexer, \ + MscgenLexer, VGLLexer +from pygments.lexers.basic import CbmBasicV2Lexer +from pygments.lexers.pawn import SourcePawnLexer, PawnLexer +from pygments.lexers.ecl import ECLLexer +from pygments.lexers.urbi import UrbiscriptLexer +from pygments.lexers.smalltalk import SmalltalkLexer, NewspeakLexer +from pygments.lexers.installers import NSISLexer, RPMSpecLexer +from pygments.lexers.textedit import AwkLexer + +__all__ = [] diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/parsers.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/parsers.py new file mode 100644 index 0000000000..91add67fd8 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/parsers.py @@ -0,0 +1,835 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.parsers + ~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for parser generators. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, DelegatingLexer, \ + include, bygroups, using +from pygments.token import Punctuation, Other, Text, Comment, Operator, \ + Keyword, Name, String, Number, Whitespace +from pygments.lexers.jvm import JavaLexer +from pygments.lexers.c_cpp import CLexer, CppLexer +from pygments.lexers.objective import ObjectiveCLexer +from pygments.lexers.d import DLexer +from pygments.lexers.dotnet import CSharpLexer +from pygments.lexers.ruby import RubyLexer +from pygments.lexers.python import PythonLexer +from pygments.lexers.perl import PerlLexer + +__all__ = ['RagelLexer', 'RagelEmbeddedLexer', 'RagelCLexer', 'RagelDLexer', + 'RagelCppLexer', 'RagelObjectiveCLexer', 'RagelRubyLexer', + 'RagelJavaLexer', 'AntlrLexer', 'AntlrPythonLexer', + 'AntlrPerlLexer', 'AntlrRubyLexer', 'AntlrCppLexer', + # 'AntlrCLexer', + 'AntlrCSharpLexer', 'AntlrObjectiveCLexer', + 'AntlrJavaLexer', 'AntlrActionScriptLexer', + 'TreetopLexer', 'EbnfLexer'] + + +class RagelLexer(RegexLexer): + """ + A pure `Ragel `_ lexer. Use this for + fragments of Ragel. For ``.rl`` files, use RagelEmbeddedLexer instead + (or one of the language-specific subclasses). + + .. versionadded:: 1.1 + """ + + name = 'Ragel' + aliases = ['ragel'] + filenames = [] + + tokens = { + 'whitespace': [ + (r'\s+', Whitespace) + ], + 'comments': [ + (r'\#.*$', Comment), + ], + 'keywords': [ + (r'(access|action|alphtype)\b', Keyword), + (r'(getkey|write|machine|include)\b', Keyword), + (r'(any|ascii|extend|alpha|digit|alnum|lower|upper)\b', Keyword), + (r'(xdigit|cntrl|graph|print|punct|space|zlen|empty)\b', Keyword) + ], + 'numbers': [ + (r'0x[0-9A-Fa-f]+', Number.Hex), + (r'[+-]?[0-9]+', Number.Integer), + ], + 'literals': [ + (r'"(\\\\|\\"|[^"])*"', String), # double quote string + (r"'(\\\\|\\'|[^'])*'", String), # single quote string + (r'\[(\\\\|\\\]|[^\]])*\]', String), # square bracket literals + (r'/(?!\*)(\\\\|\\/|[^/])*/', String.Regex), # regular expressions + ], + 'identifiers': [ + (r'[a-zA-Z_]\w*', Name.Variable), + ], + 'operators': [ + (r',', Operator), # Join + (r'\||&|--?', Operator), # Union, Intersection and Subtraction + (r'\.|<:|:>>?', Operator), # Concatention + (r':', Operator), # Label + (r'->', Operator), # Epsilon Transition + (r'(>|\$|%|<|@|<>)(/|eof\b)', Operator), # EOF Actions + (r'(>|\$|%|<|@|<>)(!|err\b)', Operator), # Global Error Actions + (r'(>|\$|%|<|@|<>)(\^|lerr\b)', Operator), # Local Error Actions + (r'(>|\$|%|<|@|<>)(~|to\b)', Operator), # To-State Actions + (r'(>|\$|%|<|@|<>)(\*|from\b)', Operator), # From-State Actions + (r'>|@|\$|%', Operator), # Transition Actions and Priorities + (r'\*|\?|\+|\{[0-9]*,[0-9]*\}', Operator), # Repetition + (r'!|\^', Operator), # Negation + (r'\(|\)', Operator), # Grouping + ], + 'root': [ + include('literals'), + include('whitespace'), + include('comments'), + include('keywords'), + include('numbers'), + include('identifiers'), + include('operators'), + (r'\{', Punctuation, 'host'), + (r'=', Operator), + (r';', Punctuation), + ], + 'host': [ + (r'(' + r'|'.join(( # keep host code in largest possible chunks + r'[^{}\'"/#]+', # exclude unsafe characters + r'[^\\]\\[{}]', # allow escaped { or } + + # strings and comments may safely contain unsafe characters + r'"(\\\\|\\"|[^"])*"', # double quote string + r"'(\\\\|\\'|[^'])*'", # single quote string + r'//.*$\n?', # single line comment + r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment + r'\#.*$\n?', # ruby comment + + # regular expression: There's no reason for it to start + # with a * and this stops confusion with comments. + r'/(?!\*)(\\\\|\\/|[^/])*/', + + # / is safe now that we've handled regex and javadoc comments + r'/', + )) + r')+', Other), + + (r'\{', Punctuation, '#push'), + (r'\}', Punctuation, '#pop'), + ], + } + + +class RagelEmbeddedLexer(RegexLexer): + """ + A lexer for `Ragel`_ embedded in a host language file. + + This will only highlight Ragel statements. If you want host language + highlighting then call the language-specific Ragel lexer. + + .. versionadded:: 1.1 + """ + + name = 'Embedded Ragel' + aliases = ['ragel-em'] + filenames = ['*.rl'] + + tokens = { + 'root': [ + (r'(' + r'|'.join(( # keep host code in largest possible chunks + r'[^%\'"/#]+', # exclude unsafe characters + r'%(?=[^%]|$)', # a single % sign is okay, just not 2 of them + + # strings and comments may safely contain unsafe characters + r'"(\\\\|\\"|[^"])*"', # double quote string + r"'(\\\\|\\'|[^'])*'", # single quote string + r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment + r'//.*$\n?', # single line comment + r'\#.*$\n?', # ruby/ragel comment + r'/(?!\*)(\\\\|\\/|[^/])*/', # regular expression + + # / is safe now that we've handled regex and javadoc comments + r'/', + )) + r')+', Other), + + # Single Line FSM. + # Please don't put a quoted newline in a single line FSM. + # That's just mean. It will break this. + (r'(%%)(?![{%])(.*)($|;)(\n?)', bygroups(Punctuation, + using(RagelLexer), + Punctuation, Text)), + + # Multi Line FSM. + (r'(%%%%|%%)\{', Punctuation, 'multi-line-fsm'), + ], + 'multi-line-fsm': [ + (r'(' + r'|'.join(( # keep ragel code in largest possible chunks. + r'(' + r'|'.join(( + r'[^}\'"\[/#]', # exclude unsafe characters + r'\}(?=[^%]|$)', # } is okay as long as it's not followed by % + r'\}%(?=[^%]|$)', # ...well, one %'s okay, just not two... + r'[^\\]\\[{}]', # ...and } is okay if it's escaped + + # allow / if it's preceded with one of these symbols + # (ragel EOF actions) + r'(>|\$|%|<|@|<>)/', + + # specifically allow regex followed immediately by * + # so it doesn't get mistaken for a comment + r'/(?!\*)(\\\\|\\/|[^/])*/\*', + + # allow / as long as it's not followed by another / or by a * + r'/(?=[^/*]|$)', + + # We want to match as many of these as we can in one block. + # Not sure if we need the + sign here, + # does it help performance? + )) + r')+', + + # strings and comments may safely contain unsafe characters + r'"(\\\\|\\"|[^"])*"', # double quote string + r"'(\\\\|\\'|[^'])*'", # single quote string + r"\[(\\\\|\\\]|[^\]])*\]", # square bracket literal + r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment + r'//.*$\n?', # single line comment + r'\#.*$\n?', # ruby/ragel comment + )) + r')+', using(RagelLexer)), + + (r'\}%%', Punctuation, '#pop'), + ] + } + + def analyse_text(text): + return '@LANG: indep' in text + + +class RagelRubyLexer(DelegatingLexer): + """ + A lexer for `Ragel`_ in a Ruby host file. + + .. versionadded:: 1.1 + """ + + name = 'Ragel in Ruby Host' + aliases = ['ragel-ruby', 'ragel-rb'] + filenames = ['*.rl'] + + def __init__(self, **options): + super(RagelRubyLexer, self).__init__(RubyLexer, RagelEmbeddedLexer, + **options) + + def analyse_text(text): + return '@LANG: ruby' in text + + +class RagelCLexer(DelegatingLexer): + """ + A lexer for `Ragel`_ in a C host file. + + .. versionadded:: 1.1 + """ + + name = 'Ragel in C Host' + aliases = ['ragel-c'] + filenames = ['*.rl'] + + def __init__(self, **options): + super(RagelCLexer, self).__init__(CLexer, RagelEmbeddedLexer, + **options) + + def analyse_text(text): + return '@LANG: c' in text + + +class RagelDLexer(DelegatingLexer): + """ + A lexer for `Ragel`_ in a D host file. + + .. versionadded:: 1.1 + """ + + name = 'Ragel in D Host' + aliases = ['ragel-d'] + filenames = ['*.rl'] + + def __init__(self, **options): + super(RagelDLexer, self).__init__(DLexer, RagelEmbeddedLexer, **options) + + def analyse_text(text): + return '@LANG: d' in text + + +class RagelCppLexer(DelegatingLexer): + """ + A lexer for `Ragel`_ in a CPP host file. + + .. versionadded:: 1.1 + """ + + name = 'Ragel in CPP Host' + aliases = ['ragel-cpp'] + filenames = ['*.rl'] + + def __init__(self, **options): + super(RagelCppLexer, self).__init__(CppLexer, RagelEmbeddedLexer, **options) + + def analyse_text(text): + return '@LANG: c++' in text + + +class RagelObjectiveCLexer(DelegatingLexer): + """ + A lexer for `Ragel`_ in an Objective C host file. + + .. versionadded:: 1.1 + """ + + name = 'Ragel in Objective C Host' + aliases = ['ragel-objc'] + filenames = ['*.rl'] + + def __init__(self, **options): + super(RagelObjectiveCLexer, self).__init__(ObjectiveCLexer, + RagelEmbeddedLexer, + **options) + + def analyse_text(text): + return '@LANG: objc' in text + + +class RagelJavaLexer(DelegatingLexer): + """ + A lexer for `Ragel`_ in a Java host file. + + .. versionadded:: 1.1 + """ + + name = 'Ragel in Java Host' + aliases = ['ragel-java'] + filenames = ['*.rl'] + + def __init__(self, **options): + super(RagelJavaLexer, self).__init__(JavaLexer, RagelEmbeddedLexer, + **options) + + def analyse_text(text): + return '@LANG: java' in text + + +class AntlrLexer(RegexLexer): + """ + Generic `ANTLR`_ Lexer. + Should not be called directly, instead + use DelegatingLexer for your target language. + + .. versionadded:: 1.1 + + .. _ANTLR: http://www.antlr.org/ + """ + + name = 'ANTLR' + aliases = ['antlr'] + filenames = [] + + _id = r'[A-Za-z]\w*' + _TOKEN_REF = r'[A-Z]\w*' + _RULE_REF = r'[a-z]\w*' + _STRING_LITERAL = r'\'(?:\\\\|\\\'|[^\']*)\'' + _INT = r'[0-9]+' + + tokens = { + 'whitespace': [ + (r'\s+', Whitespace), + ], + 'comments': [ + (r'//.*$', Comment), + (r'/\*(.|\n)*?\*/', Comment), + ], + 'root': [ + include('whitespace'), + include('comments'), + + (r'(lexer|parser|tree)?(\s*)(grammar\b)(\s*)(' + _id + ')(;)', + bygroups(Keyword, Whitespace, Keyword, Whitespace, Name.Class, + Punctuation)), + # optionsSpec + (r'options\b', Keyword, 'options'), + # tokensSpec + (r'tokens\b', Keyword, 'tokens'), + # attrScope + (r'(scope)(\s*)(' + _id + ')(\s*)(\{)', + bygroups(Keyword, Whitespace, Name.Variable, Whitespace, + Punctuation), 'action'), + # exception + (r'(catch|finally)\b', Keyword, 'exception'), + # action + (r'(@' + _id + ')(\s*)(::)?(\s*)(' + _id + ')(\s*)(\{)', + bygroups(Name.Label, Whitespace, Punctuation, Whitespace, + Name.Label, Whitespace, Punctuation), 'action'), + # rule + (r'((?:protected|private|public|fragment)\b)?(\s*)(' + _id + ')(!)?', + bygroups(Keyword, Whitespace, Name.Label, Punctuation), + ('rule-alts', 'rule-prelims')), + ], + 'exception': [ + (r'\n', Whitespace, '#pop'), + (r'\s', Whitespace), + include('comments'), + + (r'\[', Punctuation, 'nested-arg-action'), + (r'\{', Punctuation, 'action'), + ], + 'rule-prelims': [ + include('whitespace'), + include('comments'), + + (r'returns\b', Keyword), + (r'\[', Punctuation, 'nested-arg-action'), + (r'\{', Punctuation, 'action'), + # throwsSpec + (r'(throws)(\s+)(' + _id + ')', + bygroups(Keyword, Whitespace, Name.Label)), + (r'(,)(\s*)(' + _id + ')', + bygroups(Punctuation, Whitespace, Name.Label)), # Additional throws + # optionsSpec + (r'options\b', Keyword, 'options'), + # ruleScopeSpec - scope followed by target language code or name of action + # TODO finish implementing other possibilities for scope + # L173 ANTLRv3.g from ANTLR book + (r'(scope)(\s+)(\{)', bygroups(Keyword, Whitespace, Punctuation), + 'action'), + (r'(scope)(\s+)(' + _id + ')(\s*)(;)', + bygroups(Keyword, Whitespace, Name.Label, Whitespace, Punctuation)), + # ruleAction + (r'(@' + _id + ')(\s*)(\{)', + bygroups(Name.Label, Whitespace, Punctuation), 'action'), + # finished prelims, go to rule alts! + (r':', Punctuation, '#pop') + ], + 'rule-alts': [ + include('whitespace'), + include('comments'), + + # These might need to go in a separate 'block' state triggered by ( + (r'options\b', Keyword, 'options'), + (r':', Punctuation), + + # literals + (r"'(\\\\|\\'|[^'])*'", String), + (r'"(\\\\|\\"|[^"])*"', String), + (r'<<([^>]|>[^>])>>', String), + # identifiers + # Tokens start with capital letter. + (r'\$?[A-Z_]\w*', Name.Constant), + # Rules start with small letter. + (r'\$?[a-z_]\w*', Name.Variable), + # operators + (r'(\+|\||->|=>|=|\(|\)|\.\.|\.|\?|\*|\^|!|\#|~)', Operator), + (r',', Punctuation), + (r'\[', Punctuation, 'nested-arg-action'), + (r'\{', Punctuation, 'action'), + (r';', Punctuation, '#pop') + ], + 'tokens': [ + include('whitespace'), + include('comments'), + (r'\{', Punctuation), + (r'(' + _TOKEN_REF + r')(\s*)(=)?(\s*)(' + _STRING_LITERAL + + ')?(\s*)(;)', + bygroups(Name.Label, Whitespace, Punctuation, Whitespace, + String, Whitespace, Punctuation)), + (r'\}', Punctuation, '#pop'), + ], + 'options': [ + include('whitespace'), + include('comments'), + (r'\{', Punctuation), + (r'(' + _id + r')(\s*)(=)(\s*)(' + + '|'.join((_id, _STRING_LITERAL, _INT, '\*')) + ')(\s*)(;)', + bygroups(Name.Variable, Whitespace, Punctuation, Whitespace, + Text, Whitespace, Punctuation)), + (r'\}', Punctuation, '#pop'), + ], + 'action': [ + (r'(' + r'|'.join(( # keep host code in largest possible chunks + r'[^${}\'"/\\]+', # exclude unsafe characters + + # strings and comments may safely contain unsafe characters + r'"(\\\\|\\"|[^"])*"', # double quote string + r"'(\\\\|\\'|[^'])*'", # single quote string + r'//.*$\n?', # single line comment + r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment + + # regular expression: There's no reason for it to start + # with a * and this stops confusion with comments. + r'/(?!\*)(\\\\|\\/|[^/])*/', + + # backslashes are okay, as long as we are not backslashing a % + r'\\(?!%)', + + # Now that we've handled regex and javadoc comments + # it's safe to let / through. + r'/', + )) + r')+', Other), + (r'(\\)(%)', bygroups(Punctuation, Other)), + (r'(\$[a-zA-Z]+)(\.?)(text|value)?', + bygroups(Name.Variable, Punctuation, Name.Property)), + (r'\{', Punctuation, '#push'), + (r'\}', Punctuation, '#pop'), + ], + 'nested-arg-action': [ + (r'(' + r'|'.join(( # keep host code in largest possible chunks. + r'[^$\[\]\'"/]+', # exclude unsafe characters + + # strings and comments may safely contain unsafe characters + r'"(\\\\|\\"|[^"])*"', # double quote string + r"'(\\\\|\\'|[^'])*'", # single quote string + r'//.*$\n?', # single line comment + r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment + + # regular expression: There's no reason for it to start + # with a * and this stops confusion with comments. + r'/(?!\*)(\\\\|\\/|[^/])*/', + + # Now that we've handled regex and javadoc comments + # it's safe to let / through. + r'/', + )) + r')+', Other), + + + (r'\[', Punctuation, '#push'), + (r'\]', Punctuation, '#pop'), + (r'(\$[a-zA-Z]+)(\.?)(text|value)?', + bygroups(Name.Variable, Punctuation, Name.Property)), + (r'(\\\\|\\\]|\\\[|[^\[\]])+', Other), + ] + } + + def analyse_text(text): + return re.search(r'^\s*grammar\s+[a-zA-Z0-9]+\s*;', text, re.M) + +# http://www.antlr.org/wiki/display/ANTLR3/Code+Generation+Targets + +# TH: I'm not aware of any language features of C++ that will cause +# incorrect lexing of C files. Antlr doesn't appear to make a distinction, +# so just assume they're C++. No idea how to make Objective C work in the +# future. + +# class AntlrCLexer(DelegatingLexer): +# """ +# ANTLR with C Target +# +# .. versionadded:: 1.1 +# """ +# +# name = 'ANTLR With C Target' +# aliases = ['antlr-c'] +# filenames = ['*.G', '*.g'] +# +# def __init__(self, **options): +# super(AntlrCLexer, self).__init__(CLexer, AntlrLexer, **options) +# +# def analyse_text(text): +# return re.match(r'^\s*language\s*=\s*C\s*;', text) + + +class AntlrCppLexer(DelegatingLexer): + """ + `ANTLR`_ with CPP Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With CPP Target' + aliases = ['antlr-cpp'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrCppLexer, self).__init__(CppLexer, AntlrLexer, **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*C\s*;', text, re.M) + + +class AntlrObjectiveCLexer(DelegatingLexer): + """ + `ANTLR`_ with Objective-C Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With ObjectiveC Target' + aliases = ['antlr-objc'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrObjectiveCLexer, self).__init__(ObjectiveCLexer, + AntlrLexer, **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*ObjC\s*;', text) + + +class AntlrCSharpLexer(DelegatingLexer): + """ + `ANTLR`_ with C# Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With C# Target' + aliases = ['antlr-csharp', 'antlr-c#'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrCSharpLexer, self).__init__(CSharpLexer, AntlrLexer, + **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*CSharp2\s*;', text, re.M) + + +class AntlrPythonLexer(DelegatingLexer): + """ + `ANTLR`_ with Python Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With Python Target' + aliases = ['antlr-python'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrPythonLexer, self).__init__(PythonLexer, AntlrLexer, + **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*Python\s*;', text, re.M) + + +class AntlrJavaLexer(DelegatingLexer): + """ + `ANTLR`_ with Java Target + + .. versionadded:: 1. + """ + + name = 'ANTLR With Java Target' + aliases = ['antlr-java'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrJavaLexer, self).__init__(JavaLexer, AntlrLexer, + **options) + + def analyse_text(text): + # Antlr language is Java by default + return AntlrLexer.analyse_text(text) and 0.9 + + +class AntlrRubyLexer(DelegatingLexer): + """ + `ANTLR`_ with Ruby Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With Ruby Target' + aliases = ['antlr-ruby', 'antlr-rb'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrRubyLexer, self).__init__(RubyLexer, AntlrLexer, + **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*Ruby\s*;', text, re.M) + + +class AntlrPerlLexer(DelegatingLexer): + """ + `ANTLR`_ with Perl Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With Perl Target' + aliases = ['antlr-perl'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + super(AntlrPerlLexer, self).__init__(PerlLexer, AntlrLexer, + **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*Perl5\s*;', text, re.M) + + +class AntlrActionScriptLexer(DelegatingLexer): + """ + `ANTLR`_ with ActionScript Target + + .. versionadded:: 1.1 + """ + + name = 'ANTLR With ActionScript Target' + aliases = ['antlr-as', 'antlr-actionscript'] + filenames = ['*.G', '*.g'] + + def __init__(self, **options): + from pygments.lexers.actionscript import ActionScriptLexer + super(AntlrActionScriptLexer, self).__init__(ActionScriptLexer, + AntlrLexer, **options) + + def analyse_text(text): + return AntlrLexer.analyse_text(text) and \ + re.search(r'^\s*language\s*=\s*ActionScript\s*;', text, re.M) + + +class TreetopBaseLexer(RegexLexer): + """ + A base lexer for `Treetop `_ grammars. + Not for direct use; use TreetopLexer instead. + + .. versionadded:: 1.6 + """ + + tokens = { + 'root': [ + include('space'), + (r'require[ \t]+[^\n\r]+[\n\r]', Other), + (r'module\b', Keyword.Namespace, 'module'), + (r'grammar\b', Keyword, 'grammar'), + ], + 'module': [ + include('space'), + include('end'), + (r'module\b', Keyword, '#push'), + (r'grammar\b', Keyword, 'grammar'), + (r'[A-Z]\w*(?:::[A-Z]\w*)*', Name.Namespace), + ], + 'grammar': [ + include('space'), + include('end'), + (r'rule\b', Keyword, 'rule'), + (r'include\b', Keyword, 'include'), + (r'[A-Z]\w*', Name), + ], + 'include': [ + include('space'), + (r'[A-Z]\w*(?:::[A-Z]\w*)*', Name.Class, '#pop'), + ], + 'rule': [ + include('space'), + include('end'), + (r'"(\\\\|\\"|[^"])*"', String.Double), + (r"'(\\\\|\\'|[^'])*'", String.Single), + (r'([A-Za-z_]\w*)(:)', bygroups(Name.Label, Punctuation)), + (r'[A-Za-z_]\w*', Name), + (r'[()]', Punctuation), + (r'[?+*/&!~]', Operator), + (r'\[(?:\\.|\[:\^?[a-z]+:\]|[^\\\]])+\]', String.Regex), + (r'([0-9]*)(\.\.)([0-9]*)', + bygroups(Number.Integer, Operator, Number.Integer)), + (r'(<)([^>]+)(>)', bygroups(Punctuation, Name.Class, Punctuation)), + (r'\{', Punctuation, 'inline_module'), + (r'\.', String.Regex), + ], + 'inline_module': [ + (r'\{', Other, 'ruby'), + (r'\}', Punctuation, '#pop'), + (r'[^{}]+', Other), + ], + 'ruby': [ + (r'\{', Other, '#push'), + (r'\}', Other, '#pop'), + (r'[^{}]+', Other), + ], + 'space': [ + (r'[ \t\n\r]+', Whitespace), + (r'#[^\n]*', Comment.Single), + ], + 'end': [ + (r'end\b', Keyword, '#pop'), + ], + } + + +class TreetopLexer(DelegatingLexer): + """ + A lexer for `Treetop `_ grammars. + + .. versionadded:: 1.6 + """ + + name = 'Treetop' + aliases = ['treetop'] + filenames = ['*.treetop', '*.tt'] + + def __init__(self, **options): + super(TreetopLexer, self).__init__(RubyLexer, TreetopBaseLexer, **options) + + +class EbnfLexer(RegexLexer): + """ + Lexer for `ISO/IEC 14977 EBNF + `_ + grammars. + + .. versionadded:: 2.0 + """ + + name = 'EBNF' + aliases = ['ebnf'] + filenames = ['*.ebnf'] + mimetypes = ['text/x-ebnf'] + + tokens = { + 'root': [ + include('whitespace'), + include('comment_start'), + include('identifier'), + (r'=', Operator, 'production'), + ], + 'production': [ + include('whitespace'), + include('comment_start'), + include('identifier'), + (r'"[^"]*"', String.Double), + (r"'[^']*'", String.Single), + (r'(\?[^?]*\?)', Name.Entity), + (r'[\[\]{}(),|]', Punctuation), + (r'-', Operator), + (r';', Punctuation, '#pop'), + (r'\.', Punctuation, '#pop'), + ], + 'whitespace': [ + (r'\s+', Text), + ], + 'comment_start': [ + (r'\(\*', Comment.Multiline, 'comment'), + ], + 'comment': [ + (r'[^*)]', Comment.Multiline), + include('comment_start'), + (r'\*\)', Comment.Multiline, '#pop'), + (r'[*)]', Comment.Multiline), + ], + 'identifier': [ + (r'([a-zA-Z][\w \-]*)', Keyword), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pascal.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pascal.py new file mode 100644 index 0000000000..54877485e1 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pascal.py @@ -0,0 +1,831 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.pascal + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Pascal family languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, include, bygroups, words, \ + using, this, default +from pygments.util import get_bool_opt, get_list_opt +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error +from pygments.scanner import Scanner + +__all__ = ['DelphiLexer', 'Modula2Lexer', 'AdaLexer'] + + +class DelphiLexer(Lexer): + """ + For `Delphi `_ (Borland Object Pascal), + Turbo Pascal and Free Pascal source code. + + Additional options accepted: + + `turbopascal` + Highlight Turbo Pascal specific keywords (default: ``True``). + `delphi` + Highlight Borland Delphi specific keywords (default: ``True``). + `freepascal` + Highlight Free Pascal specific keywords (default: ``True``). + `units` + A list of units that should be considered builtin, supported are + ``System``, ``SysUtils``, ``Classes`` and ``Math``. + Default is to consider all of them builtin. + """ + name = 'Delphi' + aliases = ['delphi', 'pas', 'pascal', 'objectpascal'] + filenames = ['*.pas'] + mimetypes = ['text/x-pascal'] + + TURBO_PASCAL_KEYWORDS = ( + 'absolute', 'and', 'array', 'asm', 'begin', 'break', 'case', + 'const', 'constructor', 'continue', 'destructor', 'div', 'do', + 'downto', 'else', 'end', 'file', 'for', 'function', 'goto', + 'if', 'implementation', 'in', 'inherited', 'inline', 'interface', + 'label', 'mod', 'nil', 'not', 'object', 'of', 'on', 'operator', + 'or', 'packed', 'procedure', 'program', 'record', 'reintroduce', + 'repeat', 'self', 'set', 'shl', 'shr', 'string', 'then', 'to', + 'type', 'unit', 'until', 'uses', 'var', 'while', 'with', 'xor' + ) + + DELPHI_KEYWORDS = ( + 'as', 'class', 'except', 'exports', 'finalization', 'finally', + 'initialization', 'is', 'library', 'on', 'property', 'raise', + 'threadvar', 'try' + ) + + FREE_PASCAL_KEYWORDS = ( + 'dispose', 'exit', 'false', 'new', 'true' + ) + + BLOCK_KEYWORDS = set(( + 'begin', 'class', 'const', 'constructor', 'destructor', 'end', + 'finalization', 'function', 'implementation', 'initialization', + 'label', 'library', 'operator', 'procedure', 'program', 'property', + 'record', 'threadvar', 'type', 'unit', 'uses', 'var' + )) + + FUNCTION_MODIFIERS = set(( + 'alias', 'cdecl', 'export', 'inline', 'interrupt', 'nostackframe', + 'pascal', 'register', 'safecall', 'softfloat', 'stdcall', + 'varargs', 'name', 'dynamic', 'near', 'virtual', 'external', + 'override', 'assembler' + )) + + # XXX: those aren't global. but currently we know no way for defining + # them just for the type context. + DIRECTIVES = set(( + 'absolute', 'abstract', 'assembler', 'cppdecl', 'default', 'far', + 'far16', 'forward', 'index', 'oldfpccall', 'private', 'protected', + 'published', 'public' + )) + + BUILTIN_TYPES = set(( + 'ansichar', 'ansistring', 'bool', 'boolean', 'byte', 'bytebool', + 'cardinal', 'char', 'comp', 'currency', 'double', 'dword', + 'extended', 'int64', 'integer', 'iunknown', 'longbool', 'longint', + 'longword', 'pansichar', 'pansistring', 'pbool', 'pboolean', + 'pbyte', 'pbytearray', 'pcardinal', 'pchar', 'pcomp', 'pcurrency', + 'pdate', 'pdatetime', 'pdouble', 'pdword', 'pextended', 'phandle', + 'pint64', 'pinteger', 'plongint', 'plongword', 'pointer', + 'ppointer', 'pshortint', 'pshortstring', 'psingle', 'psmallint', + 'pstring', 'pvariant', 'pwidechar', 'pwidestring', 'pword', + 'pwordarray', 'pwordbool', 'real', 'real48', 'shortint', + 'shortstring', 'single', 'smallint', 'string', 'tclass', 'tdate', + 'tdatetime', 'textfile', 'thandle', 'tobject', 'ttime', 'variant', + 'widechar', 'widestring', 'word', 'wordbool' + )) + + BUILTIN_UNITS = { + 'System': ( + 'abs', 'acquireexceptionobject', 'addr', 'ansitoutf8', + 'append', 'arctan', 'assert', 'assigned', 'assignfile', + 'beginthread', 'blockread', 'blockwrite', 'break', 'chdir', + 'chr', 'close', 'closefile', 'comptocurrency', 'comptodouble', + 'concat', 'continue', 'copy', 'cos', 'dec', 'delete', + 'dispose', 'doubletocomp', 'endthread', 'enummodules', + 'enumresourcemodules', 'eof', 'eoln', 'erase', 'exceptaddr', + 'exceptobject', 'exclude', 'exit', 'exp', 'filepos', 'filesize', + 'fillchar', 'finalize', 'findclasshinstance', 'findhinstance', + 'findresourcehinstance', 'flush', 'frac', 'freemem', + 'get8087cw', 'getdir', 'getlasterror', 'getmem', + 'getmemorymanager', 'getmodulefilename', 'getvariantmanager', + 'halt', 'hi', 'high', 'inc', 'include', 'initialize', 'insert', + 'int', 'ioresult', 'ismemorymanagerset', 'isvariantmanagerset', + 'length', 'ln', 'lo', 'low', 'mkdir', 'move', 'new', 'odd', + 'olestrtostring', 'olestrtostrvar', 'ord', 'paramcount', + 'paramstr', 'pi', 'pos', 'pred', 'ptr', 'pucs4chars', 'random', + 'randomize', 'read', 'readln', 'reallocmem', + 'releaseexceptionobject', 'rename', 'reset', 'rewrite', 'rmdir', + 'round', 'runerror', 'seek', 'seekeof', 'seekeoln', + 'set8087cw', 'setlength', 'setlinebreakstyle', + 'setmemorymanager', 'setstring', 'settextbuf', + 'setvariantmanager', 'sin', 'sizeof', 'slice', 'sqr', 'sqrt', + 'str', 'stringofchar', 'stringtoolestr', 'stringtowidechar', + 'succ', 'swap', 'trunc', 'truncate', 'typeinfo', + 'ucs4stringtowidestring', 'unicodetoutf8', 'uniquestring', + 'upcase', 'utf8decode', 'utf8encode', 'utf8toansi', + 'utf8tounicode', 'val', 'vararrayredim', 'varclear', + 'widecharlentostring', 'widecharlentostrvar', + 'widechartostring', 'widechartostrvar', + 'widestringtoucs4string', 'write', 'writeln' + ), + 'SysUtils': ( + 'abort', 'addexitproc', 'addterminateproc', 'adjustlinebreaks', + 'allocmem', 'ansicomparefilename', 'ansicomparestr', + 'ansicomparetext', 'ansidequotedstr', 'ansiextractquotedstr', + 'ansilastchar', 'ansilowercase', 'ansilowercasefilename', + 'ansipos', 'ansiquotedstr', 'ansisamestr', 'ansisametext', + 'ansistrcomp', 'ansistricomp', 'ansistrlastchar', 'ansistrlcomp', + 'ansistrlicomp', 'ansistrlower', 'ansistrpos', 'ansistrrscan', + 'ansistrscan', 'ansistrupper', 'ansiuppercase', + 'ansiuppercasefilename', 'appendstr', 'assignstr', 'beep', + 'booltostr', 'bytetocharindex', 'bytetocharlen', 'bytetype', + 'callterminateprocs', 'changefileext', 'charlength', + 'chartobyteindex', 'chartobytelen', 'comparemem', 'comparestr', + 'comparetext', 'createdir', 'createguid', 'currentyear', + 'currtostr', 'currtostrf', 'date', 'datetimetofiledate', + 'datetimetostr', 'datetimetostring', 'datetimetosystemtime', + 'datetimetotimestamp', 'datetostr', 'dayofweek', 'decodedate', + 'decodedatefully', 'decodetime', 'deletefile', 'directoryexists', + 'diskfree', 'disksize', 'disposestr', 'encodedate', 'encodetime', + 'exceptionerrormessage', 'excludetrailingbackslash', + 'excludetrailingpathdelimiter', 'expandfilename', + 'expandfilenamecase', 'expanduncfilename', 'extractfiledir', + 'extractfiledrive', 'extractfileext', 'extractfilename', + 'extractfilepath', 'extractrelativepath', 'extractshortpathname', + 'fileage', 'fileclose', 'filecreate', 'filedatetodatetime', + 'fileexists', 'filegetattr', 'filegetdate', 'fileisreadonly', + 'fileopen', 'fileread', 'filesearch', 'fileseek', 'filesetattr', + 'filesetdate', 'filesetreadonly', 'filewrite', 'finalizepackage', + 'findclose', 'findcmdlineswitch', 'findfirst', 'findnext', + 'floattocurr', 'floattodatetime', 'floattodecimal', 'floattostr', + 'floattostrf', 'floattotext', 'floattotextfmt', 'fmtloadstr', + 'fmtstr', 'forcedirectories', 'format', 'formatbuf', 'formatcurr', + 'formatdatetime', 'formatfloat', 'freeandnil', 'getcurrentdir', + 'getenvironmentvariable', 'getfileversion', 'getformatsettings', + 'getlocaleformatsettings', 'getmodulename', 'getpackagedescription', + 'getpackageinfo', 'gettime', 'guidtostring', 'incamonth', + 'includetrailingbackslash', 'includetrailingpathdelimiter', + 'incmonth', 'initializepackage', 'interlockeddecrement', + 'interlockedexchange', 'interlockedexchangeadd', + 'interlockedincrement', 'inttohex', 'inttostr', 'isdelimiter', + 'isequalguid', 'isleapyear', 'ispathdelimiter', 'isvalidident', + 'languages', 'lastdelimiter', 'loadpackage', 'loadstr', + 'lowercase', 'msecstotimestamp', 'newstr', 'nextcharindex', 'now', + 'outofmemoryerror', 'quotedstr', 'raiselastoserror', + 'raiselastwin32error', 'removedir', 'renamefile', 'replacedate', + 'replacetime', 'safeloadlibrary', 'samefilename', 'sametext', + 'setcurrentdir', 'showexception', 'sleep', 'stralloc', 'strbufsize', + 'strbytetype', 'strcat', 'strcharlength', 'strcomp', 'strcopy', + 'strdispose', 'strecopy', 'strend', 'strfmt', 'stricomp', + 'stringreplace', 'stringtoguid', 'strlcat', 'strlcomp', 'strlcopy', + 'strlen', 'strlfmt', 'strlicomp', 'strlower', 'strmove', 'strnew', + 'strnextchar', 'strpas', 'strpcopy', 'strplcopy', 'strpos', + 'strrscan', 'strscan', 'strtobool', 'strtobooldef', 'strtocurr', + 'strtocurrdef', 'strtodate', 'strtodatedef', 'strtodatetime', + 'strtodatetimedef', 'strtofloat', 'strtofloatdef', 'strtoint', + 'strtoint64', 'strtoint64def', 'strtointdef', 'strtotime', + 'strtotimedef', 'strupper', 'supports', 'syserrormessage', + 'systemtimetodatetime', 'texttofloat', 'time', 'timestamptodatetime', + 'timestamptomsecs', 'timetostr', 'trim', 'trimleft', 'trimright', + 'tryencodedate', 'tryencodetime', 'tryfloattocurr', 'tryfloattodatetime', + 'trystrtobool', 'trystrtocurr', 'trystrtodate', 'trystrtodatetime', + 'trystrtofloat', 'trystrtoint', 'trystrtoint64', 'trystrtotime', + 'unloadpackage', 'uppercase', 'widecomparestr', 'widecomparetext', + 'widefmtstr', 'wideformat', 'wideformatbuf', 'widelowercase', + 'widesamestr', 'widesametext', 'wideuppercase', 'win32check', + 'wraptext' + ), + 'Classes': ( + 'activateclassgroup', 'allocatehwnd', 'bintohex', 'checksynchronize', + 'collectionsequal', 'countgenerations', 'deallocatehwnd', 'equalrect', + 'extractstrings', 'findclass', 'findglobalcomponent', 'getclass', + 'groupdescendantswith', 'hextobin', 'identtoint', + 'initinheritedcomponent', 'inttoident', 'invalidpoint', + 'isuniqueglobalcomponentname', 'linestart', 'objectbinarytotext', + 'objectresourcetotext', 'objecttexttobinary', 'objecttexttoresource', + 'pointsequal', 'readcomponentres', 'readcomponentresex', + 'readcomponentresfile', 'rect', 'registerclass', 'registerclassalias', + 'registerclasses', 'registercomponents', 'registerintegerconsts', + 'registernoicon', 'registernonactivex', 'smallpoint', 'startclassgroup', + 'teststreamformat', 'unregisterclass', 'unregisterclasses', + 'unregisterintegerconsts', 'unregistermoduleclasses', + 'writecomponentresfile' + ), + 'Math': ( + 'arccos', 'arccosh', 'arccot', 'arccoth', 'arccsc', 'arccsch', 'arcsec', + 'arcsech', 'arcsin', 'arcsinh', 'arctan2', 'arctanh', 'ceil', + 'comparevalue', 'cosecant', 'cosh', 'cot', 'cotan', 'coth', 'csc', + 'csch', 'cycletodeg', 'cycletograd', 'cycletorad', 'degtocycle', + 'degtograd', 'degtorad', 'divmod', 'doubledecliningbalance', + 'ensurerange', 'floor', 'frexp', 'futurevalue', 'getexceptionmask', + 'getprecisionmode', 'getroundmode', 'gradtocycle', 'gradtodeg', + 'gradtorad', 'hypot', 'inrange', 'interestpayment', 'interestrate', + 'internalrateofreturn', 'intpower', 'isinfinite', 'isnan', 'iszero', + 'ldexp', 'lnxp1', 'log10', 'log2', 'logn', 'max', 'maxintvalue', + 'maxvalue', 'mean', 'meanandstddev', 'min', 'minintvalue', 'minvalue', + 'momentskewkurtosis', 'netpresentvalue', 'norm', 'numberofperiods', + 'payment', 'periodpayment', 'poly', 'popnstddev', 'popnvariance', + 'power', 'presentvalue', 'radtocycle', 'radtodeg', 'radtograd', + 'randg', 'randomrange', 'roundto', 'samevalue', 'sec', 'secant', + 'sech', 'setexceptionmask', 'setprecisionmode', 'setroundmode', + 'sign', 'simpleroundto', 'sincos', 'sinh', 'slndepreciation', 'stddev', + 'sum', 'sumint', 'sumofsquares', 'sumsandsquares', 'syddepreciation', + 'tan', 'tanh', 'totalvariance', 'variance' + ) + } + + ASM_REGISTERS = set(( + 'ah', 'al', 'ax', 'bh', 'bl', 'bp', 'bx', 'ch', 'cl', 'cr0', + 'cr1', 'cr2', 'cr3', 'cr4', 'cs', 'cx', 'dh', 'di', 'dl', 'dr0', + 'dr1', 'dr2', 'dr3', 'dr4', 'dr5', 'dr6', 'dr7', 'ds', 'dx', + 'eax', 'ebp', 'ebx', 'ecx', 'edi', 'edx', 'es', 'esi', 'esp', + 'fs', 'gs', 'mm0', 'mm1', 'mm2', 'mm3', 'mm4', 'mm5', 'mm6', + 'mm7', 'si', 'sp', 'ss', 'st0', 'st1', 'st2', 'st3', 'st4', 'st5', + 'st6', 'st7', 'xmm0', 'xmm1', 'xmm2', 'xmm3', 'xmm4', 'xmm5', + 'xmm6', 'xmm7' + )) + + ASM_INSTRUCTIONS = set(( + 'aaa', 'aad', 'aam', 'aas', 'adc', 'add', 'and', 'arpl', 'bound', + 'bsf', 'bsr', 'bswap', 'bt', 'btc', 'btr', 'bts', 'call', 'cbw', + 'cdq', 'clc', 'cld', 'cli', 'clts', 'cmc', 'cmova', 'cmovae', + 'cmovb', 'cmovbe', 'cmovc', 'cmovcxz', 'cmove', 'cmovg', + 'cmovge', 'cmovl', 'cmovle', 'cmovna', 'cmovnae', 'cmovnb', + 'cmovnbe', 'cmovnc', 'cmovne', 'cmovng', 'cmovnge', 'cmovnl', + 'cmovnle', 'cmovno', 'cmovnp', 'cmovns', 'cmovnz', 'cmovo', + 'cmovp', 'cmovpe', 'cmovpo', 'cmovs', 'cmovz', 'cmp', 'cmpsb', + 'cmpsd', 'cmpsw', 'cmpxchg', 'cmpxchg486', 'cmpxchg8b', 'cpuid', + 'cwd', 'cwde', 'daa', 'das', 'dec', 'div', 'emms', 'enter', 'hlt', + 'ibts', 'icebp', 'idiv', 'imul', 'in', 'inc', 'insb', 'insd', + 'insw', 'int', 'int01', 'int03', 'int1', 'int3', 'into', 'invd', + 'invlpg', 'iret', 'iretd', 'iretw', 'ja', 'jae', 'jb', 'jbe', + 'jc', 'jcxz', 'jcxz', 'je', 'jecxz', 'jg', 'jge', 'jl', 'jle', + 'jmp', 'jna', 'jnae', 'jnb', 'jnbe', 'jnc', 'jne', 'jng', 'jnge', + 'jnl', 'jnle', 'jno', 'jnp', 'jns', 'jnz', 'jo', 'jp', 'jpe', + 'jpo', 'js', 'jz', 'lahf', 'lar', 'lcall', 'lds', 'lea', 'leave', + 'les', 'lfs', 'lgdt', 'lgs', 'lidt', 'ljmp', 'lldt', 'lmsw', + 'loadall', 'loadall286', 'lock', 'lodsb', 'lodsd', 'lodsw', + 'loop', 'loope', 'loopne', 'loopnz', 'loopz', 'lsl', 'lss', 'ltr', + 'mov', 'movd', 'movq', 'movsb', 'movsd', 'movsw', 'movsx', + 'movzx', 'mul', 'neg', 'nop', 'not', 'or', 'out', 'outsb', 'outsd', + 'outsw', 'pop', 'popa', 'popad', 'popaw', 'popf', 'popfd', 'popfw', + 'push', 'pusha', 'pushad', 'pushaw', 'pushf', 'pushfd', 'pushfw', + 'rcl', 'rcr', 'rdmsr', 'rdpmc', 'rdshr', 'rdtsc', 'rep', 'repe', + 'repne', 'repnz', 'repz', 'ret', 'retf', 'retn', 'rol', 'ror', + 'rsdc', 'rsldt', 'rsm', 'sahf', 'sal', 'salc', 'sar', 'sbb', + 'scasb', 'scasd', 'scasw', 'seta', 'setae', 'setb', 'setbe', + 'setc', 'setcxz', 'sete', 'setg', 'setge', 'setl', 'setle', + 'setna', 'setnae', 'setnb', 'setnbe', 'setnc', 'setne', 'setng', + 'setnge', 'setnl', 'setnle', 'setno', 'setnp', 'setns', 'setnz', + 'seto', 'setp', 'setpe', 'setpo', 'sets', 'setz', 'sgdt', 'shl', + 'shld', 'shr', 'shrd', 'sidt', 'sldt', 'smi', 'smint', 'smintold', + 'smsw', 'stc', 'std', 'sti', 'stosb', 'stosd', 'stosw', 'str', + 'sub', 'svdc', 'svldt', 'svts', 'syscall', 'sysenter', 'sysexit', + 'sysret', 'test', 'ud1', 'ud2', 'umov', 'verr', 'verw', 'wait', + 'wbinvd', 'wrmsr', 'wrshr', 'xadd', 'xbts', 'xchg', 'xlat', + 'xlatb', 'xor' + )) + + def __init__(self, **options): + Lexer.__init__(self, **options) + self.keywords = set() + if get_bool_opt(options, 'turbopascal', True): + self.keywords.update(self.TURBO_PASCAL_KEYWORDS) + if get_bool_opt(options, 'delphi', True): + self.keywords.update(self.DELPHI_KEYWORDS) + if get_bool_opt(options, 'freepascal', True): + self.keywords.update(self.FREE_PASCAL_KEYWORDS) + self.builtins = set() + for unit in get_list_opt(options, 'units', list(self.BUILTIN_UNITS)): + self.builtins.update(self.BUILTIN_UNITS[unit]) + + def get_tokens_unprocessed(self, text): + scanner = Scanner(text, re.DOTALL | re.MULTILINE | re.IGNORECASE) + stack = ['initial'] + in_function_block = False + in_property_block = False + was_dot = False + next_token_is_function = False + next_token_is_property = False + collect_labels = False + block_labels = set() + brace_balance = [0, 0] + + while not scanner.eos: + token = Error + + if stack[-1] == 'initial': + if scanner.scan(r'\s+'): + token = Text + elif scanner.scan(r'\{.*?\}|\(\*.*?\*\)'): + if scanner.match.startswith('$'): + token = Comment.Preproc + else: + token = Comment.Multiline + elif scanner.scan(r'//.*?$'): + token = Comment.Single + elif scanner.scan(r'[-+*\/=<>:;,.@\^]'): + token = Operator + # stop label highlighting on next ";" + if collect_labels and scanner.match == ';': + collect_labels = False + elif scanner.scan(r'[\(\)\[\]]+'): + token = Punctuation + # abort function naming ``foo = Function(...)`` + next_token_is_function = False + # if we are in a function block we count the open + # braces because ootherwise it's impossible to + # determine the end of the modifier context + if in_function_block or in_property_block: + if scanner.match == '(': + brace_balance[0] += 1 + elif scanner.match == ')': + brace_balance[0] -= 1 + elif scanner.match == '[': + brace_balance[1] += 1 + elif scanner.match == ']': + brace_balance[1] -= 1 + elif scanner.scan(r'[A-Za-z_][A-Za-z_0-9]*'): + lowercase_name = scanner.match.lower() + if lowercase_name == 'result': + token = Name.Builtin.Pseudo + elif lowercase_name in self.keywords: + token = Keyword + # if we are in a special block and a + # block ending keyword occours (and the parenthesis + # is balanced) we end the current block context + if (in_function_block or in_property_block) and \ + lowercase_name in self.BLOCK_KEYWORDS and \ + brace_balance[0] <= 0 and \ + brace_balance[1] <= 0: + in_function_block = False + in_property_block = False + brace_balance = [0, 0] + block_labels = set() + if lowercase_name in ('label', 'goto'): + collect_labels = True + elif lowercase_name == 'asm': + stack.append('asm') + elif lowercase_name == 'property': + in_property_block = True + next_token_is_property = True + elif lowercase_name in ('procedure', 'operator', + 'function', 'constructor', + 'destructor'): + in_function_block = True + next_token_is_function = True + # we are in a function block and the current name + # is in the set of registered modifiers. highlight + # it as pseudo keyword + elif in_function_block and \ + lowercase_name in self.FUNCTION_MODIFIERS: + token = Keyword.Pseudo + # if we are in a property highlight some more + # modifiers + elif in_property_block and \ + lowercase_name in ('read', 'write'): + token = Keyword.Pseudo + next_token_is_function = True + # if the last iteration set next_token_is_function + # to true we now want this name highlighted as + # function. so do that and reset the state + elif next_token_is_function: + # Look if the next token is a dot. If yes it's + # not a function, but a class name and the + # part after the dot a function name + if scanner.test(r'\s*\.\s*'): + token = Name.Class + # it's not a dot, our job is done + else: + token = Name.Function + next_token_is_function = False + # same for properties + elif next_token_is_property: + token = Name.Property + next_token_is_property = False + # Highlight this token as label and add it + # to the list of known labels + elif collect_labels: + token = Name.Label + block_labels.add(scanner.match.lower()) + # name is in list of known labels + elif lowercase_name in block_labels: + token = Name.Label + elif lowercase_name in self.BUILTIN_TYPES: + token = Keyword.Type + elif lowercase_name in self.DIRECTIVES: + token = Keyword.Pseudo + # builtins are just builtins if the token + # before isn't a dot + elif not was_dot and lowercase_name in self.builtins: + token = Name.Builtin + else: + token = Name + elif scanner.scan(r"'"): + token = String + stack.append('string') + elif scanner.scan(r'\#(\d+|\$[0-9A-Fa-f]+)'): + token = String.Char + elif scanner.scan(r'\$[0-9A-Fa-f]+'): + token = Number.Hex + elif scanner.scan(r'\d+(?![eE]|\.[^.])'): + token = Number.Integer + elif scanner.scan(r'\d+(\.\d+([eE][+-]?\d+)?|[eE][+-]?\d+)'): + token = Number.Float + else: + # if the stack depth is deeper than once, pop + if len(stack) > 1: + stack.pop() + scanner.get_char() + + elif stack[-1] == 'string': + if scanner.scan(r"''"): + token = String.Escape + elif scanner.scan(r"'"): + token = String + stack.pop() + elif scanner.scan(r"[^']*"): + token = String + else: + scanner.get_char() + stack.pop() + + elif stack[-1] == 'asm': + if scanner.scan(r'\s+'): + token = Text + elif scanner.scan(r'end'): + token = Keyword + stack.pop() + elif scanner.scan(r'\{.*?\}|\(\*.*?\*\)'): + if scanner.match.startswith('$'): + token = Comment.Preproc + else: + token = Comment.Multiline + elif scanner.scan(r'//.*?$'): + token = Comment.Single + elif scanner.scan(r"'"): + token = String + stack.append('string') + elif scanner.scan(r'@@[A-Za-z_][A-Za-z_0-9]*'): + token = Name.Label + elif scanner.scan(r'[A-Za-z_][A-Za-z_0-9]*'): + lowercase_name = scanner.match.lower() + if lowercase_name in self.ASM_INSTRUCTIONS: + token = Keyword + elif lowercase_name in self.ASM_REGISTERS: + token = Name.Builtin + else: + token = Name + elif scanner.scan(r'[-+*\/=<>:;,.@\^]+'): + token = Operator + elif scanner.scan(r'[\(\)\[\]]+'): + token = Punctuation + elif scanner.scan(r'\$[0-9A-Fa-f]+'): + token = Number.Hex + elif scanner.scan(r'\d+(?![eE]|\.[^.])'): + token = Number.Integer + elif scanner.scan(r'\d+(\.\d+([eE][+-]?\d+)?|[eE][+-]?\d+)'): + token = Number.Float + else: + scanner.get_char() + stack.pop() + + # save the dot!!!11 + if scanner.match.strip(): + was_dot = scanner.match == '.' + yield scanner.start_pos, token, scanner.match or '' + + +class Modula2Lexer(RegexLexer): + """ + For `Modula-2 `_ source code. + + Additional options that determine which keywords are highlighted: + + `pim` + Select PIM Modula-2 dialect (default: True). + `iso` + Select ISO Modula-2 dialect (default: False). + `objm2` + Select Objective Modula-2 dialect (default: False). + `gm2ext` + Also highlight GNU extensions (default: False). + + .. versionadded:: 1.3 + """ + name = 'Modula-2' + aliases = ['modula2', 'm2'] + filenames = ['*.def', '*.mod'] + mimetypes = ['text/x-modula2'] + + flags = re.MULTILINE | re.DOTALL + + tokens = { + 'whitespace': [ + (r'\n+', Text), # blank lines + (r'\s+', Text), # whitespace + ], + 'identifiers': [ + (r'([a-zA-Z_$][\w$]*)', Name), + ], + 'numliterals': [ + (r'[01]+B', Number.Bin), # binary number (ObjM2) + (r'[0-7]+B', Number.Oct), # octal number (PIM + ISO) + (r'[0-7]+C', Number.Oct), # char code (PIM + ISO) + (r'[0-9A-F]+C', Number.Hex), # char code (ObjM2) + (r'[0-9A-F]+H', Number.Hex), # hexadecimal number + (r'[0-9]+\.[0-9]+E[+-][0-9]+', Number.Float), # real number + (r'[0-9]+\.[0-9]+', Number.Float), # real number + (r'[0-9]+', Number.Integer), # decimal whole number + ], + 'strings': [ + (r"'(\\\\|\\'|[^'])*'", String), # single quoted string + (r'"(\\\\|\\"|[^"])*"', String), # double quoted string + ], + 'operators': [ + (r'[*/+=#~&<>\^-]', Operator), + (r':=', Operator), # assignment + (r'@', Operator), # pointer deref (ISO) + (r'\.\.', Operator), # ellipsis or range + (r'`', Operator), # Smalltalk message (ObjM2) + (r'::', Operator), # type conversion (ObjM2) + ], + 'punctuation': [ + (r'[()\[\]{},.:;|]', Punctuation), + ], + 'comments': [ + (r'//.*?\n', Comment.Single), # ObjM2 + (r'/\*(.*?)\*/', Comment.Multiline), # ObjM2 + (r'\(\*([^$].*?)\*\)', Comment.Multiline), + # TO DO: nesting of (* ... *) comments + ], + 'pragmas': [ + (r'\(\*\$(.*?)\*\)', Comment.Preproc), # PIM + (r'<\*(.*?)\*>', Comment.Preproc), # ISO + ObjM2 + ], + 'root': [ + include('whitespace'), + include('comments'), + include('pragmas'), + include('identifiers'), + include('numliterals'), + include('strings'), + include('operators'), + include('punctuation'), + ] + } + + pim_reserved_words = [ + # 40 reserved words + 'AND', 'ARRAY', 'BEGIN', 'BY', 'CASE', 'CONST', 'DEFINITION', + 'DIV', 'DO', 'ELSE', 'ELSIF', 'END', 'EXIT', 'EXPORT', 'FOR', + 'FROM', 'IF', 'IMPLEMENTATION', 'IMPORT', 'IN', 'LOOP', 'MOD', + 'MODULE', 'NOT', 'OF', 'OR', 'POINTER', 'PROCEDURE', 'QUALIFIED', + 'RECORD', 'REPEAT', 'RETURN', 'SET', 'THEN', 'TO', 'TYPE', + 'UNTIL', 'VAR', 'WHILE', 'WITH', + ] + + pim_pervasives = [ + # 31 pervasives + 'ABS', 'BITSET', 'BOOLEAN', 'CAP', 'CARDINAL', 'CHAR', 'CHR', 'DEC', + 'DISPOSE', 'EXCL', 'FALSE', 'FLOAT', 'HALT', 'HIGH', 'INC', 'INCL', + 'INTEGER', 'LONGINT', 'LONGREAL', 'MAX', 'MIN', 'NEW', 'NIL', 'ODD', + 'ORD', 'PROC', 'REAL', 'SIZE', 'TRUE', 'TRUNC', 'VAL', + ] + + iso_reserved_words = [ + # 46 reserved words + 'AND', 'ARRAY', 'BEGIN', 'BY', 'CASE', 'CONST', 'DEFINITION', 'DIV', + 'DO', 'ELSE', 'ELSIF', 'END', 'EXCEPT', 'EXIT', 'EXPORT', 'FINALLY', + 'FOR', 'FORWARD', 'FROM', 'IF', 'IMPLEMENTATION', 'IMPORT', 'IN', + 'LOOP', 'MOD', 'MODULE', 'NOT', 'OF', 'OR', 'PACKEDSET', 'POINTER', + 'PROCEDURE', 'QUALIFIED', 'RECORD', 'REPEAT', 'REM', 'RETRY', + 'RETURN', 'SET', 'THEN', 'TO', 'TYPE', 'UNTIL', 'VAR', 'WHILE', + 'WITH', + ] + + iso_pervasives = [ + # 42 pervasives + 'ABS', 'BITSET', 'BOOLEAN', 'CAP', 'CARDINAL', 'CHAR', 'CHR', 'CMPLX', + 'COMPLEX', 'DEC', 'DISPOSE', 'EXCL', 'FALSE', 'FLOAT', 'HALT', 'HIGH', + 'IM', 'INC', 'INCL', 'INT', 'INTEGER', 'INTERRUPTIBLE', 'LENGTH', + 'LFLOAT', 'LONGCOMPLEX', 'LONGINT', 'LONGREAL', 'MAX', 'MIN', 'NEW', + 'NIL', 'ODD', 'ORD', 'PROC', 'PROTECTION', 'RE', 'REAL', 'SIZE', + 'TRUE', 'TRUNC', 'UNINTERRUBTIBLE', 'VAL', + ] + + objm2_reserved_words = [ + # base language, 42 reserved words + 'AND', 'ARRAY', 'BEGIN', 'BY', 'CASE', 'CONST', 'DEFINITION', 'DIV', + 'DO', 'ELSE', 'ELSIF', 'END', 'ENUM', 'EXIT', 'FOR', 'FROM', 'IF', + 'IMMUTABLE', 'IMPLEMENTATION', 'IMPORT', 'IN', 'IS', 'LOOP', 'MOD', + 'MODULE', 'NOT', 'OF', 'OPAQUE', 'OR', 'POINTER', 'PROCEDURE', + 'RECORD', 'REPEAT', 'RETURN', 'SET', 'THEN', 'TO', 'TYPE', + 'UNTIL', 'VAR', 'VARIADIC', 'WHILE', + # OO extensions, 16 reserved words + 'BYCOPY', 'BYREF', 'CLASS', 'CONTINUE', 'CRITICAL', 'INOUT', 'METHOD', + 'ON', 'OPTIONAL', 'OUT', 'PRIVATE', 'PROTECTED', 'PROTOCOL', 'PUBLIC', + 'SUPER', 'TRY', + ] + + objm2_pervasives = [ + # base language, 38 pervasives + 'ABS', 'BITSET', 'BOOLEAN', 'CARDINAL', 'CHAR', 'CHR', 'DISPOSE', + 'FALSE', 'HALT', 'HIGH', 'INTEGER', 'INRANGE', 'LENGTH', 'LONGCARD', + 'LONGINT', 'LONGREAL', 'MAX', 'MIN', 'NEG', 'NEW', 'NEXTV', 'NIL', + 'OCTET', 'ODD', 'ORD', 'PRED', 'PROC', 'READ', 'REAL', 'SUCC', 'TMAX', + 'TMIN', 'TRUE', 'TSIZE', 'UNICHAR', 'VAL', 'WRITE', 'WRITEF', + # OO extensions, 3 pervasives + 'OBJECT', 'NO', 'YES', + ] + + gnu_reserved_words = [ + # 10 additional reserved words + 'ASM', '__ATTRIBUTE__', '__BUILTIN__', '__COLUMN__', '__DATE__', + '__FILE__', '__FUNCTION__', '__LINE__', '__MODULE__', 'VOLATILE', + ] + + gnu_pervasives = [ + # 21 identifiers, actually from pseudo-module SYSTEM + # but we will highlight them as if they were pervasives + 'BITSET8', 'BITSET16', 'BITSET32', 'CARDINAL8', 'CARDINAL16', + 'CARDINAL32', 'CARDINAL64', 'COMPLEX32', 'COMPLEX64', 'COMPLEX96', + 'COMPLEX128', 'INTEGER8', 'INTEGER16', 'INTEGER32', 'INTEGER64', + 'REAL8', 'REAL16', 'REAL32', 'REAL96', 'REAL128', 'THROW', + ] + + def __init__(self, **options): + self.reserved_words = set() + self.pervasives = set() + # ISO Modula-2 + if get_bool_opt(options, 'iso', False): + self.reserved_words.update(self.iso_reserved_words) + self.pervasives.update(self.iso_pervasives) + # Objective Modula-2 + elif get_bool_opt(options, 'objm2', False): + self.reserved_words.update(self.objm2_reserved_words) + self.pervasives.update(self.objm2_pervasives) + # PIM Modula-2 (DEFAULT) + else: + self.reserved_words.update(self.pim_reserved_words) + self.pervasives.update(self.pim_pervasives) + # GNU extensions + if get_bool_opt(options, 'gm2ext', False): + self.reserved_words.update(self.gnu_reserved_words) + self.pervasives.update(self.gnu_pervasives) + # initialise + RegexLexer.__init__(self, **options) + + def get_tokens_unprocessed(self, text): + for index, token, value in RegexLexer.get_tokens_unprocessed(self, text): + # check for reserved words and pervasives + if token is Name: + if value in self.reserved_words: + token = Keyword.Reserved + elif value in self.pervasives: + token = Keyword.Pervasive + # return result + yield index, token, value + + +class AdaLexer(RegexLexer): + """ + For Ada source code. + + .. versionadded:: 1.3 + """ + + name = 'Ada' + aliases = ['ada', 'ada95', 'ada2005'] + filenames = ['*.adb', '*.ads', '*.ada'] + mimetypes = ['text/x-ada'] + + flags = re.MULTILINE | re.IGNORECASE + + tokens = { + 'root': [ + (r'[^\S\n]+', Text), + (r'--.*?\n', Comment.Single), + (r'[^\S\n]+', Text), + (r'function|procedure|entry', Keyword.Declaration, 'subprogram'), + (r'(subtype|type)(\s+)(\w+)', + bygroups(Keyword.Declaration, Text, Keyword.Type), 'type_def'), + (r'task|protected', Keyword.Declaration), + (r'(subtype)(\s+)', bygroups(Keyword.Declaration, Text)), + (r'(end)(\s+)', bygroups(Keyword.Reserved, Text), 'end'), + (r'(pragma)(\s+)(\w+)', bygroups(Keyword.Reserved, Text, + Comment.Preproc)), + (r'(true|false|null)\b', Keyword.Constant), + (words(( + 'Address', 'Byte', 'Boolean', 'Character', 'Controlled', 'Count', 'Cursor', + 'Duration', 'File_Mode', 'File_Type', 'Float', 'Generator', 'Integer', 'Long_Float', + 'Long_Integer', 'Long_Long_Float', 'Long_Long_Integer', 'Natural', 'Positive', + 'Reference_Type', 'Short_Float', 'Short_Integer', 'Short_Short_Float', + 'Short_Short_Integer', 'String', 'Wide_Character', 'Wide_String'), suffix=r'\b'), + Keyword.Type), + (r'(and(\s+then)?|in|mod|not|or(\s+else)|rem)\b', Operator.Word), + (r'generic|private', Keyword.Declaration), + (r'package', Keyword.Declaration, 'package'), + (r'array\b', Keyword.Reserved, 'array_def'), + (r'(with|use)(\s+)', bygroups(Keyword.Namespace, Text), 'import'), + (r'(\w+)(\s*)(:)(\s*)(constant)', + bygroups(Name.Constant, Text, Punctuation, Text, + Keyword.Reserved)), + (r'<<\w+>>', Name.Label), + (r'(\w+)(\s*)(:)(\s*)(declare|begin|loop|for|while)', + bygroups(Name.Label, Text, Punctuation, Text, Keyword.Reserved)), + (words(( + 'abort', 'abs', 'abstract', 'accept', 'access', 'aliased', 'all', + 'array', 'at', 'begin', 'body', 'case', 'constant', 'declare', + 'delay', 'delta', 'digits', 'do', 'else', 'elsif', 'end', 'entry', + 'exception', 'exit', 'interface', 'for', 'goto', 'if', 'is', 'limited', + 'loop', 'new', 'null', 'of', 'or', 'others', 'out', 'overriding', + 'pragma', 'protected', 'raise', 'range', 'record', 'renames', 'requeue', + 'return', 'reverse', 'select', 'separate', 'subtype', 'synchronized', + 'task', 'tagged', 'terminate', 'then', 'type', 'until', 'when', + 'while', 'xor'), prefix=r'\b', suffix=r'\b'), + Keyword.Reserved), + (r'"[^"]*"', String), + include('attribute'), + include('numbers'), + (r"'[^']'", String.Character), + (r'(\w+)(\s*|[(,])', bygroups(Name, using(this))), + (r"(<>|=>|:=|[()|:;,.'])", Punctuation), + (r'[*<>+=/&-]', Operator), + (r'\n+', Text), + ], + 'numbers': [ + (r'[0-9_]+#[0-9a-f]+#', Number.Hex), + (r'[0-9_]+\.[0-9_]*', Number.Float), + (r'[0-9_]+', Number.Integer), + ], + 'attribute': [ + (r"(')(\w+)", bygroups(Punctuation, Name.Attribute)), + ], + 'subprogram': [ + (r'\(', Punctuation, ('#pop', 'formal_part')), + (r';', Punctuation, '#pop'), + (r'is\b', Keyword.Reserved, '#pop'), + (r'"[^"]+"|\w+', Name.Function), + include('root'), + ], + 'end': [ + ('(if|case|record|loop|select)', Keyword.Reserved), + ('"[^"]+"|[\w.]+', Name.Function), + ('\s+', Text), + (';', Punctuation, '#pop'), + ], + 'type_def': [ + (r';', Punctuation, '#pop'), + (r'\(', Punctuation, 'formal_part'), + (r'with|and|use', Keyword.Reserved), + (r'array\b', Keyword.Reserved, ('#pop', 'array_def')), + (r'record\b', Keyword.Reserved, ('record_def')), + (r'(null record)(;)', bygroups(Keyword.Reserved, Punctuation), '#pop'), + include('root'), + ], + 'array_def': [ + (r';', Punctuation, '#pop'), + (r'(\w+)(\s+)(range)', bygroups(Keyword.Type, Text, Keyword.Reserved)), + include('root'), + ], + 'record_def': [ + (r'end record', Keyword.Reserved, '#pop'), + include('root'), + ], + 'import': [ + (r'[\w.]+', Name.Namespace, '#pop'), + default('#pop'), + ], + 'formal_part': [ + (r'\)', Punctuation, '#pop'), + (r'\w+', Name.Variable), + (r',|:[^=]', Punctuation), + (r'(in|not|null|out|access)\b', Keyword.Reserved), + include('root'), + ], + 'package': [ + ('body', Keyword.Declaration), + ('is\s+new|renames', Keyword.Reserved), + ('is', Keyword.Reserved, '#pop'), + (';', Punctuation, '#pop'), + ('\(', Punctuation, 'package_instantiation'), + ('([\w.]+)', Name.Class), + include('root'), + ], + 'package_instantiation': [ + (r'("[^"]+"|\w+)(\s+)(=>)', bygroups(Name.Variable, Text, Punctuation)), + (r'[\w.\'"]', Text), + (r'\)', Punctuation, '#pop'), + include('root'), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pawn.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pawn.py new file mode 100644 index 0000000000..d55e2cc6bb --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/pawn.py @@ -0,0 +1,199 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.pawn + ~~~~~~~~~~~~~~~~~~~~ + + Lexers for the Pawn languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error +from pygments.util import get_bool_opt + +__all__ = ['SourcePawnLexer', 'PawnLexer'] + + +class SourcePawnLexer(RegexLexer): + """ + For SourcePawn source code with preprocessor directives. + + .. versionadded:: 1.6 + """ + name = 'SourcePawn' + aliases = ['sp'] + filenames = ['*.sp'] + mimetypes = ['text/x-sourcepawn'] + + #: optional Comment or Whitespace + _ws = r'(?:\s|//.*?\n|/\*.*?\*/)+' + #: only one /* */ style comment + _ws1 = r'\s*(?:/[*].*?[*]/\s*)*' + + tokens = { + 'root': [ + # preprocessor directives: without whitespace + ('^#if\s+0', Comment.Preproc, 'if0'), + ('^#', Comment.Preproc, 'macro'), + # or with whitespace + ('^' + _ws1 + r'#if\s+0', Comment.Preproc, 'if0'), + ('^' + _ws1 + '#', Comment.Preproc, 'macro'), + (r'\n', Text), + (r'\s+', Text), + (r'\\\n', Text), # line continuation + (r'/(\\\n)?/(\n|(.|\n)*?[^\\]\n)', Comment.Single), + (r'/(\\\n)?\*(.|\n)*?\*(\\\n)?/', Comment.Multiline), + (r'[{}]', Punctuation), + (r'L?"', String, 'string'), + (r"L?'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'", String.Char), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[LlUu]*', Number.Float), + (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'0x[0-9a-fA-F]+[LlUu]*', Number.Hex), + (r'0[0-7]+[LlUu]*', Number.Oct), + (r'\d+[LlUu]*', Number.Integer), + (r'\*/', Error), + (r'[~!%^&*+=|?:<>/-]', Operator), + (r'[()\[\],.;]', Punctuation), + (r'(case|const|continue|native|' + r'default|else|enum|for|if|new|operator|' + r'public|return|sizeof|static|decl|struct|switch)\b', Keyword), + (r'(bool|Float)\b', Keyword.Type), + (r'(true|false)\b', Keyword.Constant), + ('[a-zA-Z_]\w*', Name), + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # stray backslash + ], + 'macro': [ + (r'[^/\n]+', Comment.Preproc), + (r'/\*(.|\n)*?\*/', Comment.Multiline), + (r'//.*?\n', Comment.Single, '#pop'), + (r'/', Comment.Preproc), + (r'(?<=\\)\n', Comment.Preproc), + (r'\n', Comment.Preproc, '#pop'), + ], + 'if0': [ + (r'^\s*#if.*?(?/-]', Operator), + (r'[()\[\],.;]', Punctuation), + (r'(switch|case|default|const|new|static|char|continue|break|' + r'if|else|for|while|do|operator|enum|' + r'public|return|sizeof|tagof|state|goto)\b', Keyword), + (r'(bool|Float)\b', Keyword.Type), + (r'(true|false)\b', Keyword.Constant), + ('[a-zA-Z_]\w*', Name), + ], + 'string': [ + (r'"', String, '#pop'), + (r'\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})', String.Escape), + (r'[^\\"\n]+', String), # all other characters + (r'\\\n', String), # line continuation + (r'\\', String), # stray backslash + ], + 'macro': [ + (r'[^/\n]+', Comment.Preproc), + (r'/\*(.|\n)*?\*/', Comment.Multiline), + (r'//.*?\n', Comment.Single, '#pop'), + (r'/', Comment.Preproc), + (r'(?<=\\)\n', Comment.Preproc), + (r'\n', Comment.Preproc, '#pop'), + ], + 'if0': [ + (r'^\s*#if.*?(?`_ source code. + """ + + name = 'Perl' + aliases = ['perl', 'pl'] + filenames = ['*.pl', '*.pm', '*.t'] + mimetypes = ['text/x-perl', 'application/x-perl'] + + flags = re.DOTALL | re.MULTILINE + # TODO: give this to a perl guy who knows how to parse perl... + tokens = { + 'balanced-regex': [ + (r'/(\\\\|\\[^\\]|[^\\/])*/[egimosx]*', String.Regex, '#pop'), + (r'!(\\\\|\\[^\\]|[^\\!])*![egimosx]*', String.Regex, '#pop'), + (r'\\(\\\\|[^\\])*\\[egimosx]*', String.Regex, '#pop'), + (r'\{(\\\\|\\[^\\]|[^\\}])*\}[egimosx]*', String.Regex, '#pop'), + (r'<(\\\\|\\[^\\]|[^\\>])*>[egimosx]*', String.Regex, '#pop'), + (r'\[(\\\\|\\[^\\]|[^\\\]])*\][egimosx]*', String.Regex, '#pop'), + (r'\((\\\\|\\[^\\]|[^\\)])*\)[egimosx]*', String.Regex, '#pop'), + (r'@(\\\\|\\[^\\]|[^\\@])*@[egimosx]*', String.Regex, '#pop'), + (r'%(\\\\|\\[^\\]|[^\\%])*%[egimosx]*', String.Regex, '#pop'), + (r'\$(\\\\|\\[^\\]|[^\\$])*\$[egimosx]*', String.Regex, '#pop'), + ], + 'root': [ + (r'\#.*?$', Comment.Single), + (r'^=[a-zA-Z0-9]+\s+.*?\n=cut', Comment.Multiline), + (words(( + 'case', 'continue', 'do', 'else', 'elsif', 'for', 'foreach', + 'if', 'last', 'my', 'next', 'our', 'redo', 'reset', 'then', + 'unless', 'until', 'while', 'use', 'print', 'new', 'BEGIN', + 'CHECK', 'INIT', 'END', 'return'), suffix=r'\b'), + Keyword), + (r'(format)(\s+)(\w+)(\s*)(=)(\s*\n)', + bygroups(Keyword, Text, Name, Text, Punctuation, Text), 'format'), + (r'(eq|lt|gt|le|ge|ne|not|and|or|cmp)\b', Operator.Word), + # common delimiters + (r's/(\\\\|\\[^\\]|[^\\/])*/(\\\\|\\[^\\]|[^\\/])*/[egimosx]*', + String.Regex), + (r's!(\\\\|\\!|[^!])*!(\\\\|\\!|[^!])*![egimosx]*', String.Regex), + (r's\\(\\\\|[^\\])*\\(\\\\|[^\\])*\\[egimosx]*', String.Regex), + (r's@(\\\\|\\[^\\]|[^\\@])*@(\\\\|\\[^\\]|[^\\@])*@[egimosx]*', + String.Regex), + (r's%(\\\\|\\[^\\]|[^\\%])*%(\\\\|\\[^\\]|[^\\%])*%[egimosx]*', + String.Regex), + # balanced delimiters + (r's\{(\\\\|\\[^\\]|[^\\}])*\}\s*', String.Regex, 'balanced-regex'), + (r's<(\\\\|\\[^\\]|[^\\>])*>\s*', String.Regex, 'balanced-regex'), + (r's\[(\\\\|\\[^\\]|[^\\\]])*\]\s*', String.Regex, + 'balanced-regex'), + (r's\((\\\\|\\[^\\]|[^\\)])*\)\s*', String.Regex, + 'balanced-regex'), + + (r'm?/(\\\\|\\[^\\]|[^\\/\n])*/[gcimosx]*', String.Regex), + (r'm(?=[/!\\{<\[(@%$])', String.Regex, 'balanced-regex'), + (r'((?<==~)|(?<=\())\s*/(\\\\|\\[^\\]|[^\\/])*/[gcimosx]*', + String.Regex), + (r'\s+', Text), + (words(( + 'abs', 'accept', 'alarm', 'atan2', 'bind', 'binmode', 'bless', 'caller', 'chdir', + 'chmod', 'chomp', 'chop', 'chown', 'chr', 'chroot', 'close', 'closedir', 'connect', + 'continue', 'cos', 'crypt', 'dbmclose', 'dbmopen', 'defined', 'delete', 'die', + 'dump', 'each', 'endgrent', 'endhostent', 'endnetent', 'endprotoent', + 'endpwent', 'endservent', 'eof', 'eval', 'exec', 'exists', 'exit', 'exp', 'fcntl', + 'fileno', 'flock', 'fork', 'format', 'formline', 'getc', 'getgrent', 'getgrgid', + 'getgrnam', 'gethostbyaddr', 'gethostbyname', 'gethostent', 'getlogin', + 'getnetbyaddr', 'getnetbyname', 'getnetent', 'getpeername', 'getpgrp', + 'getppid', 'getpriority', 'getprotobyname', 'getprotobynumber', + 'getprotoent', 'getpwent', 'getpwnam', 'getpwuid', 'getservbyname', + 'getservbyport', 'getservent', 'getsockname', 'getsockopt', 'glob', 'gmtime', + 'goto', 'grep', 'hex', 'import', 'index', 'int', 'ioctl', 'join', 'keys', 'kill', 'last', + 'lc', 'lcfirst', 'length', 'link', 'listen', 'local', 'localtime', 'log', 'lstat', + 'map', 'mkdir', 'msgctl', 'msgget', 'msgrcv', 'msgsnd', 'my', 'next', 'no', 'oct', 'open', + 'opendir', 'ord', 'our', 'pack', 'package', 'pipe', 'pop', 'pos', 'printf', + 'prototype', 'push', 'quotemeta', 'rand', 'read', 'readdir', + 'readline', 'readlink', 'readpipe', 'recv', 'redo', 'ref', 'rename', 'require', + 'reverse', 'rewinddir', 'rindex', 'rmdir', 'scalar', 'seek', 'seekdir', + 'select', 'semctl', 'semget', 'semop', 'send', 'setgrent', 'sethostent', 'setnetent', + 'setpgrp', 'setpriority', 'setprotoent', 'setpwent', 'setservent', + 'setsockopt', 'shift', 'shmctl', 'shmget', 'shmread', 'shmwrite', 'shutdown', + 'sin', 'sleep', 'socket', 'socketpair', 'sort', 'splice', 'split', 'sprintf', 'sqrt', + 'srand', 'stat', 'study', 'substr', 'symlink', 'syscall', 'sysopen', 'sysread', + 'sysseek', 'system', 'syswrite', 'tell', 'telldir', 'tie', 'tied', 'time', 'times', 'tr', + 'truncate', 'uc', 'ucfirst', 'umask', 'undef', 'unlink', 'unpack', 'unshift', 'untie', + 'utime', 'values', 'vec', 'wait', 'waitpid', 'wantarray', 'warn', 'write'), suffix=r'\b'), + Name.Builtin), + (r'((__(DATA|DIE|WARN)__)|(STD(IN|OUT|ERR)))\b', Name.Builtin.Pseudo), + (r'<<([\'"]?)([a-zA-Z_]\w*)\1;?\n.*?\n\2\n', String), + (r'__END__', Comment.Preproc, 'end-part'), + (r'\$\^[ADEFHILMOPSTWX]', Name.Variable.Global), + (r"\$[\\\"\[\]'&`+*.,;=%~?@$!<>(^|/-](?!\w)", Name.Variable.Global), + (r'[$@%#]+', Name.Variable, 'varname'), + (r'0_?[0-7]+(_[0-7]+)*', Number.Oct), + (r'0x[0-9A-Fa-f]+(_[0-9A-Fa-f]+)*', Number.Hex), + (r'0b[01]+(_[01]+)*', Number.Bin), + (r'(?i)(\d*(_\d*)*\.\d+(_\d*)*|\d+(_\d*)*\.\d+(_\d*)*)(e[+-]?\d+)?', + Number.Float), + (r'(?i)\d+(_\d*)*e[+-]?\d+(_\d*)*', Number.Float), + (r'\d+(_\d+)*', Number.Integer), + (r"'(\\\\|\\[^\\]|[^'\\])*'", String), + (r'"(\\\\|\\[^\\]|[^"\\])*"', String), + (r'`(\\\\|\\[^\\]|[^`\\])*`', String.Backtick), + (r'<([^\s>]+)>', String.Regex), + (r'(q|qq|qw|qr|qx)\{', String.Other, 'cb-string'), + (r'(q|qq|qw|qr|qx)\(', String.Other, 'rb-string'), + (r'(q|qq|qw|qr|qx)\[', String.Other, 'sb-string'), + (r'(q|qq|qw|qr|qx)\<', String.Other, 'lt-string'), + (r'(q|qq|qw|qr|qx)([\W_])(.|\n)*?\2', String.Other), + (r'package\s+', Keyword, 'modulename'), + (r'sub\s+', Keyword, 'funcname'), + (r'(\[\]|\*\*|::|<<|>>|>=|<=>|<=|={3}|!=|=~|' + r'!~|&&?|\|\||\.{1,3})', Operator), + (r'[-+/*%=<>&^|!\\~]=?', Operator), + (r'[()\[\]:;,<>/?{}]', Punctuation), # yes, there's no shortage + # of punctuation in Perl! + (r'(?=\w)', Name, 'name'), + ], + 'format': [ + (r'\.\n', String.Interpol, '#pop'), + (r'[^\n]*\n', String.Interpol), + ], + 'varname': [ + (r'\s+', Text), + (r'\{', Punctuation, '#pop'), # hash syntax? + (r'\)|,', Punctuation, '#pop'), # argument specifier + (r'\w+::', Name.Namespace), + (r'[\w:]+', Name.Variable, '#pop'), + ], + 'name': [ + (r'\w+::', Name.Namespace), + (r'[\w:]+', Name, '#pop'), + (r'[A-Z_]+(?=\W)', Name.Constant, '#pop'), + (r'(?=\W)', Text, '#pop'), + ], + 'modulename': [ + (r'[a-zA-Z_]\w*', Name.Namespace, '#pop') + ], + 'funcname': [ + (r'[a-zA-Z_]\w*[!?]?', Name.Function), + (r'\s+', Text), + # argument declaration + (r'(\([$@%]*\))(\s*)', bygroups(Punctuation, Text)), + (r';', Punctuation, '#pop'), + (r'.*?\{', Punctuation, '#pop'), + ], + 'cb-string': [ + (r'\\[{}\\]', String.Other), + (r'\\', String.Other), + (r'\{', String.Other, 'cb-string'), + (r'\}', String.Other, '#pop'), + (r'[^{}\\]+', String.Other) + ], + 'rb-string': [ + (r'\\[()\\]', String.Other), + (r'\\', String.Other), + (r'\(', String.Other, 'rb-string'), + (r'\)', String.Other, '#pop'), + (r'[^()]+', String.Other) + ], + 'sb-string': [ + (r'\\[\[\]\\]', String.Other), + (r'\\', String.Other), + (r'\[', String.Other, 'sb-string'), + (r'\]', String.Other, '#pop'), + (r'[^\[\]]+', String.Other) + ], + 'lt-string': [ + (r'\\[<>\\]', String.Other), + (r'\\', String.Other), + (r'\<', String.Other, 'lt-string'), + (r'\>', String.Other, '#pop'), + (r'[^<>]+', String.Other) + ], + 'end-part': [ + (r'.+', Comment.Preproc, '#pop') + ] + } + + def analyse_text(text): + if shebang_matches(text, r'perl'): + return True + if re.search('(?:my|our)\s+[$@%(]', text): + return 0.9 + + +class Perl6Lexer(ExtendedRegexLexer): + """ + For `Perl 6 `_ source code. + + .. versionadded:: 2.0 + """ + + name = 'Perl6' + aliases = ['perl6', 'pl6'] + filenames = ['*.pl', '*.pm', '*.nqp', '*.p6', '*.6pl', '*.p6l', '*.pl6', + '*.6pm', '*.p6m', '*.pm6', '*.t'] + mimetypes = ['text/x-perl6', 'application/x-perl6'] + flags = re.MULTILINE | re.DOTALL | re.UNICODE + + PERL6_IDENTIFIER_RANGE = "['\w:-]" + + PERL6_KEYWORDS = ( + 'BEGIN', 'CATCH', 'CHECK', 'CONTROL', 'END', 'ENTER', 'FIRST', 'INIT', + 'KEEP', 'LAST', 'LEAVE', 'NEXT', 'POST', 'PRE', 'START', 'TEMP', + 'UNDO', 'as', 'assoc', 'async', 'augment', 'binary', 'break', 'but', + 'cached', 'category', 'class', 'constant', 'contend', 'continue', + 'copy', 'deep', 'default', 'defequiv', 'defer', 'die', 'do', 'else', + 'elsif', 'enum', 'equiv', 'exit', 'export', 'fail', 'fatal', 'for', + 'gather', 'given', 'goto', 'grammar', 'handles', 'has', 'if', 'inline', + 'irs', 'is', 'last', 'leave', 'let', 'lift', 'loop', 'looser', 'macro', + 'make', 'maybe', 'method', 'module', 'multi', 'my', 'next', 'of', + 'ofs', 'only', 'oo', 'ors', 'our', 'package', 'parsed', 'prec', + 'proto', 'readonly', 'redo', 'ref', 'regex', 'reparsed', 'repeat', + 'require', 'required', 'return', 'returns', 'role', 'rule', 'rw', + 'self', 'slang', 'state', 'sub', 'submethod', 'subset', 'supersede', + 'take', 'temp', 'tighter', 'token', 'trusts', 'try', 'unary', + 'unless', 'until', 'use', 'warn', 'when', 'where', 'while', 'will', + ) + + PERL6_BUILTINS = ( + 'ACCEPTS', 'HOW', 'REJECTS', 'VAR', 'WHAT', 'WHENCE', 'WHERE', 'WHICH', + 'WHO', 'abs', 'acos', 'acosec', 'acosech', 'acosh', 'acotan', 'acotanh', + 'all', 'any', 'approx', 'arity', 'asec', 'asech', 'asin', 'asinh', + 'assuming', 'atan', 'atan2', 'atanh', 'attr', 'bless', 'body', 'by', + 'bytes', 'caller', 'callsame', 'callwith', 'can', 'capitalize', 'cat', + 'ceiling', 'chars', 'chmod', 'chomp', 'chop', 'chr', 'chroot', + 'circumfix', 'cis', 'classify', 'clone', 'close', 'cmp_ok', 'codes', + 'comb', 'connect', 'contains', 'context', 'cos', 'cosec', 'cosech', + 'cosh', 'cotan', 'cotanh', 'count', 'defined', 'delete', 'diag', + 'dies_ok', 'does', 'e', 'each', 'eager', 'elems', 'end', 'eof', 'eval', + 'eval_dies_ok', 'eval_elsewhere', 'eval_lives_ok', 'evalfile', 'exists', + 'exp', 'first', 'flip', 'floor', 'flunk', 'flush', 'fmt', 'force_todo', + 'fork', 'from', 'getc', 'gethost', 'getlogin', 'getpeername', 'getpw', + 'gmtime', 'graphs', 'grep', 'hints', 'hyper', 'im', 'index', 'infix', + 'invert', 'is_approx', 'is_deeply', 'isa', 'isa_ok', 'isnt', 'iterator', + 'join', 'key', 'keys', 'kill', 'kv', 'lastcall', 'lazy', 'lc', 'lcfirst', + 'like', 'lines', 'link', 'lives_ok', 'localtime', 'log', 'log10', 'map', + 'max', 'min', 'minmax', 'name', 'new', 'nextsame', 'nextwith', 'nfc', + 'nfd', 'nfkc', 'nfkd', 'nok_error', 'nonce', 'none', 'normalize', 'not', + 'nothing', 'ok', 'once', 'one', 'open', 'opendir', 'operator', 'ord', + 'p5chomp', 'p5chop', 'pack', 'pair', 'pairs', 'pass', 'perl', 'pi', + 'pick', 'plan', 'plan_ok', 'polar', 'pop', 'pos', 'postcircumfix', + 'postfix', 'pred', 'prefix', 'print', 'printf', 'push', 'quasi', + 'quotemeta', 'rand', 're', 'read', 'readdir', 'readline', 'reduce', + 'reverse', 'rewind', 'rewinddir', 'rindex', 'roots', 'round', + 'roundrobin', 'run', 'runinstead', 'sameaccent', 'samecase', 'say', + 'sec', 'sech', 'sech', 'seek', 'shape', 'shift', 'sign', 'signature', + 'sin', 'sinh', 'skip', 'skip_rest', 'sleep', 'slurp', 'sort', 'splice', + 'split', 'sprintf', 'sqrt', 'srand', 'strand', 'subst', 'substr', 'succ', + 'sum', 'symlink', 'tan', 'tanh', 'throws_ok', 'time', 'times', 'to', + 'todo', 'trim', 'trim_end', 'trim_start', 'true', 'truncate', 'uc', + 'ucfirst', 'undef', 'undefine', 'uniq', 'unlike', 'unlink', 'unpack', + 'unpolar', 'unshift', 'unwrap', 'use_ok', 'value', 'values', 'vec', + 'version_lt', 'void', 'wait', 'want', 'wrap', 'write', 'zip', + ) + + PERL6_BUILTIN_CLASSES = ( + 'Abstraction', 'Any', 'AnyChar', 'Array', 'Associative', 'Bag', 'Bit', + 'Blob', 'Block', 'Bool', 'Buf', 'Byte', 'Callable', 'Capture', 'Char', 'Class', + 'Code', 'Codepoint', 'Comparator', 'Complex', 'Decreasing', 'Exception', + 'Failure', 'False', 'Grammar', 'Grapheme', 'Hash', 'IO', 'Increasing', + 'Int', 'Junction', 'KeyBag', 'KeyExtractor', 'KeyHash', 'KeySet', + 'KitchenSink', 'List', 'Macro', 'Mapping', 'Match', 'Matcher', 'Method', + 'Module', 'Num', 'Object', 'Ordered', 'Ordering', 'OrderingPair', + 'Package', 'Pair', 'Positional', 'Proxy', 'Range', 'Rat', 'Regex', + 'Role', 'Routine', 'Scalar', 'Seq', 'Set', 'Signature', 'Str', 'StrLen', + 'StrPos', 'Sub', 'Submethod', 'True', 'UInt', 'Undef', 'Version', 'Void', + 'Whatever', 'bit', 'bool', 'buf', 'buf1', 'buf16', 'buf2', 'buf32', + 'buf4', 'buf64', 'buf8', 'complex', 'int', 'int1', 'int16', 'int2', + 'int32', 'int4', 'int64', 'int8', 'num', 'rat', 'rat1', 'rat16', 'rat2', + 'rat32', 'rat4', 'rat64', 'rat8', 'uint', 'uint1', 'uint16', 'uint2', + 'uint32', 'uint4', 'uint64', 'uint8', 'utf16', 'utf32', 'utf8', + ) + + PERL6_OPERATORS = ( + 'X', 'Z', 'after', 'also', 'and', 'andthen', 'before', 'cmp', 'div', + 'eq', 'eqv', 'extra', 'ff', 'fff', 'ge', 'gt', 'le', 'leg', 'lt', 'm', + 'mm', 'mod', 'ne', 'or', 'orelse', 'rx', 's', 'tr', 'x', 'xor', 'xx', + '++', '--', '**', '!', '+', '-', '~', '?', '|', '||', '+^', '~^', '?^', + '^', '*', '/', '%', '%%', '+&', '+<', '+>', '~&', '~<', '~>', '?&', + 'gcd', 'lcm', '+', '-', '+|', '+^', '~|', '~^', '?|', '?^', + '~', '&', '^', 'but', 'does', '<=>', '..', '..^', '^..', '^..^', + '!=', '==', '<', '<=', '>', '>=', '~~', '===', '!eqv', + '&&', '||', '^^', '//', 'min', 'max', '??', '!!', 'ff', 'fff', 'so', + 'not', '<==', '==>', '<<==', '==>>', + ) + + # Perl 6 has a *lot* of possible bracketing characters + # this list was lifted from STD.pm6 (https://github.com/perl6/std) + PERL6_BRACKETS = { + u'\u0028': u'\u0029', u'\u003c': u'\u003e', u'\u005b': u'\u005d', + u'\u007b': u'\u007d', u'\u00ab': u'\u00bb', u'\u0f3a': u'\u0f3b', + u'\u0f3c': u'\u0f3d', u'\u169b': u'\u169c', u'\u2018': u'\u2019', + u'\u201a': u'\u2019', u'\u201b': u'\u2019', u'\u201c': u'\u201d', + u'\u201e': u'\u201d', u'\u201f': u'\u201d', u'\u2039': u'\u203a', + u'\u2045': u'\u2046', u'\u207d': u'\u207e', u'\u208d': u'\u208e', + u'\u2208': u'\u220b', u'\u2209': u'\u220c', u'\u220a': u'\u220d', + u'\u2215': u'\u29f5', u'\u223c': u'\u223d', u'\u2243': u'\u22cd', + u'\u2252': u'\u2253', u'\u2254': u'\u2255', u'\u2264': u'\u2265', + u'\u2266': u'\u2267', u'\u2268': u'\u2269', u'\u226a': u'\u226b', + u'\u226e': u'\u226f', u'\u2270': u'\u2271', u'\u2272': u'\u2273', + u'\u2274': u'\u2275', u'\u2276': u'\u2277', u'\u2278': u'\u2279', + u'\u227a': u'\u227b', u'\u227c': u'\u227d', u'\u227e': u'\u227f', + u'\u2280': u'\u2281', u'\u2282': u'\u2283', u'\u2284': u'\u2285', + u'\u2286': u'\u2287', u'\u2288': u'\u2289', u'\u228a': u'\u228b', + u'\u228f': u'\u2290', u'\u2291': u'\u2292', u'\u2298': u'\u29b8', + u'\u22a2': u'\u22a3', u'\u22a6': u'\u2ade', u'\u22a8': u'\u2ae4', + u'\u22a9': u'\u2ae3', u'\u22ab': u'\u2ae5', u'\u22b0': u'\u22b1', + u'\u22b2': u'\u22b3', u'\u22b4': u'\u22b5', u'\u22b6': u'\u22b7', + u'\u22c9': u'\u22ca', u'\u22cb': u'\u22cc', u'\u22d0': u'\u22d1', + u'\u22d6': u'\u22d7', u'\u22d8': u'\u22d9', u'\u22da': u'\u22db', + u'\u22dc': u'\u22dd', u'\u22de': u'\u22df', u'\u22e0': u'\u22e1', + u'\u22e2': u'\u22e3', u'\u22e4': u'\u22e5', u'\u22e6': u'\u22e7', + u'\u22e8': u'\u22e9', u'\u22ea': u'\u22eb', u'\u22ec': u'\u22ed', + u'\u22f0': u'\u22f1', u'\u22f2': u'\u22fa', u'\u22f3': u'\u22fb', + u'\u22f4': u'\u22fc', u'\u22f6': u'\u22fd', u'\u22f7': u'\u22fe', + u'\u2308': u'\u2309', u'\u230a': u'\u230b', u'\u2329': u'\u232a', + u'\u23b4': u'\u23b5', u'\u2768': u'\u2769', u'\u276a': u'\u276b', + u'\u276c': u'\u276d', u'\u276e': u'\u276f', u'\u2770': u'\u2771', + u'\u2772': u'\u2773', u'\u2774': u'\u2775', u'\u27c3': u'\u27c4', + u'\u27c5': u'\u27c6', u'\u27d5': u'\u27d6', u'\u27dd': u'\u27de', + u'\u27e2': u'\u27e3', u'\u27e4': u'\u27e5', u'\u27e6': u'\u27e7', + u'\u27e8': u'\u27e9', u'\u27ea': u'\u27eb', u'\u2983': u'\u2984', + u'\u2985': u'\u2986', u'\u2987': u'\u2988', u'\u2989': u'\u298a', + u'\u298b': u'\u298c', u'\u298d': u'\u298e', u'\u298f': u'\u2990', + u'\u2991': u'\u2992', u'\u2993': u'\u2994', u'\u2995': u'\u2996', + u'\u2997': u'\u2998', u'\u29c0': u'\u29c1', u'\u29c4': u'\u29c5', + u'\u29cf': u'\u29d0', u'\u29d1': u'\u29d2', u'\u29d4': u'\u29d5', + u'\u29d8': u'\u29d9', u'\u29da': u'\u29db', u'\u29f8': u'\u29f9', + u'\u29fc': u'\u29fd', u'\u2a2b': u'\u2a2c', u'\u2a2d': u'\u2a2e', + u'\u2a34': u'\u2a35', u'\u2a3c': u'\u2a3d', u'\u2a64': u'\u2a65', + u'\u2a79': u'\u2a7a', u'\u2a7d': u'\u2a7e', u'\u2a7f': u'\u2a80', + u'\u2a81': u'\u2a82', u'\u2a83': u'\u2a84', u'\u2a8b': u'\u2a8c', + u'\u2a91': u'\u2a92', u'\u2a93': u'\u2a94', u'\u2a95': u'\u2a96', + u'\u2a97': u'\u2a98', u'\u2a99': u'\u2a9a', u'\u2a9b': u'\u2a9c', + u'\u2aa1': u'\u2aa2', u'\u2aa6': u'\u2aa7', u'\u2aa8': u'\u2aa9', + u'\u2aaa': u'\u2aab', u'\u2aac': u'\u2aad', u'\u2aaf': u'\u2ab0', + u'\u2ab3': u'\u2ab4', u'\u2abb': u'\u2abc', u'\u2abd': u'\u2abe', + u'\u2abf': u'\u2ac0', u'\u2ac1': u'\u2ac2', u'\u2ac3': u'\u2ac4', + u'\u2ac5': u'\u2ac6', u'\u2acd': u'\u2ace', u'\u2acf': u'\u2ad0', + u'\u2ad1': u'\u2ad2', u'\u2ad3': u'\u2ad4', u'\u2ad5': u'\u2ad6', + u'\u2aec': u'\u2aed', u'\u2af7': u'\u2af8', u'\u2af9': u'\u2afa', + u'\u2e02': u'\u2e03', u'\u2e04': u'\u2e05', u'\u2e09': u'\u2e0a', + u'\u2e0c': u'\u2e0d', u'\u2e1c': u'\u2e1d', u'\u2e20': u'\u2e21', + u'\u3008': u'\u3009', u'\u300a': u'\u300b', u'\u300c': u'\u300d', + u'\u300e': u'\u300f', u'\u3010': u'\u3011', u'\u3014': u'\u3015', + u'\u3016': u'\u3017', u'\u3018': u'\u3019', u'\u301a': u'\u301b', + u'\u301d': u'\u301e', u'\ufd3e': u'\ufd3f', u'\ufe17': u'\ufe18', + u'\ufe35': u'\ufe36', u'\ufe37': u'\ufe38', u'\ufe39': u'\ufe3a', + u'\ufe3b': u'\ufe3c', u'\ufe3d': u'\ufe3e', u'\ufe3f': u'\ufe40', + u'\ufe41': u'\ufe42', u'\ufe43': u'\ufe44', u'\ufe47': u'\ufe48', + u'\ufe59': u'\ufe5a', u'\ufe5b': u'\ufe5c', u'\ufe5d': u'\ufe5e', + u'\uff08': u'\uff09', u'\uff1c': u'\uff1e', u'\uff3b': u'\uff3d', + u'\uff5b': u'\uff5d', u'\uff5f': u'\uff60', u'\uff62': u'\uff63', + } + + def _build_word_match(words, boundary_regex_fragment=None, prefix='', suffix=''): + if boundary_regex_fragment is None: + return r'\b(' + prefix + r'|'.join(re.escape(x) for x in words) + \ + suffix + r')\b' + else: + return r'(? 0: + next_open_pos = text.find(opening_chars, search_pos + n_chars) + next_close_pos = text.find(closing_chars, search_pos + n_chars) + + if next_close_pos == -1: + next_close_pos = len(text) + nesting_level = 0 + elif next_open_pos != -1 and next_open_pos < next_close_pos: + nesting_level += 1 + search_pos = next_open_pos + else: # next_close_pos < next_open_pos + nesting_level -= 1 + search_pos = next_close_pos + + end_pos = next_close_pos + + if end_pos < 0: # if we didn't find a closer, just highlight the + # rest of the text in this class + end_pos = len(text) + + if adverbs is not None and re.search(r':to\b', adverbs): + heredoc_terminator = text[match.start('delimiter') + n_chars:end_pos] + end_heredoc = re.search(r'^\s*' + re.escape(heredoc_terminator) + + r'\s*$', text[end_pos:], re.MULTILINE) + + if end_heredoc: + end_pos += end_heredoc.end() + else: + end_pos = len(text) + + yield match.start(), token_class, text[match.start():end_pos + n_chars] + context.pos = end_pos + n_chars + + return callback + + def opening_brace_callback(lexer, match, context): + stack = context.stack + + yield match.start(), Text, context.text[match.start():match.end()] + context.pos = match.end() + + # if we encounter an opening brace and we're one level + # below a token state, it means we need to increment + # the nesting level for braces so we know later when + # we should return to the token rules. + if len(stack) > 2 and stack[-2] == 'token': + context.perl6_token_nesting_level += 1 + + def closing_brace_callback(lexer, match, context): + stack = context.stack + + yield match.start(), Text, context.text[match.start():match.end()] + context.pos = match.end() + + # if we encounter a free closing brace and we're one level + # below a token state, it means we need to check the nesting + # level to see if we need to return to the token state. + if len(stack) > 2 and stack[-2] == 'token': + context.perl6_token_nesting_level -= 1 + if context.perl6_token_nesting_level == 0: + stack.pop() + + def embedded_perl6_callback(lexer, match, context): + context.perl6_token_nesting_level = 1 + yield match.start(), Text, context.text[match.start():match.end()] + context.pos = match.end() + context.stack.append('root') + + # If you're modifying these rules, be careful if you need to process '{' or '}' + # characters. We have special logic for processing these characters (due to the fact + # that you can nest Perl 6 code in regex blocks), so if you need to process one of + # them, make sure you also process the corresponding one! + tokens = { + 'common': [ + (r'#[`|=](?P(?P[' + ''.join(PERL6_BRACKETS) + r'])(?P=first_char)*)', + brackets_callback(Comment.Multiline)), + (r'#[^\n]*$', Comment.Singleline), + (r'^(\s*)=begin\s+(\w+)\b.*?^\1=end\s+\2', Comment.Multiline), + (r'^(\s*)=for.*?\n\s*?\n', Comment.Multiline), + (r'^=.*?\n\s*?\n', Comment.Multiline), + (r'(regex|token|rule)(\s*' + PERL6_IDENTIFIER_RANGE + '+:sym)', + bygroups(Keyword, Name), 'token-sym-brackets'), + (r'(regex|token|rule)(?!' + PERL6_IDENTIFIER_RANGE + ')(\s*' + PERL6_IDENTIFIER_RANGE + '+)?', + bygroups(Keyword, Name), 'pre-token'), + # deal with a special case in the Perl 6 grammar (role q { ... }) + (r'(role)(\s+)(q)(\s*)', bygroups(Keyword, Text, Name, Text)), + (_build_word_match(PERL6_KEYWORDS, PERL6_IDENTIFIER_RANGE), Keyword), + (_build_word_match(PERL6_BUILTIN_CLASSES, PERL6_IDENTIFIER_RANGE, suffix='(?::[UD])?'), + Name.Builtin), + (_build_word_match(PERL6_BUILTINS, PERL6_IDENTIFIER_RANGE), Name.Builtin), + # copied from PerlLexer + (r'[$@%&][.^:?=!~]?' + PERL6_IDENTIFIER_RANGE + u'+(?:<<.*?>>|<.*?>|«.*?»)*', + Name.Variable), + (r'\$[!/](?:<<.*?>>|<.*?>|«.*?»)*', Name.Variable.Global), + (r'::\?\w+', Name.Variable.Global), + (r'[$@%&]\*' + PERL6_IDENTIFIER_RANGE + u'+(?:<<.*?>>|<.*?>|«.*?»)*', + Name.Variable.Global), + (r'\$(?:<.*?>)+', Name.Variable), + (r'(?:q|qq|Q)[a-zA-Z]?\s*(?P:[\w\s:]+)?\s*(?P(?P[^0-9a-zA-Z:\s])' + r'(?P=first_char)*)', brackets_callback(String)), + # copied from PerlLexer + (r'0_?[0-7]+(_[0-7]+)*', Number.Oct), + (r'0x[0-9A-Fa-f]+(_[0-9A-Fa-f]+)*', Number.Hex), + (r'0b[01]+(_[01]+)*', Number.Bin), + (r'(?i)(\d*(_\d*)*\.\d+(_\d*)*|\d+(_\d*)*\.\d+(_\d*)*)(e[+-]?\d+)?', + Number.Float), + (r'(?i)\d+(_\d*)*e[+-]?\d+(_\d*)*', Number.Float), + (r'\d+(_\d+)*', Number.Integer), + (r'(?<=~~)\s*/(?:\\\\|\\/|.)*?/', String.Regex), + (r'(?<=[=(,])\s*/(?:\\\\|\\/|.)*?/', String.Regex), + (r'm\w+(?=\()', Name), + (r'(?:m|ms|rx)\s*(?P:[\w\s:]+)?\s*(?P(?P[^\w:\s])' + r'(?P=first_char)*)', brackets_callback(String.Regex)), + (r'(?:s|ss|tr)\s*(?::[\w\s:]+)?\s*/(?:\\\\|\\/|.)*?/(?:\\\\|\\/|.)*?/', + String.Regex), + (r'<[^\s=].*?\S>', String), + (_build_word_match(PERL6_OPERATORS), Operator), + (r'\w' + PERL6_IDENTIFIER_RANGE + '*', Name), + (r"'(\\\\|\\[^\\]|[^'\\])*'", String), + (r'"(\\\\|\\[^\\]|[^"\\])*"', String), + ], + 'root': [ + include('common'), + (r'\{', opening_brace_callback), + (r'\}', closing_brace_callback), + (r'.+?', Text), + ], + 'pre-token': [ + include('common'), + (r'\{', Text, ('#pop', 'token')), + (r'.+?', Text), + ], + 'token-sym-brackets': [ + (r'(?P(?P[' + ''.join(PERL6_BRACKETS) + '])(?P=first_char)*)', + brackets_callback(Name), ('#pop', 'pre-token')), + default(('#pop', 'pre-token')), + ], + 'token': [ + (r'\}', Text, '#pop'), + (r'(?<=:)(?:my|our|state|constant|temp|let).*?;', using(this)), + # make sure that quotes in character classes aren't treated as strings + (r'<(?:[-!?+.]\s*)?\[.*?\]>', String.Regex), + # make sure that '#' characters in quotes aren't treated as comments + (r"(?my|our)\s+)?(?:module|class|role|enum|grammar)', line) + if class_decl: + if saw_perl_decl or class_decl.group('scope') is not None: + return True + rating = 0.05 + continue + break + + return rating + + def __init__(self, **options): + super(Perl6Lexer, self).__init__(**options) + self.encoding = options.get('encoding', 'utf-8') diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/php.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/php.py new file mode 100644 index 0000000000..08dfa6a5ac --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/php.py @@ -0,0 +1,245 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.php + ~~~~~~~~~~~~~~~~~~~ + + Lexers for PHP and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, default, using, this +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Other +from pygments.util import get_bool_opt, get_list_opt, iteritems + +__all__ = ['ZephirLexer', 'PhpLexer'] + + +class ZephirLexer(RegexLexer): + """ + For `Zephir language `_ source code. + + Zephir is a compiled high level language aimed + to the creation of C-extensions for PHP. + + .. versionadded:: 2.0 + """ + + name = 'Zephir' + aliases = ['zephir'] + filenames = ['*.zep'] + + zephir_keywords = ['fetch', 'echo', 'isset', 'empty'] + zephir_type = ['bit', 'bits', 'string'] + + flags = re.DOTALL | re.MULTILINE + + tokens = { + 'commentsandwhitespace': [ + (r'\s+', Text), + (r'//.*?\n', Comment.Single), + (r'/\*.*?\*/', Comment.Multiline) + ], + 'slashstartsregex': [ + include('commentsandwhitespace'), + (r'/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/' + r'([gim]+\b|\B)', String.Regex, '#pop'), + default('#pop') + ], + 'badregex': [ + (r'\n', Text, '#pop') + ], + 'root': [ + (r'^(?=\s|/|', Punctuation), + (r'"(?:\\x[0-9a-fA-F]+\\|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}|' + r'\\[0-7]+\\|\\["\nabcefnrstv]|[^\\"])*"', String.Double), + (r"'(?:''|[^'])*'", String.Atom), # quoted atom + # Needs to not be followed by an atom. + # (r'=(?=\s|[a-zA-Z\[])', Operator), + (r'is\b', Operator), + (r'(<|>|=<|>=|==|=:=|=|/|//|\*|\+|-)(?=\s|[a-zA-Z0-9\[])', + Operator), + (r'(mod|div|not)\b', Operator), + (r'_', Keyword), # The don't-care variable + (r'([a-z]+)(:)', bygroups(Name.Namespace, Punctuation)), + (u'([a-z\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]' + u'[\w$\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]*)' + u'(\\s*)(:-|-->)', + bygroups(Name.Function, Text, Operator)), # function defn + (u'([a-z\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]' + u'[\w$\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]*)' + u'(\\s*)(\\()', + bygroups(Name.Function, Text, Punctuation)), + (u'[a-z\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]' + u'[\w$\u00c0-\u1fff\u3040-\ud7ff\ue000-\uffef]*', + String.Atom), # atom, characters + # This one includes ! + (u'[#&*+\\-./:<=>?@\\\\^~\u00a1-\u00bf\u2010-\u303f]+', + String.Atom), # atom, graphics + (r'[A-Z_]\w*', Name.Variable), + (u'\\s+|[\u2000-\u200f\ufff0-\ufffe\uffef]', Text), + ], + 'nested-comment': [ + (r'\*/', Comment.Multiline, '#pop'), + (r'/\*', Comment.Multiline, '#push'), + (r'[^*/]+', Comment.Multiline), + (r'[*/]', Comment.Multiline), + ], + } + + def analyse_text(text): + return ':-' in text + + +class LogtalkLexer(RegexLexer): + """ + For `Logtalk `_ source code. + + .. versionadded:: 0.10 + """ + + name = 'Logtalk' + aliases = ['logtalk'] + filenames = ['*.lgt', '*.logtalk'] + mimetypes = ['text/x-logtalk'] + + tokens = { + 'root': [ + # Directives + (r'^\s*:-\s', Punctuation, 'directive'), + # Comments + (r'%.*?\n', Comment), + (r'/\*(.|\n)*?\*/', Comment), + # Whitespace + (r'\n', Text), + (r'\s+', Text), + # Numbers + (r"0'.", Number), + (r'0b[01]+', Number.Bin), + (r'0o[0-7]+', Number.Oct), + (r'0x[0-9a-fA-F]+', Number.Hex), + (r'\d+\.?\d*((e|E)(\+|-)?\d+)?', Number), + # Variables + (r'([A-Z_]\w*)', Name.Variable), + # Event handlers + (r'(after|before)(?=[(])', Keyword), + # Message forwarding handler + (r'forward(?=[(])', Keyword), + # Execution-context methods + (r'(parameter|this|se(lf|nder))(?=[(])', Keyword), + # Reflection + (r'(current_predicate|predicate_property)(?=[(])', Keyword), + # DCGs and term expansion + (r'(expand_(goal|term)|(goal|term)_expansion|phrase)(?=[(])', Keyword), + # Entity + (r'(abolish|c(reate|urrent))_(object|protocol|category)(?=[(])', Keyword), + (r'(object|protocol|category)_property(?=[(])', Keyword), + # Entity relations + (r'co(mplements_object|nforms_to_protocol)(?=[(])', Keyword), + (r'extends_(object|protocol|category)(?=[(])', Keyword), + (r'imp(lements_protocol|orts_category)(?=[(])', Keyword), + (r'(instantiat|specializ)es_class(?=[(])', Keyword), + # Events + (r'(current_event|(abolish|define)_events)(?=[(])', Keyword), + # Flags + (r'(current|set)_logtalk_flag(?=[(])', Keyword), + # Compiling, loading, and library paths + (r'logtalk_(compile|l(ibrary_path|oad|oad_context)|make)(?=[(])', Keyword), + (r'\blogtalk_make\b', Keyword), + # Database + (r'(clause|retract(all)?)(?=[(])', Keyword), + (r'a(bolish|ssert(a|z))(?=[(])', Keyword), + # Control constructs + (r'(ca(ll|tch)|throw)(?=[(])', Keyword), + (r'(fa(il|lse)|true)\b', Keyword), + # All solutions + (r'((bag|set)of|f(ind|or)all)(?=[(])', Keyword), + # Multi-threading meta-predicates + (r'threaded(_(call|once|ignore|exit|peek|wait|notify))?(?=[(])', Keyword), + # Term unification + (r'(subsumes_term|unify_with_occurs_check)(?=[(])', Keyword), + # Term creation and decomposition + (r'(functor|arg|copy_term|numbervars|term_variables)(?=[(])', Keyword), + # Evaluable functors + (r'(rem|m(ax|in|od)|abs|sign)(?=[(])', Keyword), + (r'float(_(integer|fractional)_part)?(?=[(])', Keyword), + (r'(floor|truncate|round|ceiling)(?=[(])', Keyword), + # Other arithmetic functors + (r'(cos|a(cos|sin|tan)|exp|log|s(in|qrt))(?=[(])', Keyword), + # Term testing + (r'(var|atom(ic)?|integer|float|c(allable|ompound)|n(onvar|umber)|' + r'ground|acyclic_term)(?=[(])', Keyword), + # Term comparison + (r'compare(?=[(])', Keyword), + # Stream selection and control + (r'(curren|se)t_(in|out)put(?=[(])', Keyword), + (r'(open|close)(?=[(])', Keyword), + (r'flush_output(?=[(])', Keyword), + (r'(at_end_of_stream|flush_output)\b', Keyword), + (r'(stream_property|at_end_of_stream|set_stream_position)(?=[(])', Keyword), + # Character and byte input/output + (r'(nl|(get|peek|put)_(byte|c(har|ode)))(?=[(])', Keyword), + (r'\bnl\b', Keyword), + # Term input/output + (r'read(_term)?(?=[(])', Keyword), + (r'write(q|_(canonical|term))?(?=[(])', Keyword), + (r'(current_)?op(?=[(])', Keyword), + (r'(current_)?char_conversion(?=[(])', Keyword), + # Atomic term processing + (r'atom_(length|c(hars|o(ncat|des)))(?=[(])', Keyword), + (r'(char_code|sub_atom)(?=[(])', Keyword), + (r'number_c(har|ode)s(?=[(])', Keyword), + # Implementation defined hooks functions + (r'(se|curren)t_prolog_flag(?=[(])', Keyword), + (r'\bhalt\b', Keyword), + (r'halt(?=[(])', Keyword), + # Message sending operators + (r'(::|:|\^\^)', Operator), + # External call + (r'[{}]', Keyword), + # Logic and control + (r'(ignore|once)(?=[(])', Keyword), + (r'\brepeat\b', Keyword), + # Sorting + (r'(key)?sort(?=[(])', Keyword), + # Bitwise functors + (r'(>>|<<|/\\|\\\\|\\)', Operator), + # Predicate aliases + (r'\bas\b', Operator), + # Arithemtic evaluation + (r'\bis\b', Keyword), + # Arithemtic comparison + (r'(=:=|=\\=|<|=<|>=|>)', Operator), + # Term creation and decomposition + (r'=\.\.', Operator), + # Term unification + (r'(=|\\=)', Operator), + # Term comparison + (r'(==|\\==|@=<|@<|@>=|@>)', Operator), + # Evaluable functors + (r'(//|[-+*/])', Operator), + (r'\b(e|pi|mod|rem)\b', Operator), + # Other arithemtic functors + (r'\b\*\*\b', Operator), + # DCG rules + (r'-->', Operator), + # Control constructs + (r'([!;]|->)', Operator), + # Logic and control + (r'\\+', Operator), + # Mode operators + (r'[?@]', Operator), + # Existential quantifier + (r'\^', Operator), + # Strings + (r'"(\\\\|\\"|[^"])*"', String), + # Ponctuation + (r'[()\[\],.|]', Text), + # Atoms + (r"[a-z]\w*", Text), + (r"'", String, 'quoted_atom'), + ], + + 'quoted_atom': [ + (r"''", String), + (r"'", String, '#pop'), + (r'\\([\\abfnrtv"\']|(x[a-fA-F0-9]+|[0-7]+)\\)', String.Escape), + (r"[^\\'\n]+", String), + (r'\\', String), + ], + + 'directive': [ + # Conditional compilation directives + (r'(el)?if(?=[(])', Keyword, 'root'), + (r'(e(lse|ndif))[.]', Keyword, 'root'), + # Entity directives + (r'(category|object|protocol)(?=[(])', Keyword, 'entityrelations'), + (r'(end_(category|object|protocol))[.]', Keyword, 'root'), + # Predicate scope directives + (r'(public|protected|private)(?=[(])', Keyword, 'root'), + # Other directives + (r'e(n(coding|sure_loaded)|xport)(?=[(])', Keyword, 'root'), + (r'in(clude|itialization|fo)(?=[(])', Keyword, 'root'), + (r'(built_in|dynamic|synchronized|threaded)[.]', Keyword, 'root'), + (r'(alias|d(ynamic|iscontiguous)|m(eta_(non_terminal|predicate)|ode|ultifile)|' + r's(et_(logtalk|prolog)_flag|ynchronized))(?=[(])', Keyword, 'root'), + (r'op(?=[(])', Keyword, 'root'), + (r'(c(alls|oinductive)|module|reexport|use(s|_module))(?=[(])', Keyword, 'root'), + (r'[a-z]\w*(?=[(])', Text, 'root'), + (r'[a-z]\w*[.]', Text, 'root'), + ], + + 'entityrelations': [ + (r'(complements|extends|i(nstantiates|mp(lements|orts))|specializes)(?=[(])', Keyword), + # Numbers + (r"0'.", Number), + (r'0b[01]+', Number.Bin), + (r'0o[0-7]+', Number.Oct), + (r'0x[0-9a-fA-F]+', Number.Hex), + (r'\d+\.?\d*((e|E)(\+|-)?\d+)?', Number), + # Variables + (r'([A-Z_]\w*)', Name.Variable), + # Atoms + (r"[a-z]\w*", Text), + (r"'", String, 'quoted_atom'), + # Strings + (r'"(\\\\|\\"|[^"])*"', String), + # End of entity-opening directive + (r'([)]\.)', Text, 'root'), + # Scope operator + (r'(::)', Operator), + # Ponctuation + (r'[()\[\],.|]', Text), + # Comments + (r'%.*?\n', Comment), + (r'/\*(.|\n)*?\*/', Comment), + # Whitespace + (r'\n', Text), + (r'\s+', Text), + ] + } + + def analyse_text(text): + if ':- object(' in text: + return 1.0 + elif ':- protocol(' in text: + return 1.0 + elif ':- category(' in text: + return 1.0 + elif re.search('^:-\s[a-z]', text, re.M): + return 0.9 + else: + return 0.0 diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/python.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/python.py new file mode 100644 index 0000000000..259d1a9c85 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/python.py @@ -0,0 +1,833 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.python + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Python and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, include, bygroups, using, \ + default, words, combined, do_insertions +from pygments.util import get_bool_opt, shebang_matches +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Generic, Other, Error +from pygments import unistring as uni + +__all__ = ['PythonLexer', 'PythonConsoleLexer', 'PythonTracebackLexer', + 'Python3Lexer', 'Python3TracebackLexer', 'CythonLexer', + 'DgLexer', 'NumPyLexer'] + +line_re = re.compile('.*?\n') + + +class PythonLexer(RegexLexer): + """ + For `Python `_ source code. + """ + + name = 'Python' + aliases = ['python', 'py', 'sage'] + filenames = ['*.py', '*.pyw', '*.sc', 'SConstruct', 'SConscript', '*.tac', '*.sage'] + mimetypes = ['text/x-python', 'application/x-python'] + + tokens = { + 'root': [ + (r'\n', Text), + (r'^(\s*)([rRuU]{,2}"""(?:.|\n)*?""")', bygroups(Text, String.Doc)), + (r"^(\s*)([rRuU]{,2}'''(?:.|\n)*?''')", bygroups(Text, String.Doc)), + (r'[^\S\n]+', Text), + (r'#.*$', Comment), + (r'[]{}:(),;[]', Punctuation), + (r'\\\n', Text), + (r'\\', Text), + (r'(in|is|and|or|not)\b', Operator.Word), + (r'!=|==|<<|>>|[-~+/*%=<>&^|.]', Operator), + include('keywords'), + (r'(def)((?:\s|\\\s)+)', bygroups(Keyword, Text), 'funcname'), + (r'(class)((?:\s|\\\s)+)', bygroups(Keyword, Text), 'classname'), + (r'(from)((?:\s|\\\s)+)', bygroups(Keyword.Namespace, Text), + 'fromimport'), + (r'(import)((?:\s|\\\s)+)', bygroups(Keyword.Namespace, Text), + 'import'), + include('builtins'), + include('backtick'), + ('(?:[rR]|[uU][rR]|[rR][uU])"""', String, 'tdqs'), + ("(?:[rR]|[uU][rR]|[rR][uU])'''", String, 'tsqs'), + ('(?:[rR]|[uU][rR]|[rR][uU])"', String, 'dqs'), + ("(?:[rR]|[uU][rR]|[rR][uU])'", String, 'sqs'), + ('[uU]?"""', String, combined('stringescape', 'tdqs')), + ("[uU]?'''", String, combined('stringescape', 'tsqs')), + ('[uU]?"', String, combined('stringescape', 'dqs')), + ("[uU]?'", String, combined('stringescape', 'sqs')), + include('name'), + include('numbers'), + ], + 'keywords': [ + (words(( + 'assert', 'break', 'continue', 'del', 'elif', 'else', 'except', + 'exec', 'finally', 'for', 'global', 'if', 'lambda', 'pass', + 'print', 'raise', 'return', 'try', 'while', 'yield', + 'yield from', 'as', 'with'), suffix=r'\b'), + Keyword), + ], + 'builtins': [ + (words(( + '__import__', 'abs', 'all', 'any', 'apply', 'basestring', 'bin', + 'bool', 'buffer', 'bytearray', 'bytes', 'callable', 'chr', 'classmethod', + 'cmp', 'coerce', 'compile', 'complex', 'delattr', 'dict', 'dir', 'divmod', + 'enumerate', 'eval', 'execfile', 'exit', 'file', 'filter', 'float', + 'frozenset', 'getattr', 'globals', 'hasattr', 'hash', 'hex', 'id', + 'input', 'int', 'intern', 'isinstance', 'issubclass', 'iter', 'len', + 'list', 'locals', 'long', 'map', 'max', 'min', 'next', 'object', + 'oct', 'open', 'ord', 'pow', 'property', 'range', 'raw_input', 'reduce', + 'reload', 'repr', 'reversed', 'round', 'set', 'setattr', 'slice', + 'sorted', 'staticmethod', 'str', 'sum', 'super', 'tuple', 'type', + 'unichr', 'unicode', 'vars', 'xrange', 'zip'), + prefix=r'(?`_ source code (version 3.0). + + .. versionadded:: 0.10 + """ + + name = 'Python 3' + aliases = ['python3', 'py3'] + filenames = [] # Nothing until Python 3 gets widespread + mimetypes = ['text/x-python3', 'application/x-python3'] + + flags = re.MULTILINE | re.UNICODE + + uni_name = "[%s][%s]*" % (uni.xid_start, uni.xid_continue) + + tokens = PythonLexer.tokens.copy() + tokens['keywords'] = [ + (words(( + 'assert', 'break', 'continue', 'del', 'elif', 'else', 'except', + 'finally', 'for', 'global', 'if', 'lambda', 'pass', 'raise', + 'nonlocal', 'return', 'try', 'while', 'yield', 'yield from', 'as', + 'with', 'True', 'False', 'None'), suffix=r'\b'), + Keyword), + ] + tokens['builtins'] = [ + (words(( + '__import__', 'abs', 'all', 'any', 'bin', 'bool', 'bytearray', 'bytes', + 'chr', 'classmethod', 'cmp', 'compile', 'complex', 'delattr', 'dict', + 'dir', 'divmod', 'enumerate', 'eval', 'filter', 'float', 'format', + 'frozenset', 'getattr', 'globals', 'hasattr', 'hash', 'hex', 'id', + 'input', 'int', 'isinstance', 'issubclass', 'iter', 'len', 'list', + 'locals', 'map', 'max', 'memoryview', 'min', 'next', 'object', 'oct', + 'open', 'ord', 'pow', 'print', 'property', 'range', 'repr', 'reversed', + 'round', 'set', 'setattr', 'slice', 'sorted', 'staticmethod', 'str', + 'sum', 'super', 'tuple', 'type', 'vars', 'zip'), prefix=r'(?>> a = 'foo' + >>> print a + foo + >>> 1 / 0 + Traceback (most recent call last): + File "", line 1, in + ZeroDivisionError: integer division or modulo by zero + + Additional options: + + `python3` + Use Python 3 lexer for code. Default is ``False``. + + .. versionadded:: 1.0 + """ + name = 'Python console session' + aliases = ['pycon'] + mimetypes = ['text/x-python-doctest'] + + def __init__(self, **options): + self.python3 = get_bool_opt(options, 'python3', False) + Lexer.__init__(self, **options) + + def get_tokens_unprocessed(self, text): + if self.python3: + pylexer = Python3Lexer(**self.options) + tblexer = Python3TracebackLexer(**self.options) + else: + pylexer = PythonLexer(**self.options) + tblexer = PythonTracebackLexer(**self.options) + + curcode = '' + insertions = [] + curtb = '' + tbindex = 0 + tb = 0 + for match in line_re.finditer(text): + line = match.group() + if line.startswith(u'>>> ') or line.startswith(u'... '): + tb = 0 + insertions.append((len(curcode), + [(0, Generic.Prompt, line[:4])])) + curcode += line[4:] + elif line.rstrip() == u'...' and not tb: + # only a new >>> prompt can end an exception block + # otherwise an ellipsis in place of the traceback frames + # will be mishandled + insertions.append((len(curcode), + [(0, Generic.Prompt, u'...')])) + curcode += line[3:] + else: + if curcode: + for item in do_insertions( + insertions, pylexer.get_tokens_unprocessed(curcode)): + yield item + curcode = '' + insertions = [] + if (line.startswith(u'Traceback (most recent call last):') or + re.match(u' File "[^"]+", line \\d+\\n$', line)): + tb = 1 + curtb = line + tbindex = match.start() + elif line == 'KeyboardInterrupt\n': + yield match.start(), Name.Class, line + elif tb: + curtb += line + if not (line.startswith(' ') or line.strip() == u'...'): + tb = 0 + for i, t, v in tblexer.get_tokens_unprocessed(curtb): + yield tbindex+i, t, v + else: + yield match.start(), Generic.Output, line + if curcode: + for item in do_insertions(insertions, + pylexer.get_tokens_unprocessed(curcode)): + yield item + if curtb: + for i, t, v in tblexer.get_tokens_unprocessed(curtb): + yield tbindex+i, t, v + + +class PythonTracebackLexer(RegexLexer): + """ + For Python tracebacks. + + .. versionadded:: 0.7 + """ + + name = 'Python Traceback' + aliases = ['pytb'] + filenames = ['*.pytb'] + mimetypes = ['text/x-python-traceback'] + + tokens = { + 'root': [ + (r'^Traceback \(most recent call last\):\n', + Generic.Traceback, 'intb'), + # SyntaxError starts with this. + (r'^(?= File "[^"]+", line \d+)', Generic.Traceback, 'intb'), + (r'^.*\n', Other), + ], + 'intb': [ + (r'^( File )("[^"]+")(, line )(\d+)(, in )(.+)(\n)', + bygroups(Text, Name.Builtin, Text, Number, Text, Name, Text)), + (r'^( File )("[^"]+")(, line )(\d+)(\n)', + bygroups(Text, Name.Builtin, Text, Number, Text)), + (r'^( )(.+)(\n)', + bygroups(Text, using(PythonLexer), Text)), + (r'^([ \t]*)(\.\.\.)(\n)', + bygroups(Text, Comment, Text)), # for doctests... + (r'^([^:]+)(: )(.+)(\n)', + bygroups(Generic.Error, Text, Name, Text), '#pop'), + (r'^([a-zA-Z_]\w*)(:?\n)', + bygroups(Generic.Error, Text), '#pop') + ], + } + + +class Python3TracebackLexer(RegexLexer): + """ + For Python 3.0 tracebacks, with support for chained exceptions. + + .. versionadded:: 1.0 + """ + + name = 'Python 3.0 Traceback' + aliases = ['py3tb'] + filenames = ['*.py3tb'] + mimetypes = ['text/x-python3-traceback'] + + tokens = { + 'root': [ + (r'\n', Text), + (r'^Traceback \(most recent call last\):\n', Generic.Traceback, 'intb'), + (r'^During handling of the above exception, another ' + r'exception occurred:\n\n', Generic.Traceback), + (r'^The above exception was the direct cause of the ' + r'following exception:\n\n', Generic.Traceback), + (r'^(?= File "[^"]+", line \d+)', Generic.Traceback, 'intb'), + ], + 'intb': [ + (r'^( File )("[^"]+")(, line )(\d+)(, in )(.+)(\n)', + bygroups(Text, Name.Builtin, Text, Number, Text, Name, Text)), + (r'^( File )("[^"]+")(, line )(\d+)(\n)', + bygroups(Text, Name.Builtin, Text, Number, Text)), + (r'^( )(.+)(\n)', + bygroups(Text, using(Python3Lexer), Text)), + (r'^([ \t]*)(\.\.\.)(\n)', + bygroups(Text, Comment, Text)), # for doctests... + (r'^([^:]+)(: )(.+)(\n)', + bygroups(Generic.Error, Text, Name, Text), '#pop'), + (r'^([a-zA-Z_]\w*)(:?\n)', + bygroups(Generic.Error, Text), '#pop') + ], + } + + +class CythonLexer(RegexLexer): + """ + For Pyrex and `Cython `_ source code. + + .. versionadded:: 1.1 + """ + + name = 'Cython' + aliases = ['cython', 'pyx', 'pyrex'] + filenames = ['*.pyx', '*.pxd', '*.pxi'] + mimetypes = ['text/x-cython', 'application/x-cython'] + + tokens = { + 'root': [ + (r'\n', Text), + (r'^(\s*)("""(?:.|\n)*?""")', bygroups(Text, String.Doc)), + (r"^(\s*)('''(?:.|\n)*?''')", bygroups(Text, String.Doc)), + (r'[^\S\n]+', Text), + (r'#.*$', Comment), + (r'[]{}:(),;[]', Punctuation), + (r'\\\n', Text), + (r'\\', Text), + (r'(in|is|and|or|not)\b', Operator.Word), + (r'(<)([a-zA-Z0-9.?]+)(>)', + bygroups(Punctuation, Keyword.Type, Punctuation)), + (r'!=|==|<<|>>|[-~+/*%=<>&^|.?]', Operator), + (r'(from)(\d+)(<=)(\s+)(<)(\d+)(:)', + bygroups(Keyword, Number.Integer, Operator, Name, Operator, + Name, Punctuation)), + include('keywords'), + (r'(def|property)(\s+)', bygroups(Keyword, Text), 'funcname'), + (r'(cp?def)(\s+)', bygroups(Keyword, Text), 'cdef'), + (r'(class|struct)(\s+)', bygroups(Keyword, Text), 'classname'), + (r'(from)(\s+)', bygroups(Keyword, Text), 'fromimport'), + (r'(c?import)(\s+)', bygroups(Keyword, Text), 'import'), + include('builtins'), + include('backtick'), + ('(?:[rR]|[uU][rR]|[rR][uU])"""', String, 'tdqs'), + ("(?:[rR]|[uU][rR]|[rR][uU])'''", String, 'tsqs'), + ('(?:[rR]|[uU][rR]|[rR][uU])"', String, 'dqs'), + ("(?:[rR]|[uU][rR]|[rR][uU])'", String, 'sqs'), + ('[uU]?"""', String, combined('stringescape', 'tdqs')), + ("[uU]?'''", String, combined('stringescape', 'tsqs')), + ('[uU]?"', String, combined('stringescape', 'dqs')), + ("[uU]?'", String, combined('stringescape', 'sqs')), + include('name'), + include('numbers'), + ], + 'keywords': [ + (words(( + 'assert', 'break', 'by', 'continue', 'ctypedef', 'del', 'elif', + 'else', 'except', 'except?', 'exec', 'finally', 'for', 'gil', + 'global', 'if', 'include', 'lambda', 'nogil', 'pass', 'print', + 'raise', 'return', 'try', 'while', 'yield', 'as', 'with'), suffix=r'\b'), + Keyword), + (r'(DEF|IF|ELIF|ELSE)\b', Comment.Preproc), + ], + 'builtins': [ + (words(( + '__import__', 'abs', 'all', 'any', 'apply', 'basestring', 'bin', + 'bool', 'buffer', 'bytearray', 'bytes', 'callable', 'chr', + 'classmethod', 'cmp', 'coerce', 'compile', 'complex', 'delattr', + 'dict', 'dir', 'divmod', 'enumerate', 'eval', 'execfile', 'exit', + 'file', 'filter', 'float', 'frozenset', 'getattr', 'globals', + 'hasattr', 'hash', 'hex', 'id', 'input', 'int', 'intern', 'isinstance', + 'issubclass', 'iter', 'len', 'list', 'locals', 'long', 'map', 'max', + 'min', 'next', 'object', 'oct', 'open', 'ord', 'pow', 'property', + 'range', 'raw_input', 'reduce', 'reload', 'repr', 'reversed', + 'round', 'set', 'setattr', 'slice', 'sorted', 'staticmethod', + 'str', 'sum', 'super', 'tuple', 'type', 'unichr', 'unicode', + 'vars', 'xrange', 'zip'), prefix=r'(?`_, + a functional and object-oriented programming language + running on the CPython 3 VM. + + .. versionadded:: 1.6 + """ + name = 'dg' + aliases = ['dg'] + filenames = ['*.dg'] + mimetypes = ['text/x-dg'] + + tokens = { + 'root': [ + (r'\s+', Text), + (r'#.*?$', Comment.Single), + + (r'(?i)0b[01]+', Number.Bin), + (r'(?i)0o[0-7]+', Number.Oct), + (r'(?i)0x[0-9a-f]+', Number.Hex), + (r'(?i)[+-]?[0-9]+\.[0-9]+(e[+-]?[0-9]+)?j?', Number.Float), + (r'(?i)[+-]?[0-9]+e[+-]?\d+j?', Number.Float), + (r'(?i)[+-]?[0-9]+j?', Number.Integer), + + (r"(?i)(br|r?b?)'''", String, combined('stringescape', 'tsqs', 'string')), + (r'(?i)(br|r?b?)"""', String, combined('stringescape', 'tdqs', 'string')), + (r"(?i)(br|r?b?)'", String, combined('stringescape', 'sqs', 'string')), + (r'(?i)(br|r?b?)"', String, combined('stringescape', 'dqs', 'string')), + + (r"`\w+'*`", Operator), + (r'\b(and|in|is|or|where)\b', Operator.Word), + (r'[!$%&*+\-./:<-@\\^|~;,]+', Operator), + + (words(( + 'bool', 'bytearray', 'bytes', 'classmethod', 'complex', 'dict', 'dict\'', + 'float', 'frozenset', 'int', 'list', 'list\'', 'memoryview', 'object', + 'property', 'range', 'set', 'set\'', 'slice', 'staticmethod', 'str', 'super', + 'tuple', 'tuple\'', 'type'), prefix=r'(?') or line.startswith('+'): + # Colorize the prompt as such, + # then put rest of line into current_code_block + insertions.append((len(current_code_block), + [(0, Generic.Prompt, line[:2])])) + current_code_block += line[2:] + else: + # We have reached a non-prompt line! + # If we have stored prompt lines, need to process them first. + if current_code_block: + # Weave together the prompts and highlight code. + for item in do_insertions( + insertions, slexer.get_tokens_unprocessed(current_code_block)): + yield item + # Reset vars for next code block. + current_code_block = '' + insertions = [] + # Now process the actual line itself, this is output from R. + yield match.start(), Generic.Output, line + + # If we happen to end on a code block with nothing after it, need to + # process the last code block. This is neither elegant nor DRY so + # should be changed. + if current_code_block: + for item in do_insertions( + insertions, slexer.get_tokens_unprocessed(current_code_block)): + yield item + + +class SLexer(RegexLexer): + """ + For S, S-plus, and R source code. + + .. versionadded:: 0.10 + """ + + name = 'S' + aliases = ['splus', 's', 'r'] + filenames = ['*.S', '*.R', '.Rhistory', '.Rprofile', '.Renviron'] + mimetypes = ['text/S-plus', 'text/S', 'text/x-r-source', 'text/x-r', + 'text/x-R', 'text/x-r-history', 'text/x-r-profile'] + + builtins_base = ( + 'Arg', 'Conj', 'Cstack_info', 'Encoding', 'FALSE', + 'Filter', 'Find', 'I', 'ISOdate', 'ISOdatetime', 'Im', 'Inf', + 'La.svd', 'Map', 'Math.Date', 'Math.POSIXt', 'Math.data.frame', + 'Math.difftime', 'Math.factor', 'Mod', 'NA_character_', + 'NA_complex_', 'NA_real_', 'NCOL', 'NROW', 'NULLNA_integer_', 'NaN', + 'Negate', 'NextMethod', 'Ops.Date', 'Ops.POSIXt', 'Ops.data.frame', + 'Ops.difftime', 'Ops.factor', 'Ops.numeric_version', 'Ops.ordered', + 'Position', 'R.Version', 'R.home', 'R.version', 'R.version.string', + 'RNGkind', 'RNGversion', 'R_system_version', 'Re', 'Recall', + 'Reduce', 'Summary.Date', 'Summary.POSIXct', 'Summary.POSIXlt', + 'Summary.data.frame', 'Summary.difftime', 'Summary.factor', + 'Summary.numeric_version', 'Summary.ordered', 'Sys.Date', + 'Sys.chmod', 'Sys.getenv', 'Sys.getlocale', 'Sys.getpid', + 'Sys.glob', 'Sys.info', 'Sys.localeconv', 'Sys.readlink', + 'Sys.setFileTime', 'Sys.setenv', 'Sys.setlocale', 'Sys.sleep', + 'Sys.time', 'Sys.timezone', 'Sys.umask', 'Sys.unsetenv', + 'Sys.which', 'TRUE', 'UseMethod', 'Vectorize', 'abbreviate', 'abs', + 'acos', 'acosh', 'addNA', 'addTaskCallback', 'agrep', 'alist', + 'all', 'all.equal', 'all.equal.POSIXct', 'all.equal.character', + 'all.equal.default', 'all.equal.factor', 'all.equal.formula', + 'all.equal.language', 'all.equal.list', 'all.equal.numeric', + 'all.equal.raw', 'all.names', 'all.vars', 'any', 'anyDuplicated', + 'anyDuplicated.array', 'anyDuplicated.data.frame', + 'anyDuplicated.default', 'anyDuplicated.matrix', 'aperm', + 'aperm.default', 'aperm.table', 'append', 'apply', 'args', + 'arrayInd', 'as.Date', 'as.Date.POSIXct', 'as.Date.POSIXlt', + 'as.Date.character', 'as.Date.date', 'as.Date.dates', + 'as.Date.default', 'as.Date.factor', 'as.Date.numeric', + 'as.POSIXct', 'as.POSIXct.Date', 'as.POSIXct.POSIXlt', + 'as.POSIXct.date', 'as.POSIXct.dates', 'as.POSIXct.default', + 'as.POSIXct.numeric', 'as.POSIXlt', 'as.POSIXlt.Date', + 'as.POSIXlt.POSIXct', 'as.POSIXlt.character', 'as.POSIXlt.date', + 'as.POSIXlt.dates', 'as.POSIXlt.default', 'as.POSIXlt.factor', + 'as.POSIXlt.numeric', 'as.array', 'as.array.default', 'as.call', + 'as.character', 'as.character.Date', 'as.character.POSIXt', + 'as.character.condition', 'as.character.default', + 'as.character.error', 'as.character.factor', 'as.character.hexmode', + 'as.character.numeric_version', 'as.character.octmode', + 'as.character.srcref', 'as.complex', 'as.data.frame', + 'as.data.frame.AsIs', 'as.data.frame.Date', 'as.data.frame.POSIXct', + 'as.data.frame.POSIXlt', 'as.data.frame.array', + 'as.data.frame.character', 'as.data.frame.complex', + 'as.data.frame.data.frame', 'as.data.frame.default', + 'as.data.frame.difftime', 'as.data.frame.factor', + 'as.data.frame.integer', 'as.data.frame.list', + 'as.data.frame.logical', 'as.data.frame.matrix', + 'as.data.frame.model.matrix', 'as.data.frame.numeric', + 'as.data.frame.numeric_version', 'as.data.frame.ordered', + 'as.data.frame.raw', 'as.data.frame.table', 'as.data.frame.ts', + 'as.data.frame.vector', 'as.difftime', 'as.double', + 'as.double.POSIXlt', 'as.double.difftime', 'as.environment', + 'as.expression', 'as.expression.default', 'as.factor', + 'as.function', 'as.function.default', 'as.hexmode', 'as.integer', + 'as.list', 'as.list.Date', 'as.list.POSIXct', 'as.list.data.frame', + 'as.list.default', 'as.list.environment', 'as.list.factor', + 'as.list.function', 'as.list.numeric_version', 'as.logical', + 'as.logical.factor', 'as.matrix', 'as.matrix.POSIXlt', + 'as.matrix.data.frame', 'as.matrix.default', 'as.matrix.noquote', + 'as.name', 'as.null', 'as.null.default', 'as.numeric', + 'as.numeric_version', 'as.octmode', 'as.ordered', + 'as.package_version', 'as.pairlist', 'as.qr', 'as.raw', 'as.single', + 'as.single.default', 'as.symbol', 'as.table', 'as.table.default', + 'as.vector', 'as.vector.factor', 'asNamespace', 'asS3', 'asS4', + 'asin', 'asinh', 'assign', 'atan', 'atan2', 'atanh', + 'attachNamespace', 'attr', 'attr.all.equal', 'attributes', + 'autoload', 'autoloader', 'backsolve', 'baseenv', 'basename', + 'besselI', 'besselJ', 'besselK', 'besselY', 'beta', + 'bindingIsActive', 'bindingIsLocked', 'bindtextdomain', 'bitwAnd', + 'bitwNot', 'bitwOr', 'bitwShiftL', 'bitwShiftR', 'bitwXor', 'body', + 'bquote', 'browser', 'browserCondition', 'browserSetDebug', + 'browserText', 'builtins', 'by', 'by.data.frame', 'by.default', + 'bzfile', 'c.Date', 'c.POSIXct', 'c.POSIXlt', 'c.noquote', + 'c.numeric_version', 'call', 'callCC', 'capabilities', 'casefold', + 'cat', 'category', 'cbind', 'cbind.data.frame', 'ceiling', + 'char.expand', 'charToRaw', 'charmatch', 'chartr', 'check_tzones', + 'chol', 'chol.default', 'chol2inv', 'choose', 'class', + 'clearPushBack', 'close', 'close.connection', 'close.srcfile', + 'close.srcfilealias', 'closeAllConnections', 'col', 'colMeans', + 'colSums', 'colnames', 'commandArgs', 'comment', 'computeRestarts', + 'conditionCall', 'conditionCall.condition', 'conditionMessage', + 'conditionMessage.condition', 'conflicts', 'contributors', 'cos', + 'cosh', 'crossprod', 'cummax', 'cummin', 'cumprod', 'cumsum', 'cut', + 'cut.Date', 'cut.POSIXt', 'cut.default', 'dQuote', 'data.class', + 'data.matrix', 'date', 'debug', 'debugonce', + 'default.stringsAsFactors', 'delayedAssign', 'deparse', 'det', + 'determinant', 'determinant.matrix', 'dget', 'diag', 'diff', + 'diff.Date', 'diff.POSIXt', 'diff.default', 'difftime', 'digamma', + 'dim', 'dim.data.frame', 'dimnames', 'dimnames.data.frame', 'dir', + 'dir.create', 'dirname', 'do.call', 'dput', 'drop', 'droplevels', + 'droplevels.data.frame', 'droplevels.factor', 'dump', 'duplicated', + 'duplicated.POSIXlt', 'duplicated.array', 'duplicated.data.frame', + 'duplicated.default', 'duplicated.matrix', + 'duplicated.numeric_version', 'dyn.load', 'dyn.unload', 'eapply', + 'eigen', 'else', 'emptyenv', 'enc2native', 'enc2utf8', + 'encodeString', 'enquote', 'env.profile', 'environment', + 'environmentIsLocked', 'environmentName', 'eval', 'eval.parent', + 'evalq', 'exists', 'exp', 'expand.grid', 'expm1', 'expression', + 'factor', 'factorial', 'fifo', 'file', 'file.access', 'file.append', + 'file.choose', 'file.copy', 'file.create', 'file.exists', + 'file.info', 'file.link', 'file.path', 'file.remove', 'file.rename', + 'file.show', 'file.symlink', 'find.package', 'findInterval', + 'findPackageEnv', 'findRestart', 'floor', 'flush', + 'flush.connection', 'force', 'formals', 'format', + 'format.AsIs', 'format.Date', 'format.POSIXct', 'format.POSIXlt', + 'format.data.frame', 'format.default', 'format.difftime', + 'format.factor', 'format.hexmode', 'format.info', + 'format.libraryIQR', 'format.numeric_version', 'format.octmode', + 'format.packageInfo', 'format.pval', 'format.summaryDefault', + 'formatC', 'formatDL', 'forwardsolve', 'gamma', 'gc', 'gc.time', + 'gcinfo', 'gctorture', 'gctorture2', 'get', 'getAllConnections', + 'getCallingDLL', 'getCallingDLLe', 'getConnection', + 'getDLLRegisteredRoutines', 'getDLLRegisteredRoutines.DLLInfo', + 'getDLLRegisteredRoutines.character', 'getElement', + 'getExportedValue', 'getHook', 'getLoadedDLLs', 'getNamespace', + 'getNamespaceExports', 'getNamespaceImports', 'getNamespaceInfo', + 'getNamespaceName', 'getNamespaceUsers', 'getNamespaceVersion', + 'getNativeSymbolInfo', 'getOption', 'getRversion', 'getSrcLines', + 'getTaskCallbackNames', 'geterrmessage', 'gettext', 'gettextf', + 'getwd', 'gl', 'globalenv', 'gregexpr', 'grep', 'grepRaw', 'grepl', + 'gsub', 'gzcon', 'gzfile', 'head', 'iconv', 'iconvlist', + 'icuSetCollate', 'identical', 'identity', 'ifelse', 'importIntoEnv', + 'in', 'inherits', 'intToBits', 'intToUtf8', 'interaction', 'interactive', + 'intersect', 'inverse.rle', 'invisible', 'invokeRestart', + 'invokeRestartInteractively', 'is.R', 'is.array', 'is.atomic', + 'is.call', 'is.character', 'is.complex', 'is.data.frame', + 'is.double', 'is.element', 'is.environment', 'is.expression', + 'is.factor', 'is.finite', 'is.function', 'is.infinite', + 'is.integer', 'is.language', 'is.list', 'is.loaded', 'is.logical', + 'is.matrix', 'is.na', 'is.na.POSIXlt', 'is.na.data.frame', + 'is.na.numeric_version', 'is.name', 'is.nan', 'is.null', + 'is.numeric', 'is.numeric.Date', 'is.numeric.POSIXt', + 'is.numeric.difftime', 'is.numeric_version', 'is.object', + 'is.ordered', 'is.package_version', 'is.pairlist', 'is.primitive', + 'is.qr', 'is.raw', 'is.recursive', 'is.single', 'is.symbol', + 'is.table', 'is.unsorted', 'is.vector', 'isBaseNamespace', + 'isIncomplete', 'isNamespace', 'isOpen', 'isRestart', 'isS4', + 'isSeekable', 'isSymmetric', 'isSymmetric.matrix', 'isTRUE', + 'isatty', 'isdebugged', 'jitter', 'julian', 'julian.Date', + 'julian.POSIXt', 'kappa', 'kappa.default', 'kappa.lm', 'kappa.qr', + 'kronecker', 'l10n_info', 'labels', 'labels.default', 'lapply', + 'lazyLoad', 'lazyLoadDBexec', 'lazyLoadDBfetch', 'lbeta', 'lchoose', + 'length', 'length.POSIXlt', 'letters', 'levels', 'levels.default', + 'lfactorial', 'lgamma', 'library.dynam', 'library.dynam.unload', + 'licence', 'license', 'list.dirs', 'list.files', 'list2env', 'load', + 'loadNamespace', 'loadedNamespaces', 'loadingNamespaceInfo', + 'local', 'lockBinding', 'lockEnvironment', 'log', 'log10', 'log1p', + 'log2', 'logb', 'lower.tri', 'ls', 'make.names', 'make.unique', + 'makeActiveBinding', 'mapply', 'margin.table', 'mat.or.vec', + 'match', 'match.arg', 'match.call', 'match.fun', 'max', 'max.col', + 'mean', 'mean.Date', 'mean.POSIXct', 'mean.POSIXlt', 'mean.default', + 'mean.difftime', 'mem.limits', 'memCompress', 'memDecompress', + 'memory.profile', 'merge', 'merge.data.frame', 'merge.default', + 'message', 'mget', 'min', 'missing', 'mode', 'month.abb', + 'month.name', 'months', 'months.Date', 'months.POSIXt', + 'months.abb', 'months.nameletters', 'names', 'names.POSIXlt', + 'namespaceExport', 'namespaceImport', 'namespaceImportClasses', + 'namespaceImportFrom', 'namespaceImportMethods', 'nargs', 'nchar', + 'ncol', 'new.env', 'ngettext', 'nlevels', 'noquote', 'norm', + 'normalizePath', 'nrow', 'numeric_version', 'nzchar', 'objects', + 'oldClass', 'on.exit', 'open', 'open.connection', 'open.srcfile', + 'open.srcfilealias', 'open.srcfilecopy', 'options', 'order', + 'ordered', 'outer', 'packBits', 'packageEvent', + 'packageHasNamespace', 'packageStartupMessage', 'package_version', + 'pairlist', 'parent.env', 'parent.frame', 'parse', + 'parseNamespaceFile', 'paste', 'paste0', 'path.expand', + 'path.package', 'pipe', 'pmatch', 'pmax', 'pmax.int', 'pmin', + 'pmin.int', 'polyroot', 'pos.to.env', 'pretty', 'pretty.default', + 'prettyNum', 'print', 'print.AsIs', 'print.DLLInfo', + 'print.DLLInfoList', 'print.DLLRegisteredRoutines', 'print.Date', + 'print.NativeRoutineList', 'print.POSIXct', 'print.POSIXlt', + 'print.by', 'print.condition', 'print.connection', + 'print.data.frame', 'print.default', 'print.difftime', + 'print.factor', 'print.function', 'print.hexmode', + 'print.libraryIQR', 'print.listof', 'print.noquote', + 'print.numeric_version', 'print.octmode', 'print.packageInfo', + 'print.proc_time', 'print.restart', 'print.rle', + 'print.simple.list', 'print.srcfile', 'print.srcref', + 'print.summary.table', 'print.summaryDefault', 'print.table', + 'print.warnings', 'prmatrix', 'proc.time', 'prod', 'prop.table', + 'provideDimnames', 'psigamma', 'pushBack', 'pushBackLength', 'q', + 'qr', 'qr.Q', 'qr.R', 'qr.X', 'qr.coef', 'qr.default', 'qr.fitted', + 'qr.qty', 'qr.qy', 'qr.resid', 'qr.solve', 'quarters', + 'quarters.Date', 'quarters.POSIXt', 'quit', 'quote', 'range', + 'range.default', 'rank', 'rapply', 'raw', 'rawConnection', + 'rawConnectionValue', 'rawShift', 'rawToBits', 'rawToChar', 'rbind', + 'rbind.data.frame', 'rcond', 'read.dcf', 'readBin', 'readChar', + 'readLines', 'readRDS', 'readRenviron', 'readline', 'reg.finalizer', + 'regexec', 'regexpr', 'registerS3method', 'registerS3methods', + 'regmatches', 'remove', 'removeTaskCallback', 'rep', 'rep.Date', + 'rep.POSIXct', 'rep.POSIXlt', 'rep.factor', 'rep.int', + 'rep.numeric_version', 'rep_len', 'replace', 'replicate', + 'requireNamespace', 'restartDescription', 'restartFormals', + 'retracemem', 'rev', 'rev.default', 'rle', 'rm', 'round', + 'round.Date', 'round.POSIXt', 'row', 'row.names', + 'row.names.data.frame', 'row.names.default', 'rowMeans', 'rowSums', + 'rownames', 'rowsum', 'rowsum.data.frame', 'rowsum.default', + 'sQuote', 'sample', 'sample.int', 'sapply', 'save', 'save.image', + 'saveRDS', 'scale', 'scale.default', 'scan', 'search', + 'searchpaths', 'seek', 'seek.connection', 'seq', 'seq.Date', + 'seq.POSIXt', 'seq.default', 'seq.int', 'seq_along', 'seq_len', + 'sequence', 'serialize', 'set.seed', 'setHook', 'setNamespaceInfo', + 'setSessionTimeLimit', 'setTimeLimit', 'setdiff', 'setequal', + 'setwd', 'shQuote', 'showConnections', 'sign', 'signalCondition', + 'signif', 'simpleCondition', 'simpleError', 'simpleMessage', + 'simpleWarning', 'simplify2array', 'sin', 'single', + 'sinh', 'sink', 'sink.number', 'slice.index', 'socketConnection', + 'socketSelect', 'solve', 'solve.default', 'solve.qr', 'sort', + 'sort.POSIXlt', 'sort.default', 'sort.int', 'sort.list', 'split', + 'split.Date', 'split.POSIXct', 'split.data.frame', 'split.default', + 'sprintf', 'sqrt', 'srcfile', 'srcfilealias', 'srcfilecopy', + 'srcref', 'standardGeneric', 'stderr', 'stdin', 'stdout', 'stop', + 'stopifnot', 'storage.mode', 'strftime', 'strptime', 'strsplit', + 'strtoi', 'strtrim', 'structure', 'strwrap', 'sub', 'subset', + 'subset.data.frame', 'subset.default', 'subset.matrix', + 'substitute', 'substr', 'substring', 'sum', 'summary', + 'summary.Date', 'summary.POSIXct', 'summary.POSIXlt', + 'summary.connection', 'summary.data.frame', 'summary.default', + 'summary.factor', 'summary.matrix', 'summary.proc_time', + 'summary.srcfile', 'summary.srcref', 'summary.table', + 'suppressMessages', 'suppressPackageStartupMessages', + 'suppressWarnings', 'svd', 'sweep', 'sys.call', 'sys.calls', + 'sys.frame', 'sys.frames', 'sys.function', 'sys.load.image', + 'sys.nframe', 'sys.on.exit', 'sys.parent', 'sys.parents', + 'sys.save.image', 'sys.source', 'sys.status', 'system', + 'system.file', 'system.time', 'system2', 't', 't.data.frame', + 't.default', 'table', 'tabulate', 'tail', 'tan', 'tanh', 'tapply', + 'taskCallbackManager', 'tcrossprod', 'tempdir', 'tempfile', + 'testPlatformEquivalence', 'textConnection', 'textConnectionValue', + 'toString', 'toString.default', 'tolower', 'topenv', 'toupper', + 'trace', 'traceback', 'tracemem', 'tracingState', 'transform', + 'transform.data.frame', 'transform.default', 'trigamma', 'trunc', + 'trunc.Date', 'trunc.POSIXt', 'truncate', 'truncate.connection', + 'try', 'tryCatch', 'typeof', 'unclass', 'undebug', 'union', + 'unique', 'unique.POSIXlt', 'unique.array', 'unique.data.frame', + 'unique.default', 'unique.matrix', 'unique.numeric_version', + 'units', 'units.difftime', 'unix.time', 'unlink', 'unlist', + 'unloadNamespace', 'unlockBinding', 'unname', 'unserialize', + 'unsplit', 'untrace', 'untracemem', 'unz', 'upper.tri', 'url', + 'utf8ToInt', 'vapply', 'version', 'warning', 'warnings', 'weekdays', + 'weekdays.Date', 'weekdays.POSIXt', 'which', 'which.max', + 'which.min', 'with', 'with.default', 'withCallingHandlers', + 'withRestarts', 'withVisible', 'within', 'within.data.frame', + 'within.list', 'write', 'write.dcf', 'writeBin', 'writeChar', + 'writeLines', 'xor', 'xor.hexmode', 'xor.octmode', + 'xpdrows.data.frame', 'xtfrm', 'xtfrm.AsIs', 'xtfrm.Date', + 'xtfrm.POSIXct', 'xtfrm.POSIXlt', 'xtfrm.Surv', 'xtfrm.default', + 'xtfrm.difftime', 'xtfrm.factor', 'xtfrm.numeric_version', 'xzfile', + 'zapsmall' + ) + + tokens = { + 'comments': [ + (r'#.*$', Comment.Single), + ], + 'valid_name': [ + (r'[a-zA-Z][\w.]*', Text), + # can begin with ., but not if that is followed by a digit + (r'\.[a-zA-Z_][\w.]*', Text), + ], + 'punctuation': [ + (r'\[{1,2}|\]{1,2}|\(|\)|;|,', Punctuation), + ], + 'keywords': [ + (words(builtins_base, suffix=r'(?![\w. =])'), + Keyword.Pseudo), + (r'(if|else|for|while|repeat|in|next|break|return|switch|function)' + r'(?![\w.])', + Keyword.Reserved), + (r'(array|category|character|complex|double|function|integer|list|' + r'logical|matrix|numeric|vector|data.frame|c)' + r'(?![\w.])', + Keyword.Type), + (r'(library|require|attach|detach|source)' + r'(?![\w.])', + Keyword.Namespace) + ], + 'operators': [ + (r'<>?|-|==|<=|>=|<|>|&&?|!=|\|\|?|\?', Operator), + (r'\*|\+|\^|/|!|%[^%]*%|=|~|\$|@|:{1,3}', Operator) + ], + 'builtin_symbols': [ + (r'(NULL|NA(_(integer|real|complex|character)_)?|' + r'letters|LETTERS|Inf|TRUE|FALSE|NaN|pi|\.\.(\.|[0-9]+))' + r'(?![\w.])', + Keyword.Constant), + (r'(T|F)\b', Name.Builtin.Pseudo), + ], + 'numbers': [ + # hex number + (r'0[xX][a-fA-F0-9]+([pP][0-9]+)?[Li]?', Number.Hex), + # decimal number + (r'[+-]?([0-9]+(\.[0-9]+)?|\.[0-9]+|\.)([eE][+-]?[0-9]+)?[Li]?', + Number), + ], + 'statements': [ + include('comments'), + # whitespaces + (r'\s+', Text), + (r'`.*?`', String.Backtick), + (r'\'', String, 'string_squote'), + (r'\"', String, 'string_dquote'), + include('builtin_symbols'), + include('numbers'), + include('keywords'), + include('punctuation'), + include('operators'), + include('valid_name'), + ], + 'root': [ + include('statements'), + # blocks: + (r'\{|\}', Punctuation), + # (r'\{', Punctuation, 'block'), + (r'.', Text), + ], + # 'block': [ + # include('statements'), + # ('\{', Punctuation, '#push'), + # ('\}', Punctuation, '#pop') + # ], + 'string_squote': [ + (r'([^\'\\]|\\.)*\'', String, '#pop'), + ], + 'string_dquote': [ + (r'([^"\\]|\\.)*"', String, '#pop'), + ], + } + + def analyse_text(text): + if re.search(r'[a-z0-9_\])\s]<-(?!-)', text): + return 0.11 + + +class RdLexer(RegexLexer): + """ + Pygments Lexer for R documentation (Rd) files + + This is a very minimal implementation, highlighting little more + than the macros. A description of Rd syntax is found in `Writing R + Extensions `_ + and `Parsing Rd files `_. + + .. versionadded:: 1.6 + """ + name = 'Rd' + aliases = ['rd'] + filenames = ['*.Rd'] + mimetypes = ['text/x-r-doc'] + + # To account for verbatim / LaTeX-like / and R-like areas + # would require parsing. + tokens = { + 'root': [ + # catch escaped brackets and percent sign + (r'\\[\\{}%]', String.Escape), + # comments + (r'%.*$', Comment), + # special macros with no arguments + (r'\\(?:cr|l?dots|R|tab)\b', Keyword.Constant), + # macros + (r'\\[a-zA-Z]+\b', Keyword), + # special preprocessor macros + (r'^\s*#(?:ifn?def|endif).*\b', Comment.Preproc), + # non-escaped brackets + (r'[{}]', Name.Builtin), + # everything else + (r'[^\\%\n{}]+', Text), + (r'.', Text), + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rdf.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rdf.py new file mode 100644 index 0000000000..292b1ae210 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rdf.py @@ -0,0 +1,99 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.rdf + ~~~~~~~~~~~~~~~~~~~ + + Lexers for semantic web and RDF query languages and markup. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, bygroups, default +from pygments.token import Keyword, Punctuation, String, Number, Operator, \ + Whitespace, Name, Literal, Comment, Text + +__all__ = ['SparqlLexer'] + + +class SparqlLexer(RegexLexer): + """ + Lexer for `SPARQL `_ query language. + + .. versionadded:: 2.0 + """ + name = 'SPARQL' + aliases = ['sparql'] + filenames = ['*.rq', '*.sparql'] + mimetypes = ['application/sparql-query'] + + flags = re.IGNORECASE + + tokens = { + 'root': [ + (r'\s+', Whitespace), + (r'(select|construct|describe|ask|where|filter|group\s+by|minus|' + r'distinct|reduced|from named|from|order\s+by|limit|' + r'offset|bindings|load|clear|drop|create|add|move|copy|' + r'insert\s+data|delete\s+data|delete\s+where|delete|insert|' + r'using named|using|graph|default|named|all|optional|service|' + r'silent|bind|union|not in|in|as|a)', Keyword), + (r'(prefix|base)(\s+)([a-z][\w-]*)(\s*)(\:)', + bygroups(Keyword, Whitespace, Name.Namespace, Whitespace, + Punctuation)), + (r'\?[a-z_]\w*', Name.Variable), + (r'<[^>]+>', Name.Label), + (r'([a-z][\w-]*)(\:)([a-z][\w-]*)', + bygroups(Name.Namespace, Punctuation, Name.Tag)), + (r'(str|lang|langmatches|datatype|bound|iri|uri|bnode|rand|abs|' + r'ceil|floor|round|concat|strlen|ucase|lcase|encode_for_uri|' + r'contains|strstarts|strends|strbefore|strafter|year|month|day|' + r'hours|minutes|seconds|timezone|tz|now|md5|sha1|sha256|sha384|' + r'sha512|coalesce|if|strlang|strdt|sameterm|isiri|isuri|isblank|' + r'isliteral|isnumeric|regex|substr|replace|exists|not exists|' + r'count|sum|min|max|avg|sample|group_concat|separator)\b', + Name.Function), + (r'(true|false)', Literal), + (r'[+\-]?\d*\.\d+', Number.Float), + (r'[+\-]?\d*(:?\.\d+)?E[+\-]?\d+', Number.Float), + (r'[+\-]?\d+', Number.Integer), + (r'(\|\||&&|=|\*|\-|\+|/)', Operator), + (r'[(){}.;,:^]', Punctuation), + (r'#[^\n]+', Comment), + (r'"""', String, 'triple-double-quoted-string'), + (r'"', String, 'single-double-quoted-string'), + (r"'''", String, 'triple-single-quoted-string'), + (r"'", String, 'single-single-quoted-string'), + ], + 'triple-double-quoted-string': [ + (r'"""', String, 'end-of-string'), + (r'[^\\]+', String), + (r'\\', String, 'string-escape'), + ], + 'single-double-quoted-string': [ + (r'"', String, 'end-of-string'), + (r'[^"\\\n]+', String), + (r'\\', String, 'string-escape'), + ], + 'triple-single-quoted-string': [ + (r"'''", String, 'end-of-string'), + (r'[^\\]+', String), + (r'\\', String, 'string-escape'), + ], + 'single-single-quoted-string': [ + (r"'", String, 'end-of-string'), + (r"[^'\\\n]+", String), + (r'\\', String, 'string-escape'), + ], + 'string-escape': [ + (r'.', String, '#pop'), + ], + 'end-of-string': [ + (r'(@)([a-z]+(:?-[a-z0-9]+)*)', + bygroups(Operator, Name.Function), '#pop:2'), + (r'\^\^', Operator, '#pop:2'), + default('#pop:2'), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rebol.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rebol.py new file mode 100644 index 0000000000..8ff97ee267 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rebol.py @@ -0,0 +1,431 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.rebol + ~~~~~~~~~~~~~~~~~~~~~ + + Lexers for the REBOL and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, bygroups +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Generic, Whitespace + +__all__ = ['RebolLexer', 'RedLexer'] + + +class RebolLexer(RegexLexer): + """ + A `REBOL `_ lexer. + + .. versionadded:: 1.1 + """ + name = 'REBOL' + aliases = ['rebol'] + filenames = ['*.r', '*.r3', '*.reb'] + mimetypes = ['text/x-rebol'] + + flags = re.IGNORECASE | re.MULTILINE + + escape_re = r'(?:\^\([0-9a-f]{1,4}\)*)' + + def word_callback(lexer, match): + word = match.group() + + if re.match(".*:$", word): + yield match.start(), Generic.Subheading, word + elif re.match( + r'(native|alias|all|any|as-string|as-binary|bind|bound\?|case|' + r'catch|checksum|comment|debase|dehex|exclude|difference|disarm|' + r'either|else|enbase|foreach|remove-each|form|free|get|get-env|if|' + r'in|intersect|loop|minimum-of|maximum-of|mold|new-line|' + r'new-line\?|not|now|prin|print|reduce|compose|construct|repeat|' + r'reverse|save|script\?|set|shift|switch|throw|to-hex|trace|try|' + r'type\?|union|unique|unless|unprotect|unset|until|use|value\?|' + r'while|compress|decompress|secure|open|close|read|read-io|' + r'write-io|write|update|query|wait|input\?|exp|log-10|log-2|' + r'log-e|square-root|cosine|sine|tangent|arccosine|arcsine|' + r'arctangent|protect|lowercase|uppercase|entab|detab|connected\?|' + r'browse|launch|stats|get-modes|set-modes|to-local-file|' + r'to-rebol-file|encloak|decloak|create-link|do-browser|bind\?|' + r'hide|draw|show|size-text|textinfo|offset-to-caret|' + r'caret-to-offset|local-request-file|rgb-to-hsv|hsv-to-rgb|' + r'crypt-strength\?|dh-make-key|dh-generate-key|dh-compute-key|' + r'dsa-make-key|dsa-generate-key|dsa-make-signature|' + r'dsa-verify-signature|rsa-make-key|rsa-generate-key|' + r'rsa-encrypt)$', word): + yield match.start(), Name.Builtin, word + elif re.match( + r'(add|subtract|multiply|divide|remainder|power|and~|or~|xor~|' + r'minimum|maximum|negate|complement|absolute|random|head|tail|' + r'next|back|skip|at|pick|first|second|third|fourth|fifth|sixth|' + r'seventh|eighth|ninth|tenth|last|path|find|select|make|to|copy\*|' + r'insert|remove|change|poke|clear|trim|sort|min|max|abs|cp|' + r'copy)$', word): + yield match.start(), Name.Function, word + elif re.match( + r'(error|source|input|license|help|install|echo|Usage|with|func|' + r'throw-on-error|function|does|has|context|probe|\?\?|as-pair|' + r'mod|modulo|round|repend|about|set-net|append|join|rejoin|reform|' + r'remold|charset|array|replace|move|extract|forskip|forall|alter|' + r'first+|also|take|for|forever|dispatch|attempt|what-dir|' + r'change-dir|clean-path|list-dir|dirize|rename|split-path|delete|' + r'make-dir|delete-dir|in-dir|confirm|dump-obj|upgrade|what|' + r'build-tag|process-source|build-markup|decode-cgi|read-cgi|' + r'write-user|save-user|set-user-name|protect-system|parse-xml|' + r'cvs-date|cvs-version|do-boot|get-net-info|desktop|layout|' + r'scroll-para|get-face|alert|set-face|uninstall|unfocus|' + r'request-dir|center-face|do-events|net-error|decode-url|' + r'parse-header|parse-header-date|parse-email-addrs|import-email|' + r'send|build-attach-body|resend|show-popup|hide-popup|open-events|' + r'find-key-face|do-face|viewtop|confine|find-window|' + r'insert-event-func|remove-event-func|inform|dump-pane|dump-face|' + r'flag-face|deflag-face|clear-fields|read-net|vbug|path-thru|' + r'read-thru|load-thru|do-thru|launch-thru|load-image|' + r'request-download|do-face-alt|set-font|set-para|get-style|' + r'set-style|make-face|stylize|choose|hilight-text|hilight-all|' + r'unlight-text|focus|scroll-drag|clear-face|reset-face|scroll-face|' + r'resize-face|load-stock|load-stock-block|notify|request|flash|' + r'request-color|request-pass|request-text|request-list|' + r'request-date|request-file|dbug|editor|link-relative-path|' + r'emailer|parse-error)$', word): + yield match.start(), Keyword.Namespace, word + elif re.match( + r'(halt|quit|do|load|q|recycle|call|run|ask|parse|view|unview|' + r'return|exit|break)$', word): + yield match.start(), Name.Exception, word + elif re.match('REBOL$', word): + yield match.start(), Generic.Heading, word + elif re.match("to-.*", word): + yield match.start(), Keyword, word + elif re.match('(\+|-|\*|/|//|\*\*|and|or|xor|=\?|=|==|<>|<|>|<=|>=)$', + word): + yield match.start(), Operator, word + elif re.match(".*\?$", word): + yield match.start(), Keyword, word + elif re.match(".*\!$", word): + yield match.start(), Keyword.Type, word + elif re.match("'.*", word): + yield match.start(), Name.Variable.Instance, word # lit-word + elif re.match("#.*", word): + yield match.start(), Name.Label, word # issue + elif re.match("%.*", word): + yield match.start(), Name.Decorator, word # file + else: + yield match.start(), Name.Variable, word + + tokens = { + 'root': [ + (r'[^R]+', Comment), + (r'REBOL\s+\[', Generic.Strong, 'script'), + (r'R', Comment) + ], + 'script': [ + (r'\s+', Text), + (r'#"', String.Char, 'char'), + (r'#\{[0-9a-f]*\}', Number.Hex), + (r'2#\{', Number.Hex, 'bin2'), + (r'64#\{[0-9a-z+/=\s]*\}', Number.Hex), + (r'"', String, 'string'), + (r'\{', String, 'string2'), + (r';#+.*\n', Comment.Special), + (r';\*+.*\n', Comment.Preproc), + (r';.*\n', Comment), + (r'%"', Name.Decorator, 'stringFile'), + (r'%[^(^{")\s\[\]]+', Name.Decorator), + (r'[+-]?([a-z]{1,3})?\$\d+(\.\d+)?', Number.Float), # money + (r'[+-]?\d+\:\d+(\:\d+)?(\.\d+)?', String.Other), # time + (r'\d+[\-/][0-9a-z]+[\-/]\d+(\/\d+\:\d+((\:\d+)?' + r'([.\d+]?([+-]?\d+:\d+)?)?)?)?', String.Other), # date + (r'\d+(\.\d+)+\.\d+', Keyword.Constant), # tuple + (r'\d+X\d+', Keyword.Constant), # pair + (r'[+-]?\d+(\'\d+)?([.,]\d*)?E[+-]?\d+', Number.Float), + (r'[+-]?\d+(\'\d+)?[.,]\d*', Number.Float), + (r'[+-]?\d+(\'\d+)?', Number), + (r'[\[\]()]', Generic.Strong), + (r'[a-z]+[^(^{"\s:)]*://[^(^{"\s)]*', Name.Decorator), # url + (r'mailto:[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator), # url + (r'[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator), # email + (r'comment\s"', Comment, 'commentString1'), + (r'comment\s\{', Comment, 'commentString2'), + (r'comment\s\[', Comment, 'commentBlock'), + (r'comment\s[^(\s{"\[]+', Comment), + (r'/[^(^{")\s/[\]]*', Name.Attribute), + (r'([^(^{")\s/[\]]+)(?=[:({"\s/\[\]])', word_callback), + (r'<[\w:.-]*>', Name.Tag), + (r'<[^(<>\s")]+', Name.Tag, 'tag'), + (r'([^(^{")\s]+)', Text), + ], + 'string': [ + (r'[^(^")]+', String), + (escape_re, String.Escape), + (r'[(|)]+', String), + (r'\^.', String.Escape), + (r'"', String, '#pop'), + ], + 'string2': [ + (r'[^(^{})]+', String), + (escape_re, String.Escape), + (r'[(|)]+', String), + (r'\^.', String.Escape), + (r'\{', String, '#push'), + (r'\}', String, '#pop'), + ], + 'stringFile': [ + (r'[^(^")]+', Name.Decorator), + (escape_re, Name.Decorator), + (r'\^.', Name.Decorator), + (r'"', Name.Decorator, '#pop'), + ], + 'char': [ + (escape_re + '"', String.Char, '#pop'), + (r'\^."', String.Char, '#pop'), + (r'."', String.Char, '#pop'), + ], + 'tag': [ + (escape_re, Name.Tag), + (r'"', Name.Tag, 'tagString'), + (r'[^(<>\r\n")]+', Name.Tag), + (r'>', Name.Tag, '#pop'), + ], + 'tagString': [ + (r'[^(^")]+', Name.Tag), + (escape_re, Name.Tag), + (r'[(|)]+', Name.Tag), + (r'\^.', Name.Tag), + (r'"', Name.Tag, '#pop'), + ], + 'tuple': [ + (r'(\d+\.)+', Keyword.Constant), + (r'\d+', Keyword.Constant, '#pop'), + ], + 'bin2': [ + (r'\s+', Number.Hex), + (r'([01]\s*){8}', Number.Hex), + (r'\}', Number.Hex, '#pop'), + ], + 'commentString1': [ + (r'[^(^")]+', Comment), + (escape_re, Comment), + (r'[(|)]+', Comment), + (r'\^.', Comment), + (r'"', Comment, '#pop'), + ], + 'commentString2': [ + (r'[^(^{})]+', Comment), + (escape_re, Comment), + (r'[(|)]+', Comment), + (r'\^.', Comment), + (r'\{', Comment, '#push'), + (r'\}', Comment, '#pop'), + ], + 'commentBlock': [ + (r'\[', Comment, '#push'), + (r'\]', Comment, '#pop'), + (r'"', Comment, "commentString1"), + (r'\{', Comment, "commentString2"), + (r'[^(\[\]"{)]+', Comment), + ], + } + + def analyse_text(text): + """ + Check if code contains REBOL header and so it probably not R code + """ + if re.match(r'^\s*REBOL\s*\[', text, re.IGNORECASE): + # The code starts with REBOL header + return 1.0 + elif re.search(r'\s*REBOL\s*[', text, re.IGNORECASE): + # The code contains REBOL header but also some text before it + return 0.5 + + +class RedLexer(RegexLexer): + """ + A `Red-language `_ lexer. + + .. versionadded:: 2.0 + """ + name = 'Red' + aliases = ['red', 'red/system'] + filenames = ['*.red', '*.reds'] + mimetypes = ['text/x-red', 'text/x-red-system'] + + flags = re.IGNORECASE | re.MULTILINE + + escape_re = r'(?:\^\([0-9a-f]{1,4}\)*)' + + def word_callback(lexer, match): + word = match.group() + + if re.match(".*:$", word): + yield match.start(), Generic.Subheading, word + elif re.match(r'(if|unless|either|any|all|while|until|loop|repeat|' + r'foreach|forall|func|function|does|has|switch|' + r'case|reduce|compose|get|set|print|prin|equal\?|' + r'not-equal\?|strict-equal\?|lesser\?|greater\?|lesser-or-equal\?|' + r'greater-or-equal\?|same\?|not|type\?|stats|' + r'bind|union|replace|charset|routine)$', word): + yield match.start(), Name.Builtin, word + elif re.match(r'(make|random|reflect|to|form|mold|absolute|add|divide|multiply|negate|' + r'power|remainder|round|subtract|even\?|odd\?|and~|complement|or~|xor~|' + r'append|at|back|change|clear|copy|find|head|head\?|index\?|insert|' + r'length\?|next|pick|poke|remove|reverse|select|sort|skip|swap|tail|tail\?|' + r'take|trim|create|close|delete|modify|open|open\?|query|read|rename|' + r'update|write)$', word): + yield match.start(), Name.Function, word + elif re.match(r'(yes|on|no|off|true|false|tab|cr|lf|newline|escape|slash|sp|space|null|' + r'none|crlf|dot|null-byte)$', word): + yield match.start(), Name.Builtin.Pseudo, word + elif re.match(r'(#system-global|#include|#enum|#define|#either|#if|#import|#export|' + r'#switch|#default|#get-definition)$', word): + yield match.start(), Keyword.Namespace, word + elif re.match(r'(system|halt|quit|quit-return|do|load|q|recycle|call|run|ask|parse|' + r'raise-error|return|exit|break|alias|push|pop|probe|\?\?|spec-of|body-of|' + r'quote|forever)$', word): + yield match.start(), Name.Exception, word + elif re.match(r'(action\?|block\?|char\?|datatype\?|file\?|function\?|get-path\?|zero\?|' + r'get-word\?|integer\?|issue\?|lit-path\?|lit-word\?|logic\?|native\?|' + r'op\?|paren\?|path\?|refinement\?|set-path\?|set-word\?|string\?|unset\?|' + r'any-struct\?|none\?|word\?|any-series\?)$', word): + yield match.start(), Keyword, word + elif re.match(r'(JNICALL|stdcall|cdecl|infix)$', word): + yield match.start(), Keyword.Namespace, word + elif re.match("to-.*", word): + yield match.start(), Keyword, word + elif re.match('(\+|-\*\*|-|\*\*|//|/|\*|and|or|xor|=\?|===|==|=|<>|<=|>=|' + '<<<|>>>|<<|>>|<|>%)$', word): + yield match.start(), Operator, word + elif re.match(".*\!$", word): + yield match.start(), Keyword.Type, word + elif re.match("'.*", word): + yield match.start(), Name.Variable.Instance, word # lit-word + elif re.match("#.*", word): + yield match.start(), Name.Label, word # issue + elif re.match("%.*", word): + yield match.start(), Name.Decorator, word # file + elif re.match(":.*", word): + yield match.start(), Generic.Subheading, word # get-word + else: + yield match.start(), Name.Variable, word + + tokens = { + 'root': [ + (r'[^R]+', Comment), + (r'Red/System\s+\[', Generic.Strong, 'script'), + (r'Red\s+\[', Generic.Strong, 'script'), + (r'R', Comment) + ], + 'script': [ + (r'\s+', Text), + (r'#"', String.Char, 'char'), + (r'#\{[0-9a-f\s]*\}', Number.Hex), + (r'2#\{', Number.Hex, 'bin2'), + (r'64#\{[0-9a-z+/=\s]*\}', Number.Hex), + (r'([0-9a-f]+)(h)((\s)|(?=[\[\]{}"()]))', + bygroups(Number.Hex, Name.Variable, Whitespace)), + (r'"', String, 'string'), + (r'\{', String, 'string2'), + (r';#+.*\n', Comment.Special), + (r';\*+.*\n', Comment.Preproc), + (r';.*\n', Comment), + (r'%"', Name.Decorator, 'stringFile'), + (r'%[^(^{")\s\[\]]+', Name.Decorator), + (r'[+-]?([a-z]{1,3})?\$\d+(\.\d+)?', Number.Float), # money + (r'[+-]?\d+\:\d+(\:\d+)?(\.\d+)?', String.Other), # time + (r'\d+[\-/][0-9a-z]+[\-/]\d+(/\d+:\d+((:\d+)?' + r'([\.\d+]?([+-]?\d+:\d+)?)?)?)?', String.Other), # date + (r'\d+(\.\d+)+\.\d+', Keyword.Constant), # tuple + (r'\d+X\d+', Keyword.Constant), # pair + (r'[+-]?\d+(\'\d+)?([.,]\d*)?E[+-]?\d+', Number.Float), + (r'[+-]?\d+(\'\d+)?[.,]\d*', Number.Float), + (r'[+-]?\d+(\'\d+)?', Number), + (r'[\[\]()]', Generic.Strong), + (r'[a-z]+[^(^{"\s:)]*://[^(^{"\s)]*', Name.Decorator), # url + (r'mailto:[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator), # url + (r'[^(^{"@\s)]+@[^(^{"@\s)]+', Name.Decorator), # email + (r'comment\s"', Comment, 'commentString1'), + (r'comment\s\{', Comment, 'commentString2'), + (r'comment\s\[', Comment, 'commentBlock'), + (r'comment\s[^(\s{"\[]+', Comment), + (r'/[^(^{^")\s/[\]]*', Name.Attribute), + (r'([^(^{^")\s/[\]]+)(?=[:({"\s/\[\]])', word_callback), + (r'<[\w:.-]*>', Name.Tag), + (r'<[^(<>\s")]+', Name.Tag, 'tag'), + (r'([^(^{")\s]+)', Text), + ], + 'string': [ + (r'[^(^")]+', String), + (escape_re, String.Escape), + (r'[(|)]+', String), + (r'\^.', String.Escape), + (r'"', String, '#pop'), + ], + 'string2': [ + (r'[^(^{})]+', String), + (escape_re, String.Escape), + (r'[(|)]+', String), + (r'\^.', String.Escape), + (r'\{', String, '#push'), + (r'\}', String, '#pop'), + ], + 'stringFile': [ + (r'[^(^")]+', Name.Decorator), + (escape_re, Name.Decorator), + (r'\^.', Name.Decorator), + (r'"', Name.Decorator, '#pop'), + ], + 'char': [ + (escape_re + '"', String.Char, '#pop'), + (r'\^."', String.Char, '#pop'), + (r'."', String.Char, '#pop'), + ], + 'tag': [ + (escape_re, Name.Tag), + (r'"', Name.Tag, 'tagString'), + (r'[^(<>\r\n")]+', Name.Tag), + (r'>', Name.Tag, '#pop'), + ], + 'tagString': [ + (r'[^(^")]+', Name.Tag), + (escape_re, Name.Tag), + (r'[(|)]+', Name.Tag), + (r'\^.', Name.Tag), + (r'"', Name.Tag, '#pop'), + ], + 'tuple': [ + (r'(\d+\.)+', Keyword.Constant), + (r'\d+', Keyword.Constant, '#pop'), + ], + 'bin2': [ + (r'\s+', Number.Hex), + (r'([01]\s*){8}', Number.Hex), + (r'\}', Number.Hex, '#pop'), + ], + 'commentString1': [ + (r'[^(^")]+', Comment), + (escape_re, Comment), + (r'[(|)]+', Comment), + (r'\^.', Comment), + (r'"', Comment, '#pop'), + ], + 'commentString2': [ + (r'[^(^{})]+', Comment), + (escape_re, Comment), + (r'[(|)]+', Comment), + (r'\^.', Comment), + (r'\{', Comment, '#push'), + (r'\}', Comment, '#pop'), + ], + 'commentBlock': [ + (r'\[', Comment, '#push'), + (r'\]', Comment, '#pop'), + (r'"', Comment, "commentString1"), + (r'\{', Comment, "commentString2"), + (r'[^(\[\]"{)]+', Comment), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/resource.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/resource.py new file mode 100644 index 0000000000..6a0da2fa5f --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/resource.py @@ -0,0 +1,84 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.resource + ~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexer for resource definition files. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, bygroups, words +from pygments.token import Comment, String, Number, Operator, Text, \ + Keyword, Name + +__all__ = ['ResourceLexer'] + + +class ResourceLexer(RegexLexer): + """Lexer for `ICU Resource bundles + `_. + + .. versionadded:: 2.0 + """ + name = 'ResourceBundle' + aliases = ['resource', 'resourcebundle'] + filenames = ['*.txt'] + + _types = (':table', ':array', ':string', ':bin', ':import', ':intvector', + ':int', ':alias') + + flags = re.MULTILINE | re.IGNORECASE + tokens = { + 'root': [ + (r'//.*?$', Comment), + (r'"', String, 'string'), + (r'-?\d+', Number.Integer), + (r'[,{}]', Operator), + (r'([^\s{:]+)(\s*)(%s?)' % '|'.join(_types), + bygroups(Name, Text, Keyword)), + (r'\s+', Text), + (words(_types), Keyword), + ], + 'string': [ + (r'(\\x[0-9a-f]{2}|\\u[0-9a-f]{4}|\\U00[0-9a-f]{6}|' + r'\\[0-7]{1,3}|\\c.|\\[abtnvfre\'"?\\]|\\\{|[^"{\\])+', String), + (r'\{', String.Escape, 'msgname'), + (r'"', String, '#pop') + ], + 'msgname': [ + (r'([^{},]+)(\s*)', bygroups(Name, String.Escape), ('#pop', 'message')) + ], + 'message': [ + (r'\{', String.Escape, 'msgname'), + (r'\}', String.Escape, '#pop'), + (r'(,)(\s*)([a-z]+)(\s*\})', + bygroups(Operator, String.Escape, Keyword, String.Escape), '#pop'), + (r'(,)(\s*)([a-z]+)(\s*)(,)(\s*)(offset)(\s*)(:)(\s*)(-?\d+)(\s*)', + bygroups(Operator, String.Escape, Keyword, String.Escape, Operator, + String.Escape, Operator.Word, String.Escape, Operator, + String.Escape, Number.Integer, String.Escape), 'choice'), + (r'(,)(\s*)([a-z]+)(\s*)(,)(\s*)', + bygroups(Operator, String.Escape, Keyword, String.Escape, Operator, + String.Escape), 'choice'), + (r'\s+', String.Escape) + ], + 'choice': [ + (r'(=|<|>|<=|>=|!=)(-?\d+)(\s*\{)', + bygroups(Operator, Number.Integer, String.Escape), 'message'), + (r'([a-z]+)(\s*\{)', bygroups(Keyword.Type, String.Escape), 'str'), + (r'\}', String.Escape, ('#pop', '#pop')), + (r'\s+', String.Escape) + ], + 'str': [ + (r'\}', String.Escape, '#pop'), + (r'\{', String.Escape, 'msgname'), + (r'[^{}]+', String) + ] + } + + def analyse_text(text): + return text.startswith('root:table') diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/robotframework.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/robotframework.py new file mode 100644 index 0000000000..7b6f55643e --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/robotframework.py @@ -0,0 +1,560 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.robotframework + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexer for Robot Framework. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +# Copyright 2012 Nokia Siemens Networks Oyj +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import re + +from pygments.lexer import Lexer +from pygments.token import Token +from pygments.util import text_type + +__all__ = ['RobotFrameworkLexer'] + + +HEADING = Token.Generic.Heading +SETTING = Token.Keyword.Namespace +IMPORT = Token.Name.Namespace +TC_KW_NAME = Token.Generic.Subheading +KEYWORD = Token.Name.Function +ARGUMENT = Token.String +VARIABLE = Token.Name.Variable +COMMENT = Token.Comment +SEPARATOR = Token.Punctuation +SYNTAX = Token.Punctuation +GHERKIN = Token.Generic.Emph +ERROR = Token.Error + + +def normalize(string, remove=''): + string = string.lower() + for char in remove + ' ': + if char in string: + string = string.replace(char, '') + return string + + +class RobotFrameworkLexer(Lexer): + """ + For `Robot Framework `_ test data. + + Supports both space and pipe separated plain text formats. + + .. versionadded:: 1.6 + """ + name = 'RobotFramework' + aliases = ['robotframework'] + filenames = ['*.txt', '*.robot'] + mimetypes = ['text/x-robotframework'] + + def __init__(self, **options): + options['tabsize'] = 2 + options['encoding'] = 'UTF-8' + Lexer.__init__(self, **options) + + def get_tokens_unprocessed(self, text): + row_tokenizer = RowTokenizer() + var_tokenizer = VariableTokenizer() + index = 0 + for row in text.splitlines(): + for value, token in row_tokenizer.tokenize(row): + for value, token in var_tokenizer.tokenize(value, token): + if value: + yield index, token, text_type(value) + index += len(value) + + +class VariableTokenizer(object): + + def tokenize(self, string, token): + var = VariableSplitter(string, identifiers='$@%') + if var.start < 0 or token in (COMMENT, ERROR): + yield string, token + return + for value, token in self._tokenize(var, string, token): + if value: + yield value, token + + def _tokenize(self, var, string, orig_token): + before = string[:var.start] + yield before, orig_token + yield var.identifier + '{', SYNTAX + for value, token in self.tokenize(var.base, VARIABLE): + yield value, token + yield '}', SYNTAX + if var.index: + yield '[', SYNTAX + for value, token in self.tokenize(var.index, VARIABLE): + yield value, token + yield ']', SYNTAX + for value, token in self.tokenize(string[var.end:], orig_token): + yield value, token + + +class RowTokenizer(object): + + def __init__(self): + self._table = UnknownTable() + self._splitter = RowSplitter() + testcases = TestCaseTable() + settings = SettingTable(testcases.set_default_template) + variables = VariableTable() + keywords = KeywordTable() + self._tables = {'settings': settings, 'setting': settings, + 'metadata': settings, + 'variables': variables, 'variable': variables, + 'testcases': testcases, 'testcase': testcases, + 'keywords': keywords, 'keyword': keywords, + 'userkeywords': keywords, 'userkeyword': keywords} + + def tokenize(self, row): + commented = False + heading = False + for index, value in enumerate(self._splitter.split(row)): + # First value, and every second after that, is a separator. + index, separator = divmod(index-1, 2) + if value.startswith('#'): + commented = True + elif index == 0 and value.startswith('*'): + self._table = self._start_table(value) + heading = True + for value, token in self._tokenize(value, index, commented, + separator, heading): + yield value, token + self._table.end_row() + + def _start_table(self, header): + name = normalize(header, remove='*') + return self._tables.get(name, UnknownTable()) + + def _tokenize(self, value, index, commented, separator, heading): + if commented: + yield value, COMMENT + elif separator: + yield value, SEPARATOR + elif heading: + yield value, HEADING + else: + for value, token in self._table.tokenize(value, index): + yield value, token + + +class RowSplitter(object): + _space_splitter = re.compile('( {2,})') + _pipe_splitter = re.compile('((?:^| +)\|(?: +|$))') + + def split(self, row): + splitter = (row.startswith('| ') and self._split_from_pipes + or self._split_from_spaces) + for value in splitter(row): + yield value + yield '\n' + + def _split_from_spaces(self, row): + yield '' # Start with (pseudo)separator similarly as with pipes + for value in self._space_splitter.split(row): + yield value + + def _split_from_pipes(self, row): + _, separator, rest = self._pipe_splitter.split(row, 1) + yield separator + while self._pipe_splitter.search(rest): + cell, separator, rest = self._pipe_splitter.split(rest, 1) + yield cell + yield separator + yield rest + + +class Tokenizer(object): + _tokens = None + + def __init__(self): + self._index = 0 + + def tokenize(self, value): + values_and_tokens = self._tokenize(value, self._index) + self._index += 1 + if isinstance(values_and_tokens, type(Token)): + values_and_tokens = [(value, values_and_tokens)] + return values_and_tokens + + def _tokenize(self, value, index): + index = min(index, len(self._tokens) - 1) + return self._tokens[index] + + def _is_assign(self, value): + if value.endswith('='): + value = value[:-1].strip() + var = VariableSplitter(value, identifiers='$@') + return var.start == 0 and var.end == len(value) + + +class Comment(Tokenizer): + _tokens = (COMMENT,) + + +class Setting(Tokenizer): + _tokens = (SETTING, ARGUMENT) + _keyword_settings = ('suitesetup', 'suiteprecondition', 'suiteteardown', + 'suitepostcondition', 'testsetup', 'testprecondition', + 'testteardown', 'testpostcondition', 'testtemplate') + _import_settings = ('library', 'resource', 'variables') + _other_settings = ('documentation', 'metadata', 'forcetags', 'defaulttags', + 'testtimeout') + _custom_tokenizer = None + + def __init__(self, template_setter=None): + Tokenizer.__init__(self) + self._template_setter = template_setter + + def _tokenize(self, value, index): + if index == 1 and self._template_setter: + self._template_setter(value) + if index == 0: + normalized = normalize(value) + if normalized in self._keyword_settings: + self._custom_tokenizer = KeywordCall(support_assign=False) + elif normalized in self._import_settings: + self._custom_tokenizer = ImportSetting() + elif normalized not in self._other_settings: + return ERROR + elif self._custom_tokenizer: + return self._custom_tokenizer.tokenize(value) + return Tokenizer._tokenize(self, value, index) + + +class ImportSetting(Tokenizer): + _tokens = (IMPORT, ARGUMENT) + + +class TestCaseSetting(Setting): + _keyword_settings = ('setup', 'precondition', 'teardown', 'postcondition', + 'template') + _import_settings = () + _other_settings = ('documentation', 'tags', 'timeout') + + def _tokenize(self, value, index): + if index == 0: + type = Setting._tokenize(self, value[1:-1], index) + return [('[', SYNTAX), (value[1:-1], type), (']', SYNTAX)] + return Setting._tokenize(self, value, index) + + +class KeywordSetting(TestCaseSetting): + _keyword_settings = ('teardown',) + _other_settings = ('documentation', 'arguments', 'return', 'timeout') + + +class Variable(Tokenizer): + _tokens = (SYNTAX, ARGUMENT) + + def _tokenize(self, value, index): + if index == 0 and not self._is_assign(value): + return ERROR + return Tokenizer._tokenize(self, value, index) + + +class KeywordCall(Tokenizer): + _tokens = (KEYWORD, ARGUMENT) + + def __init__(self, support_assign=True): + Tokenizer.__init__(self) + self._keyword_found = not support_assign + self._assigns = 0 + + def _tokenize(self, value, index): + if not self._keyword_found and self._is_assign(value): + self._assigns += 1 + return SYNTAX # VariableTokenizer tokenizes this later. + if self._keyword_found: + return Tokenizer._tokenize(self, value, index - self._assigns) + self._keyword_found = True + return GherkinTokenizer().tokenize(value, KEYWORD) + + +class GherkinTokenizer(object): + _gherkin_prefix = re.compile('^(Given|When|Then|And) ', re.IGNORECASE) + + def tokenize(self, value, token): + match = self._gherkin_prefix.match(value) + if not match: + return [(value, token)] + end = match.end() + return [(value[:end], GHERKIN), (value[end:], token)] + + +class TemplatedKeywordCall(Tokenizer): + _tokens = (ARGUMENT,) + + +class ForLoop(Tokenizer): + + def __init__(self): + Tokenizer.__init__(self) + self._in_arguments = False + + def _tokenize(self, value, index): + token = self._in_arguments and ARGUMENT or SYNTAX + if value.upper() in ('IN', 'IN RANGE'): + self._in_arguments = True + return token + + +class _Table(object): + _tokenizer_class = None + + def __init__(self, prev_tokenizer=None): + self._tokenizer = self._tokenizer_class() + self._prev_tokenizer = prev_tokenizer + self._prev_values_on_row = [] + + def tokenize(self, value, index): + if self._continues(value, index): + self._tokenizer = self._prev_tokenizer + yield value, SYNTAX + else: + for value_and_token in self._tokenize(value, index): + yield value_and_token + self._prev_values_on_row.append(value) + + def _continues(self, value, index): + return value == '...' and all(self._is_empty(t) + for t in self._prev_values_on_row) + + def _is_empty(self, value): + return value in ('', '\\') + + def _tokenize(self, value, index): + return self._tokenizer.tokenize(value) + + def end_row(self): + self.__init__(prev_tokenizer=self._tokenizer) + + +class UnknownTable(_Table): + _tokenizer_class = Comment + + def _continues(self, value, index): + return False + + +class VariableTable(_Table): + _tokenizer_class = Variable + + +class SettingTable(_Table): + _tokenizer_class = Setting + + def __init__(self, template_setter, prev_tokenizer=None): + _Table.__init__(self, prev_tokenizer) + self._template_setter = template_setter + + def _tokenize(self, value, index): + if index == 0 and normalize(value) == 'testtemplate': + self._tokenizer = Setting(self._template_setter) + return _Table._tokenize(self, value, index) + + def end_row(self): + self.__init__(self._template_setter, prev_tokenizer=self._tokenizer) + + +class TestCaseTable(_Table): + _setting_class = TestCaseSetting + _test_template = None + _default_template = None + + @property + def _tokenizer_class(self): + if self._test_template or (self._default_template and + self._test_template is not False): + return TemplatedKeywordCall + return KeywordCall + + def _continues(self, value, index): + return index > 0 and _Table._continues(self, value, index) + + def _tokenize(self, value, index): + if index == 0: + if value: + self._test_template = None + return GherkinTokenizer().tokenize(value, TC_KW_NAME) + if index == 1 and self._is_setting(value): + if self._is_template(value): + self._test_template = False + self._tokenizer = self._setting_class(self.set_test_template) + else: + self._tokenizer = self._setting_class() + if index == 1 and self._is_for_loop(value): + self._tokenizer = ForLoop() + if index == 1 and self._is_empty(value): + return [(value, SYNTAX)] + return _Table._tokenize(self, value, index) + + def _is_setting(self, value): + return value.startswith('[') and value.endswith(']') + + def _is_template(self, value): + return normalize(value) == '[template]' + + def _is_for_loop(self, value): + return value.startswith(':') and normalize(value, remove=':') == 'for' + + def set_test_template(self, template): + self._test_template = self._is_template_set(template) + + def set_default_template(self, template): + self._default_template = self._is_template_set(template) + + def _is_template_set(self, template): + return normalize(template) not in ('', '\\', 'none', '${empty}') + + +class KeywordTable(TestCaseTable): + _tokenizer_class = KeywordCall + _setting_class = KeywordSetting + + def _is_template(self, value): + return False + + +# Following code copied directly from Robot Framework 2.7.5. + +class VariableSplitter: + + def __init__(self, string, identifiers): + self.identifier = None + self.base = None + self.index = None + self.start = -1 + self.end = -1 + self._identifiers = identifiers + self._may_have_internal_variables = False + try: + self._split(string) + except ValueError: + pass + else: + self._finalize() + + def get_replaced_base(self, variables): + if self._may_have_internal_variables: + return variables.replace_string(self.base) + return self.base + + def _finalize(self): + self.identifier = self._variable_chars[0] + self.base = ''.join(self._variable_chars[2:-1]) + self.end = self.start + len(self._variable_chars) + if self._has_list_variable_index(): + self.index = ''.join(self._list_variable_index_chars[1:-1]) + self.end += len(self._list_variable_index_chars) + + def _has_list_variable_index(self): + return self._list_variable_index_chars\ + and self._list_variable_index_chars[-1] == ']' + + def _split(self, string): + start_index, max_index = self._find_variable(string) + self.start = start_index + self._open_curly = 1 + self._state = self._variable_state + self._variable_chars = [string[start_index], '{'] + self._list_variable_index_chars = [] + self._string = string + start_index += 2 + for index, char in enumerate(string[start_index:]): + index += start_index # Giving start to enumerate only in Py 2.6+ + try: + self._state(char, index) + except StopIteration: + return + if index == max_index and not self._scanning_list_variable_index(): + return + + def _scanning_list_variable_index(self): + return self._state in [self._waiting_list_variable_index_state, + self._list_variable_index_state] + + def _find_variable(self, string): + max_end_index = string.rfind('}') + if max_end_index == -1: + raise ValueError('No variable end found') + if self._is_escaped(string, max_end_index): + return self._find_variable(string[:max_end_index]) + start_index = self._find_start_index(string, 1, max_end_index) + if start_index == -1: + raise ValueError('No variable start found') + return start_index, max_end_index + + def _find_start_index(self, string, start, end): + index = string.find('{', start, end) - 1 + if index < 0: + return -1 + if self._start_index_is_ok(string, index): + return index + return self._find_start_index(string, index+2, end) + + def _start_index_is_ok(self, string, index): + return string[index] in self._identifiers\ + and not self._is_escaped(string, index) + + def _is_escaped(self, string, index): + escaped = False + while index > 0 and string[index-1] == '\\': + index -= 1 + escaped = not escaped + return escaped + + def _variable_state(self, char, index): + self._variable_chars.append(char) + if char == '}' and not self._is_escaped(self._string, index): + self._open_curly -= 1 + if self._open_curly == 0: + if not self._is_list_variable(): + raise StopIteration + self._state = self._waiting_list_variable_index_state + elif char in self._identifiers: + self._state = self._internal_variable_start_state + + def _is_list_variable(self): + return self._variable_chars[0] == '@' + + def _internal_variable_start_state(self, char, index): + self._state = self._variable_state + if char == '{': + self._variable_chars.append(char) + self._open_curly += 1 + self._may_have_internal_variables = True + else: + self._variable_state(char, index) + + def _waiting_list_variable_index_state(self, char, index): + if char != '[': + raise StopIteration + self._list_variable_index_chars.append(char) + self._state = self._list_variable_index_state + + def _list_variable_index_state(self, char, index): + self._list_variable_index_chars.append(char) + if char == ']': + raise StopIteration diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ruby.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ruby.py new file mode 100644 index 0000000000..d346df94cc --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/ruby.py @@ -0,0 +1,518 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.ruby + ~~~~~~~~~~~~~~~~~~~~ + + Lexers for Ruby and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, ExtendedRegexLexer, include, \ + bygroups, default, LexerContext, do_insertions, words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error, Generic +from pygments.util import shebang_matches + +__all__ = ['RubyLexer', 'RubyConsoleLexer', 'FancyLexer'] + +line_re = re.compile('.*?\n') + + +RUBY_OPERATORS = ( + '*', '**', '-', '+', '-@', '+@', '/', '%', '&', '|', '^', '`', '~', + '[]', '[]=', '<<', '>>', '<', '<>', '<=>', '>', '>=', '==', '===' +) + + +class RubyLexer(ExtendedRegexLexer): + """ + For `Ruby `_ source code. + """ + + name = 'Ruby' + aliases = ['rb', 'ruby', 'duby'] + filenames = ['*.rb', '*.rbw', 'Rakefile', '*.rake', '*.gemspec', + '*.rbx', '*.duby'] + mimetypes = ['text/x-ruby', 'application/x-ruby'] + + flags = re.DOTALL | re.MULTILINE + + def heredoc_callback(self, match, ctx): + # okay, this is the hardest part of parsing Ruby... + # match: 1 = <<-?, 2 = quote? 3 = name 4 = quote? 5 = rest of line + + start = match.start(1) + yield start, Operator, match.group(1) # <<-? + yield match.start(2), String.Heredoc, match.group(2) # quote ", ', ` + yield match.start(3), Name.Constant, match.group(3) # heredoc name + yield match.start(4), String.Heredoc, match.group(4) # quote again + + heredocstack = ctx.__dict__.setdefault('heredocstack', []) + outermost = not bool(heredocstack) + heredocstack.append((match.group(1) == '<<-', match.group(3))) + + ctx.pos = match.start(5) + ctx.end = match.end(5) + # this may find other heredocs + for i, t, v in self.get_tokens_unprocessed(context=ctx): + yield i, t, v + ctx.pos = match.end() + + if outermost: + # this is the outer heredoc again, now we can process them all + for tolerant, hdname in heredocstack: + lines = [] + for match in line_re.finditer(ctx.text, ctx.pos): + if tolerant: + check = match.group().strip() + else: + check = match.group().rstrip() + if check == hdname: + for amatch in lines: + yield amatch.start(), String.Heredoc, amatch.group() + yield match.start(), Name.Constant, match.group() + ctx.pos = match.end() + break + else: + lines.append(match) + else: + # end of heredoc not found -- error! + for amatch in lines: + yield amatch.start(), Error, amatch.group() + ctx.end = len(ctx.text) + del heredocstack[:] + + def gen_rubystrings_rules(): + def intp_regex_callback(self, match, ctx): + yield match.start(1), String.Regex, match.group(1) # begin + nctx = LexerContext(match.group(3), 0, ['interpolated-regex']) + for i, t, v in self.get_tokens_unprocessed(context=nctx): + yield match.start(3)+i, t, v + yield match.start(4), String.Regex, match.group(4) # end[mixounse]* + ctx.pos = match.end() + + def intp_string_callback(self, match, ctx): + yield match.start(1), String.Other, match.group(1) + nctx = LexerContext(match.group(3), 0, ['interpolated-string']) + for i, t, v in self.get_tokens_unprocessed(context=nctx): + yield match.start(3)+i, t, v + yield match.start(4), String.Other, match.group(4) # end + ctx.pos = match.end() + + states = {} + states['strings'] = [ + # easy ones + (r'\:@{0,2}[a-zA-Z_]\w*[!?]?', String.Symbol), + (words(RUBY_OPERATORS, prefix=r'\:@{0,2}'), String.Symbol), + (r":'(\\\\|\\'|[^'])*'", String.Symbol), + (r"'(\\\\|\\'|[^'])*'", String.Single), + (r':"', String.Symbol, 'simple-sym'), + (r'([a-zA-Z_]\w*)(:)(?!:)', + bygroups(String.Symbol, Punctuation)), # Since Ruby 1.9 + (r'"', String.Double, 'simple-string'), + (r'(?', '<>', 'ab'): + states[name+'-intp-string'] = [ + (r'\\[\\' + bracecc + ']', String.Other), + (lbrace, String.Other, '#push'), + (rbrace, String.Other, '#pop'), + include('string-intp-escaped'), + (r'[\\#' + bracecc + ']', String.Other), + (r'[^\\#' + bracecc + ']+', String.Other), + ] + states['strings'].append((r'%[QWx]?' + lbrace, String.Other, + name+'-intp-string')) + states[name+'-string'] = [ + (r'\\[\\' + bracecc + ']', String.Other), + (lbrace, String.Other, '#push'), + (rbrace, String.Other, '#pop'), + (r'[\\#' + bracecc + ']', String.Other), + (r'[^\\#' + bracecc + ']+', String.Other), + ] + states['strings'].append((r'%[qsw]' + lbrace, String.Other, + name+'-string')) + states[name+'-regex'] = [ + (r'\\[\\' + bracecc + ']', String.Regex), + (lbrace, String.Regex, '#push'), + (rbrace + '[mixounse]*', String.Regex, '#pop'), + include('string-intp'), + (r'[\\#' + bracecc + ']', String.Regex), + (r'[^\\#' + bracecc + ']+', String.Regex), + ] + states['strings'].append((r'%r' + lbrace, String.Regex, + name+'-regex')) + + # these must come after %! + states['strings'] += [ + # %r regex + (r'(%r([\W_]))((?:\\\2|(?!\2).)*)(\2[mixounse]*)', + intp_regex_callback), + # regular fancy strings with qsw + (r'%[qsw]([\W_])((?:\\\1|(?!\1).)*)\1', String.Other), + (r'(%[QWx]([\W_]))((?:\\\2|(?!\2).)*)(\2)', + intp_string_callback), + # special forms of fancy strings after operators or + # in method calls with braces + (r'(?<=[-+/*%=<>&!^|~,(])(\s*)(%([\t ])(?:(?:\\\3|(?!\3).)*)\3)', + bygroups(Text, String.Other, None)), + # and because of fixed width lookbehinds the whole thing a + # second time for line startings... + (r'^(\s*)(%([\t ])(?:(?:\\\3|(?!\3).)*)\3)', + bygroups(Text, String.Other, None)), + # all regular fancy strings without qsw + (r'(%([^a-zA-Z0-9\s]))((?:\\\2|(?!\2).)*)(\2)', + intp_string_callback), + ] + + return states + + tokens = { + 'root': [ + (r'#.*?$', Comment.Single), + (r'=begin\s.*?\n=end.*?$', Comment.Multiline), + # keywords + (words(( + 'BEGIN', 'END', 'alias', 'begin', 'break', 'case', 'defined?', + 'do', 'else', 'elsif', 'end', 'ensure', 'for', 'if', 'in', 'next', 'redo', + 'rescue', 'raise', 'retry', 'return', 'super', 'then', 'undef', + 'unless', 'until', 'when', 'while', 'yield'), suffix=r'\b'), + Keyword), + # start of function, class and module names + (r'(module)(\s+)([a-zA-Z_]\w*' + r'(?:::[a-zA-Z_]\w*)*)', + bygroups(Keyword, Text, Name.Namespace)), + (r'(def)(\s+)', bygroups(Keyword, Text), 'funcname'), + (r'def(?=[*%&^`~+-/\[<>=])', Keyword, 'funcname'), + (r'(class)(\s+)', bygroups(Keyword, Text), 'classname'), + # special methods + (words(( + 'initialize', 'new', 'loop', 'include', 'extend', 'raise', 'attr_reader', + 'attr_writer', 'attr_accessor', 'attr', 'catch', 'throw', 'private', + 'module_function', 'public', 'protected', 'true', 'false', 'nil'), + suffix=r'\b'), + Keyword.Pseudo), + (r'(not|and|or)\b', Operator.Word), + (words(( + 'autoload', 'block_given', 'const_defined', 'eql', 'equal', 'frozen', 'include', + 'instance_of', 'is_a', 'iterator', 'kind_of', 'method_defined', 'nil', + 'private_method_defined', 'protected_method_defined', + 'public_method_defined', 'respond_to', 'tainted'), suffix=r'\?'), + Name.Builtin), + (r'(chomp|chop|exit|gsub|sub)!', Name.Builtin), + (words(( + 'Array', 'Float', 'Integer', 'String', '__id__', '__send__', 'abort', + 'ancestors', 'at_exit', 'autoload', 'binding', 'callcc', 'caller', + 'catch', 'chomp', 'chop', 'class_eval', 'class_variables', + 'clone', 'const_defined?', 'const_get', 'const_missing', 'const_set', + 'constants', 'display', 'dup', 'eval', 'exec', 'exit', 'extend', 'fail', 'fork', + 'format', 'freeze', 'getc', 'gets', 'global_variables', 'gsub', + 'hash', 'id', 'included_modules', 'inspect', 'instance_eval', + 'instance_method', 'instance_methods', + 'instance_variable_get', 'instance_variable_set', 'instance_variables', + 'lambda', 'load', 'local_variables', 'loop', + 'method', 'method_missing', 'methods', 'module_eval', 'name', + 'object_id', 'open', 'p', 'print', 'printf', 'private_class_method', + 'private_instance_methods', + 'private_methods', 'proc', 'protected_instance_methods', + 'protected_methods', 'public_class_method', + 'public_instance_methods', 'public_methods', + 'putc', 'puts', 'raise', 'rand', 'readline', 'readlines', 'require', + 'scan', 'select', 'self', 'send', 'set_trace_func', 'singleton_methods', 'sleep', + 'split', 'sprintf', 'srand', 'sub', 'syscall', 'system', 'taint', + 'test', 'throw', 'to_a', 'to_s', 'trace_var', 'trap', 'untaint', + 'untrace_var', 'warn'), prefix=r'(?~!:])|' + r'(?<=(?:\s|;)when\s)|' + r'(?<=(?:\s|;)or\s)|' + r'(?<=(?:\s|;)and\s)|' + r'(?<=(?:\s|;|\.)index\s)|' + r'(?<=(?:\s|;|\.)scan\s)|' + r'(?<=(?:\s|;|\.)sub\s)|' + r'(?<=(?:\s|;|\.)sub!\s)|' + r'(?<=(?:\s|;|\.)gsub\s)|' + r'(?<=(?:\s|;|\.)gsub!\s)|' + r'(?<=(?:\s|;|\.)match\s)|' + r'(?<=(?:\s|;)if\s)|' + r'(?<=(?:\s|;)elsif\s)|' + r'(?<=^when\s)|' + r'(?<=^index\s)|' + r'(?<=^scan\s)|' + r'(?<=^sub\s)|' + r'(?<=^gsub\s)|' + r'(?<=^sub!\s)|' + r'(?<=^gsub!\s)|' + r'(?<=^match\s)|' + r'(?<=^if\s)|' + r'(?<=^elsif\s)' + r')(\s*)(/)', bygroups(Text, String.Regex), 'multiline-regex'), + # multiline regex (in method calls or subscripts) + (r'(?<=\(|,|\[)/', String.Regex, 'multiline-regex'), + # multiline regex (this time the funny no whitespace rule) + (r'(\s+)(/)(?![\s=])', bygroups(Text, String.Regex), + 'multiline-regex'), + # lex numbers and ignore following regular expressions which + # are division operators in fact (grrrr. i hate that. any + # better ideas?) + # since pygments 0.7 we also eat a "?" operator after numbers + # so that the char operator does not work. Chars are not allowed + # there so that you can use the ternary operator. + # stupid example: + # x>=0?n[x]:"" + (r'(0_?[0-7]+(?:_[0-7]+)*)(\s*)([/?])?', + bygroups(Number.Oct, Text, Operator)), + (r'(0x[0-9A-Fa-f]+(?:_[0-9A-Fa-f]+)*)(\s*)([/?])?', + bygroups(Number.Hex, Text, Operator)), + (r'(0b[01]+(?:_[01]+)*)(\s*)([/?])?', + bygroups(Number.Bin, Text, Operator)), + (r'([\d]+(?:_\d+)*)(\s*)([/?])?', + bygroups(Number.Integer, Text, Operator)), + # Names + (r'@@[a-zA-Z_]\w*', Name.Variable.Class), + (r'@[a-zA-Z_]\w*', Name.Variable.Instance), + (r'\$\w+', Name.Variable.Global), + (r'\$[!@&`\'+~=/\\,;.<>_*$?:"^-]', Name.Variable.Global), + (r'\$-[0adFiIlpvw]', Name.Variable.Global), + (r'::', Operator), + include('strings'), + # chars + (r'\?(\\[MC]-)*' # modifiers + r'(\\([\\abefnrstv#"\']|x[a-fA-F0-9]{1,2}|[0-7]{1,3})|\S)' + r'(?!\w)', + String.Char), + (r'[A-Z]\w+', Name.Constant), + # this is needed because ruby attributes can look + # like keywords (class) or like this: ` ?!? + (words(RUBY_OPERATORS, prefix=r'(\.|::)'), + bygroups(Operator, Name.Operator)), + (r'(\.|::)([a-zA-Z_]\w*[!?]?|[*%&^`~+\-/\[<>=])', + bygroups(Operator, Name)), + (r'[a-zA-Z_]\w*[!?]?', Name), + (r'(\[|\]|\*\*|<>?|>=|<=|<=>|=~|={3}|' + r'!~|&&?|\|\||\.{1,3})', Operator), + (r'[-+/*%=<>&!^|~]=?', Operator), + (r'[(){};,/?:\\]', Punctuation), + (r'\s+', Text) + ], + 'funcname': [ + (r'\(', Punctuation, 'defexpr'), + (r'(?:([a-zA-Z_]\w*)(\.))?' + r'([a-zA-Z_]\w*[!?]?|\*\*?|[-+]@?|' + r'[/%&|^`~]|\[\]=?|<<|>>|<=?>|>=?|===?)', + bygroups(Name.Class, Operator, Name.Function), '#pop'), + default('#pop') + ], + 'classname': [ + (r'\(', Punctuation, 'defexpr'), + (r'<<', Operator, '#pop'), + (r'[A-Z_]\w*', Name.Class, '#pop'), + default('#pop') + ], + 'defexpr': [ + (r'(\))(\.|::)?', bygroups(Punctuation, Operator), '#pop'), + (r'\(', Operator, '#push'), + include('root') + ], + 'in-intp': [ + (r'\{', String.Interpol, '#push'), + (r'\}', String.Interpol, '#pop'), + include('root'), + ], + 'string-intp': [ + (r'#\{', String.Interpol, 'in-intp'), + (r'#@@?[a-zA-Z_]\w*', String.Interpol), + (r'#\$[a-zA-Z_]\w*', String.Interpol) + ], + 'string-intp-escaped': [ + include('string-intp'), + (r'\\([\\abefnrstv#"\']|x[a-fA-F0-9]{1,2}|[0-7]{1,3})', + String.Escape) + ], + 'interpolated-regex': [ + include('string-intp'), + (r'[\\#]', String.Regex), + (r'[^\\#]+', String.Regex), + ], + 'interpolated-string': [ + include('string-intp'), + (r'[\\#]', String.Other), + (r'[^\\#]+', String.Other), + ], + 'multiline-regex': [ + include('string-intp'), + (r'\\\\', String.Regex), + (r'\\/', String.Regex), + (r'[\\#]', String.Regex), + (r'[^\\/#]+', String.Regex), + (r'/[mixounse]*', String.Regex, '#pop'), + ], + 'end-part': [ + (r'.+', Comment.Preproc, '#pop') + ] + } + tokens.update(gen_rubystrings_rules()) + + def analyse_text(text): + return shebang_matches(text, r'ruby(1\.\d)?') + + +class RubyConsoleLexer(Lexer): + """ + For Ruby interactive console (**irb**) output like: + + .. sourcecode:: rbcon + + irb(main):001:0> a = 1 + => 1 + irb(main):002:0> puts a + 1 + => nil + """ + name = 'Ruby irb session' + aliases = ['rbcon', 'irb'] + mimetypes = ['text/x-ruby-shellsession'] + + _prompt_re = re.compile('irb\([a-zA-Z_]\w*\):\d{3}:\d+[>*"\'] ' + '|>> |\?> ') + + def get_tokens_unprocessed(self, text): + rblexer = RubyLexer(**self.options) + + curcode = '' + insertions = [] + for match in line_re.finditer(text): + line = match.group() + m = self._prompt_re.match(line) + if m is not None: + end = m.end() + insertions.append((len(curcode), + [(0, Generic.Prompt, line[:end])])) + curcode += line[end:] + else: + if curcode: + for item in do_insertions( + insertions, rblexer.get_tokens_unprocessed(curcode)): + yield item + curcode = '' + insertions = [] + yield match.start(), Generic.Output, line + if curcode: + for item in do_insertions( + insertions, rblexer.get_tokens_unprocessed(curcode)): + yield item + + +class FancyLexer(RegexLexer): + """ + Pygments Lexer For `Fancy `_. + + Fancy is a self-hosted, pure object-oriented, dynamic, + class-based, concurrent general-purpose programming language + running on Rubinius, the Ruby VM. + + .. versionadded:: 1.5 + """ + name = 'Fancy' + filenames = ['*.fy', '*.fancypack'] + aliases = ['fancy', 'fy'] + mimetypes = ['text/x-fancysrc'] + + tokens = { + # copied from PerlLexer: + 'balanced-regex': [ + (r'/(\\\\|\\/|[^/])*/[egimosx]*', String.Regex, '#pop'), + (r'!(\\\\|\\!|[^!])*![egimosx]*', String.Regex, '#pop'), + (r'\\(\\\\|[^\\])*\\[egimosx]*', String.Regex, '#pop'), + (r'\{(\\\\|\\\}|[^}])*\}[egimosx]*', String.Regex, '#pop'), + (r'<(\\\\|\\>|[^>])*>[egimosx]*', String.Regex, '#pop'), + (r'\[(\\\\|\\\]|[^\]])*\][egimosx]*', String.Regex, '#pop'), + (r'\((\\\\|\\\)|[^)])*\)[egimosx]*', String.Regex, '#pop'), + (r'@(\\\\|\\@|[^@])*@[egimosx]*', String.Regex, '#pop'), + (r'%(\\\\|\\%|[^%])*%[egimosx]*', String.Regex, '#pop'), + (r'\$(\\\\|\\\$|[^$])*\$[egimosx]*', String.Regex, '#pop'), + ], + 'root': [ + (r'\s+', Text), + + # balanced delimiters (copied from PerlLexer): + (r's\{(\\\\|\\\}|[^}])*\}\s*', String.Regex, 'balanced-regex'), + (r's<(\\\\|\\>|[^>])*>\s*', String.Regex, 'balanced-regex'), + (r's\[(\\\\|\\\]|[^\]])*\]\s*', String.Regex, 'balanced-regex'), + (r's\((\\\\|\\\)|[^)])*\)\s*', String.Regex, 'balanced-regex'), + (r'm?/(\\\\|\\/|[^/\n])*/[gcimosx]*', String.Regex), + (r'm(?=[/!\\{<\[(@%$])', String.Regex, 'balanced-regex'), + + # Comments + (r'#(.*?)\n', Comment.Single), + # Symbols + (r'\'([^\'\s\[\](){}]+|\[\])', String.Symbol), + # Multi-line DoubleQuotedString + (r'"""(\\\\|\\"|[^"])*"""', String), + # DoubleQuotedString + (r'"(\\\\|\\"|[^"])*"', String), + # keywords + (r'(def|class|try|catch|finally|retry|return|return_local|match|' + r'case|->|=>)\b', Keyword), + # constants + (r'(self|super|nil|false|true)\b', Name.Constant), + (r'[(){};,/?|:\\]', Punctuation), + # names + (words(( + 'Object', 'Array', 'Hash', 'Directory', 'File', 'Class', 'String', + 'Number', 'Enumerable', 'FancyEnumerable', 'Block', 'TrueClass', + 'NilClass', 'FalseClass', 'Tuple', 'Symbol', 'Stack', 'Set', + 'FancySpec', 'Method', 'Package', 'Range'), suffix=r'\b'), + Name.Builtin), + # functions + (r'[a-zA-Z](\w|[-+?!=*/^><%])*:', Name.Function), + # operators, must be below functions + (r'[-+*/~,<>=&!?%^\[\].$]+', Operator), + ('[A-Z]\w*', Name.Constant), + ('@[a-zA-Z_]\w*', Name.Variable.Instance), + ('@@[a-zA-Z_]\w*', Name.Variable.Class), + ('@@?', Operator), + ('[a-zA-Z_]\w*', Name), + # numbers - / checks are necessary to avoid mismarking regexes, + # see comment in RubyLexer + (r'(0[oO]?[0-7]+(?:_[0-7]+)*)(\s*)([/?])?', + bygroups(Number.Oct, Text, Operator)), + (r'(0[xX][0-9A-Fa-f]+(?:_[0-9A-Fa-f]+)*)(\s*)([/?])?', + bygroups(Number.Hex, Text, Operator)), + (r'(0[bB][01]+(?:_[01]+)*)(\s*)([/?])?', + bygroups(Number.Bin, Text, Operator)), + (r'([\d]+(?:_\d+)*)(\s*)([/?])?', + bygroups(Number.Integer, Text, Operator)), + (r'\d+([eE][+-]?[0-9]+)|\d+\.\d+([eE][+-]?[0-9]+)?', Number.Float), + (r'\d+', Number.Integer) + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rust.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rust.py new file mode 100644 index 0000000000..4447e1dbba --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/rust.py @@ -0,0 +1,167 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.rust + ~~~~~~~~~~~~~~~~~~~~ + + Lexers for the Rust language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, include, bygroups, words, default +from pygments.token import Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Whitespace + +__all__ = ['RustLexer'] + + +class RustLexer(RegexLexer): + """ + Lexer for the Rust programming language (version 0.9). + + .. versionadded:: 1.6 + """ + name = 'Rust' + filenames = ['*.rs'] + aliases = ['rust'] + mimetypes = ['text/x-rustsrc'] + + tokens = { + 'root': [ + # Whitespace and Comments + (r'\n', Whitespace), + (r'\s+', Whitespace), + (r'//[/!](.*?)\n', Comment.Doc), + (r'//(.*?)\n', Comment.Single), + (r'/\*', Comment.Multiline, 'comment'), + + # Lifetime + (r"""'[a-zA-Z_]\w*""", Name.Label), + # Macro parameters + (r"""\$([a-zA-Z_]\w*|\(,?|\),?|,?)""", Comment.Preproc), + # Keywords + (words(( + 'as', 'box', 'break', 'continue', 'do', 'else', 'enum', 'extern', + 'fn', 'for', 'if', 'impl', 'in', 'loop', 'match', 'mut', 'priv', + 'proc', 'pub', 'ref', 'return', 'static', '\'static', 'struct', + 'trait', 'true', 'type', 'unsafe', 'while'), suffix=r'\b'), + Keyword), + (words(('alignof', 'be', 'const', 'offsetof', 'pure', 'sizeof', + 'typeof', 'once', 'unsized', 'yield'), suffix=r'\b'), + Keyword.Reserved), + (r'(mod|use)\b', Keyword.Namespace), + (r'(true|false)\b', Keyword.Constant), + (r'let\b', Keyword.Declaration), + (words(('u8', 'u16', 'u32', 'u64', 'i8', 'i16', 'i32', 'i64', 'uint', + 'int', 'f32', 'f64', 'str', 'bool'), suffix=r'\b'), + Keyword.Type), + (r'self\b', Name.Builtin.Pseudo), + # Prelude + (words(( + 'Freeze', 'Pod', 'Send', 'Sized', 'Add', 'Sub', 'Mul', 'Div', 'Rem', 'Neg', 'Not', 'BitAnd', + 'BitOr', 'BitXor', 'Drop', 'Shl', 'Shr', 'Index', 'Option', 'Some', 'None', 'Result', + 'Ok', 'Err', 'from_str', 'range', 'print', 'println', 'Any', 'AnyOwnExt', 'AnyRefExt', + 'AnyMutRefExt', 'Ascii', 'AsciiCast', 'OnwedAsciiCast', 'AsciiStr', + 'IntoBytes', 'Bool', 'ToCStr', 'Char', 'Clone', 'DeepClone', 'Eq', 'ApproxEq', + 'Ord', 'TotalEq', 'Ordering', 'Less', 'Equal', 'Greater', 'Equiv', 'Container', + 'Mutable', 'Map', 'MutableMap', 'Set', 'MutableSet', 'Default', 'FromStr', + 'Hash', 'FromIterator', 'Extendable', 'Iterator', 'DoubleEndedIterator', + 'RandomAccessIterator', 'CloneableIterator', 'OrdIterator', + 'MutableDoubleEndedIterator', 'ExactSize', 'Times', 'Algebraic', + 'Trigonometric', 'Exponential', 'Hyperbolic', 'Bitwise', 'BitCount', + 'Bounded', 'Integer', 'Fractional', 'Real', 'RealExt', 'Num', 'NumCast', + 'CheckedAdd', 'CheckedSub', 'CheckedMul', 'Orderable', 'Signed', + 'Unsigned', 'Round', 'Primitive', 'Int', 'Float', 'ToStrRadix', + 'ToPrimitive', 'FromPrimitive', 'GenericPath', 'Path', 'PosixPath', + 'WindowsPath', 'RawPtr', 'Buffer', 'Writer', 'Reader', 'Seek', + 'SendStr', 'SendStrOwned', 'SendStrStatic', 'IntoSendStr', 'Str', + 'StrVector', 'StrSlice', 'OwnedStr', 'IterBytes', 'ToStr', 'IntoStr', + 'CopyableTuple', 'ImmutableTuple', 'ImmutableEqVector', 'ImmutableTotalOrdVector', + 'ImmutableCopyableVector', 'OwnedVector', 'OwnedCopyableVector', + 'OwnedEqVector', 'MutableVector', 'MutableTotalOrdVector', + 'Vector', 'VectorVector', 'CopyableVector', 'ImmutableVector', + 'Port', 'Chan', 'SharedChan', 'spawn', 'drop'), suffix=r'\b'), + Name.Builtin), + (r'(ImmutableTuple\d+|Tuple\d+)\b', Name.Builtin), + # Borrowed pointer + (r'(&)(\'[A-Za-z_]\w*)?', bygroups(Operator, Name)), + # Labels + (r'\'[A-Za-z_]\w*:', Name.Label), + # Character Literal + (r"""'(\\['"\\nrt]|\\x[0-9a-fA-F]{2}|\\[0-7]{1,3}""" + r"""|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}|.)'""", + String.Char), + # Binary Literal + (r'0b[01_]+', Number.Bin, 'number_lit'), + # Octal Literal + (r'0o[0-7_]+', Number.Oct, 'number_lit'), + # Hexadecimal Literal + (r'0[xX][0-9a-fA-F_]+', Number.Hex, 'number_lit'), + # Decimal Literal + (r'[0-9][0-9_]*(\.[0-9_]+[eE][+\-]?[0-9_]+|' + r'\.[0-9_]*|[eE][+\-]?[0-9_]+)', Number.Float, 'number_lit'), + (r'[0-9][0-9_]*', Number.Integer, 'number_lit'), + # String Literal + (r'"', String, 'string'), + (r'r(#*)".*?"\1', String.Raw), + + # Operators and Punctuation + (r'[{}()\[\],.;]', Punctuation), + (r'[+\-*/%&|<>^!~@=:?]', Operator), + + # Identifier + (r'[a-zA-Z_]\w*', Name), + + # Attributes + (r'#!?\[', Comment.Preproc, 'attribute['), + # Macros + (r'([A-Za-z_]\w*)(!)(\s*)([A-Za-z_]\w*)?(\s*)(\{)', + bygroups(Comment.Preproc, Punctuation, Whitespace, Name, + Whitespace, Punctuation), 'macro{'), + (r'([A-Za-z_]\w*)(!)(\s*)([A-Za-z_]\w*)?(\()', + bygroups(Comment.Preproc, Punctuation, Whitespace, Name, + Punctuation), 'macro('), + ], + 'comment': [ + (r'[^*/]+', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline), + ], + 'number_lit': [ + (r'[ui](8|16|32|64)', Keyword, '#pop'), + (r'f(32|64)', Keyword, '#pop'), + default('#pop'), + ], + 'string': [ + (r'"', String, '#pop'), + (r"""\\['"\\nrt]|\\x[0-9a-fA-F]{2}|\\[0-7]{1,3}""" + r"""|\\u[0-9a-fA-F]{4}|\\U[0-9a-fA-F]{8}""", String.Escape), + (r'[^\\"]+', String), + (r'\\', String), + ], + 'macro{': [ + (r'\{', Operator, '#push'), + (r'\}', Operator, '#pop'), + ], + 'macro(': [ + (r'\(', Operator, '#push'), + (r'\)', Operator, '#pop'), + ], + 'attribute_common': [ + (r'"', String, 'string'), + (r'\[', Comment.Preproc, 'attribute['), + (r'\(', Comment.Preproc, 'attribute('), + ], + 'attribute[': [ + include('attribute_common'), + (r'\];?', Comment.Preproc, '#pop'), + (r'[^"\]]+', Comment.Preproc), + ], + 'attribute(': [ + include('attribute_common'), + (r'\);?', Comment.Preproc, '#pop'), + (r'[^")]+', Comment.Preproc), + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/scripting.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/scripting.py new file mode 100644 index 0000000000..678cab21a6 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/scripting.py @@ -0,0 +1,923 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.scripting + ~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexer for scripting and embedded languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import RegexLexer, include, bygroups, default, combined, \ + words +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation, Error, Whitespace +from pygments.util import get_bool_opt, get_list_opt, iteritems + +__all__ = ['LuaLexer', 'MoonScriptLexer', 'ChaiscriptLexer', 'LSLLexer', + 'AppleScriptLexer', 'RexxLexer', 'MOOCodeLexer', 'HybrisLexer'] + + +class LuaLexer(RegexLexer): + """ + For `Lua `_ source code. + + Additional options accepted: + + `func_name_highlighting` + If given and ``True``, highlight builtin function names + (default: ``True``). + `disabled_modules` + If given, must be a list of module names whose function names + should not be highlighted. By default all modules are highlighted. + + To get a list of allowed modules have a look into the + `_lua_builtins` module: + + .. sourcecode:: pycon + + >>> from pygments.lexers._lua_builtins import MODULES + >>> MODULES.keys() + ['string', 'coroutine', 'modules', 'io', 'basic', ...] + """ + + name = 'Lua' + aliases = ['lua'] + filenames = ['*.lua', '*.wlua'] + mimetypes = ['text/x-lua', 'application/x-lua'] + + tokens = { + 'root': [ + # lua allows a file to start with a shebang + (r'#!(.*?)$', Comment.Preproc), + default('base'), + ], + 'base': [ + (r'(?s)--\[(=*)\[.*?\]\1\]', Comment.Multiline), + ('--.*$', Comment.Single), + + (r'(?i)(\d*\.\d+|\d+\.\d*)(e[+-]?\d+)?', Number.Float), + (r'(?i)\d+e[+-]?\d+', Number.Float), + ('(?i)0x[0-9a-f]*', Number.Hex), + (r'\d+', Number.Integer), + + (r'\n', Text), + (r'[^\S\n]', Text), + # multiline strings + (r'(?s)\[(=*)\[.*?\]\1\]', String), + + (r'(==|~=|<=|>=|\.\.\.|\.\.|[=+\-*/%^<>#])', Operator), + (r'[\[\]{}().,:;]', Punctuation), + (r'(and|or|not)\b', Operator.Word), + + ('(break|do|else|elseif|end|for|if|in|repeat|return|then|until|' + r'while)\b', Keyword), + (r'(local)\b', Keyword.Declaration), + (r'(true|false|nil)\b', Keyword.Constant), + + (r'(function)\b', Keyword, 'funcname'), + + (r'[A-Za-z_]\w*(\.[A-Za-z_]\w*)?', Name), + + ("'", String.Single, combined('stringescape', 'sqs')), + ('"', String.Double, combined('stringescape', 'dqs')) + ], + + 'funcname': [ + (r'\s+', Text), + ('(?:([A-Za-z_]\w*)(\.))?([A-Za-z_]\w*)', + bygroups(Name.Class, Punctuation, Name.Function), '#pop'), + # inline function + ('\(', Punctuation, '#pop'), + ], + + # if I understand correctly, every character is valid in a lua string, + # so this state is only for later corrections + 'string': [ + ('.', String) + ], + + 'stringescape': [ + (r'''\\([abfnrtv\\"']|\d{1,3})''', String.Escape) + ], + + 'sqs': [ + ("'", String, '#pop'), + include('string') + ], + + 'dqs': [ + ('"', String, '#pop'), + include('string') + ] + } + + def __init__(self, **options): + self.func_name_highlighting = get_bool_opt( + options, 'func_name_highlighting', True) + self.disabled_modules = get_list_opt(options, 'disabled_modules', []) + + self._functions = set() + if self.func_name_highlighting: + from pygments.lexers._lua_builtins import MODULES + for mod, func in iteritems(MODULES): + if mod not in self.disabled_modules: + self._functions.update(func) + RegexLexer.__init__(self, **options) + + def get_tokens_unprocessed(self, text): + for index, token, value in \ + RegexLexer.get_tokens_unprocessed(self, text): + if token is Name: + if value in self._functions: + yield index, Name.Builtin, value + continue + elif '.' in value: + a, b = value.split('.') + yield index, Name, a + yield index + len(a), Punctuation, u'.' + yield index + len(a) + 1, Name, b + continue + yield index, token, value + + +class MoonScriptLexer(LuaLexer): + """ + For `MoonScript `_ source code. + + .. versionadded:: 1.5 + """ + + name = "MoonScript" + aliases = ["moon", "moonscript"] + filenames = ["*.moon"] + mimetypes = ['text/x-moonscript', 'application/x-moonscript'] + + tokens = { + 'root': [ + (r'#!(.*?)$', Comment.Preproc), + default('base'), + ], + 'base': [ + ('--.*$', Comment.Single), + (r'(?i)(\d*\.\d+|\d+\.\d*)(e[+-]?\d+)?', Number.Float), + (r'(?i)\d+e[+-]?\d+', Number.Float), + (r'(?i)0x[0-9a-f]*', Number.Hex), + (r'\d+', Number.Integer), + (r'\n', Text), + (r'[^\S\n]+', Text), + (r'(?s)\[(=*)\[.*?\]\1\]', String), + (r'(->|=>)', Name.Function), + (r':[a-zA-Z_]\w*', Name.Variable), + (r'(==|!=|~=|<=|>=|\.\.\.|\.\.|[=+\-*/%^<>#!.\\:])', Operator), + (r'[;,]', Punctuation), + (r'[\[\]{}()]', Keyword.Type), + (r'[a-zA-Z_]\w*:', Name.Variable), + (words(( + 'class', 'extends', 'if', 'then', 'super', 'do', 'with', + 'import', 'export', 'while', 'elseif', 'return', 'for', 'in', + 'from', 'when', 'using', 'else', 'and', 'or', 'not', 'switch', + 'break'), suffix=r'\b'), + Keyword), + (r'(true|false|nil)\b', Keyword.Constant), + (r'(and|or|not)\b', Operator.Word), + (r'(self)\b', Name.Builtin.Pseudo), + (r'@@?([a-zA-Z_]\w*)?', Name.Variable.Class), + (r'[A-Z]\w*', Name.Class), # proper name + (r'[A-Za-z_]\w*(\.[A-Za-z_]\w*)?', Name), + ("'", String.Single, combined('stringescape', 'sqs')), + ('"', String.Double, combined('stringescape', 'dqs')) + ], + 'stringescape': [ + (r'''\\([abfnrtv\\"']|\d{1,3})''', String.Escape) + ], + 'sqs': [ + ("'", String.Single, '#pop'), + (".", String) + ], + 'dqs': [ + ('"', String.Double, '#pop'), + (".", String) + ] + } + + def get_tokens_unprocessed(self, text): + # set . as Operator instead of Punctuation + for index, token, value in LuaLexer.get_tokens_unprocessed(self, text): + if token == Punctuation and value == ".": + token = Operator + yield index, token, value + + +class ChaiscriptLexer(RegexLexer): + """ + For `ChaiScript `_ source code. + + .. versionadded:: 2.0 + """ + + name = 'ChaiScript' + aliases = ['chai', 'chaiscript'] + filenames = ['*.chai'] + mimetypes = ['text/x-chaiscript', 'application/x-chaiscript'] + + flags = re.DOTALL | re.MULTILINE + + tokens = { + 'commentsandwhitespace': [ + (r'\s+', Text), + (r'//.*?\n', Comment.Single), + (r'/\*.*?\*/', Comment.Multiline), + (r'^\#.*?\n', Comment.Single) + ], + 'slashstartsregex': [ + include('commentsandwhitespace'), + (r'/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/' + r'([gim]+\b|\B)', String.Regex, '#pop'), + (r'(?=/)', Text, ('#pop', 'badregex')), + default('#pop') + ], + 'badregex': [ + (r'\n', Text, '#pop') + ], + 'root': [ + include('commentsandwhitespace'), + (r'\n', Text), + (r'[^\S\n]+', Text), + (r'\+\+|--|~|&&|\?|:|\|\||\\(?=\n)|\.\.' + r'(<<|>>>?|==?|!=?|[-<>+*%&|^/])=?', Operator, 'slashstartsregex'), + (r'[{(\[;,]', Punctuation, 'slashstartsregex'), + (r'[})\].]', Punctuation), + (r'[=+\-*/]', Operator), + (r'(for|in|while|do|break|return|continue|if|else|' + r'throw|try|catch' + r')\b', Keyword, 'slashstartsregex'), + (r'(var)\b', Keyword.Declaration, 'slashstartsregex'), + (r'(attr|def|fun)\b', Keyword.Reserved), + (r'(true|false)\b', Keyword.Constant), + (r'(eval|throw)\b', Name.Builtin), + (r'`\S+`', Name.Builtin), + (r'[$a-zA-Z_]\w*', Name.Other), + (r'[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float), + (r'0x[0-9a-fA-F]+', Number.Hex), + (r'[0-9]+', Number.Integer), + (r'"', String.Double, 'dqstring'), + (r"'(\\\\|\\'|[^'])*'", String.Single), + ], + 'dqstring': [ + (r'\$\{[^"}]+?\}', String.Interpol), + (r'\$', String.Double), + (r'\\\\', String.Double), + (r'\\"', String.Double), + (r'[^\\"$]+', String.Double), + (r'"', String.Double, '#pop'), + ], + } + + +class LSLLexer(RegexLexer): + """ + For Second Life's Linden Scripting Language source code. + + .. versionadded:: 2.0 + """ + + name = 'LSL' + aliases = ['lsl'] + filenames = ['*.lsl'] + mimetypes = ['text/x-lsl'] + + flags = re.MULTILINE + + lsl_keywords = r'\b(?:do|else|for|if|jump|return|while)\b' + lsl_types = r'\b(?:float|integer|key|list|quaternion|rotation|string|vector)\b' + lsl_states = r'\b(?:(?:state)\s+\w+|default)\b' + lsl_events = r'\b(?:state_(?:entry|exit)|touch(?:_(?:start|end))?|(?:land_)?collision(?:_(?:start|end))?|timer|listen|(?:no_)?sensor|control|(?:not_)?at_(?:rot_)?target|money|email|run_time_permissions|changed|attach|dataserver|moving_(?:start|end)|link_message|(?:on|object)_rez|remote_data|http_re(?:sponse|quest)|path_update|transaction_result)\b' + lsl_functions_builtin = r'\b(?:ll(?:ReturnObjectsBy(?:ID|Owner)|Json(?:2List|[GS]etValue|ValueType)|Sin|Cos|Tan|Atan2|Sqrt|Pow|Abs|Fabs|Frand|Floor|Ceil|Round|Vec(?:Mag|Norm|Dist)|Rot(?:Between|2(?:Euler|Fwd|Left|Up))|(?:Euler|Axes)2Rot|Whisper|(?:Region|Owner)?Say|Shout|Listen(?:Control|Remove)?|Sensor(?:Repeat|Remove)?|Detected(?:Name|Key|Owner|Type|Pos|Vel|Grab|Rot|Group|LinkNumber)|Die|Ground|Wind|(?:[GS]et)(?:AnimationOverride|MemoryLimit|PrimMediaParams|ParcelMusicURL|Object(?:Desc|Name)|PhysicsMaterial|Status|Scale|Color|Alpha|Texture|Pos|Rot|Force|Torque)|ResetAnimationOverride|(?:Scale|Offset|Rotate)Texture|(?:Rot)?Target(?:Remove)?|(?:Stop)?MoveToTarget|Apply(?:Rotational)?Impulse|Set(?:KeyframedMotion|ContentType|RegionPos|(?:Angular)?Velocity|Buoyancy|HoverHeight|ForceAndTorque|TimerEvent|ScriptState|Damage|TextureAnim|Sound(?:Queueing|Radius)|Vehicle(?:Type|(?:Float|Vector|Rotation)Param)|(?:Touch|Sit)?Text|Camera(?:Eye|At)Offset|PrimitiveParams|ClickAction|Link(?:Alpha|Color|PrimitiveParams(?:Fast)?|Texture(?:Anim)?|Camera|Media)|RemoteScriptAccessPin|PayPrice|LocalRot)|ScaleByFactor|Get(?:(?:Max|Min)ScaleFactor|ClosestNavPoint|StaticPath|SimStats|Env|PrimitiveParams|Link(?:PrimitiveParams|Number(?:OfSides)?|Key|Name|Media)|HTTPHeader|FreeURLs|Object(?:Details|PermMask|PrimCount)|Parcel(?:MaxPrims|Details|Prim(?:Count|Owners))|Attached|(?:SPMax|Free|Used)Memory|Region(?:Name|TimeDilation|FPS|Corner|AgentCount)|Root(?:Position|Rotation)|UnixTime|(?:Parcel|Region)Flags|(?:Wall|GMT)clock|SimulatorHostname|BoundingBox|GeometricCenter|Creator|NumberOf(?:Prims|NotecardLines|Sides)|Animation(?:List)?|(?:Camera|Local)(?:Pos|Rot)|Vel|Accel|Omega|Time(?:stamp|OfDay)|(?:Object|CenterOf)?Mass|MassMKS|Energy|Owner|(?:Owner)?Key|SunDirection|Texture(?:Offset|Scale|Rot)|Inventory(?:Number|Name|Key|Type|Creator|PermMask)|Permissions(?:Key)?|StartParameter|List(?:Length|EntryType)|Date|Agent(?:Size|Info|Language|List)|LandOwnerAt|NotecardLine|Script(?:Name|State))|(?:Get|Reset|GetAndReset)Time|PlaySound(?:Slave)?|LoopSound(?:Master|Slave)?|(?:Trigger|Stop|Preload)Sound|(?:(?:Get|Delete)Sub|Insert)String|To(?:Upper|Lower)|Give(?:InventoryList|Money)|RezObject|(?:Stop)?LookAt|Sleep|CollisionFilter|(?:Take|Release)Controls|DetachFromAvatar|AttachToAvatar(?:Temp)?|InstantMessage|(?:GetNext)?Email|StopHover|MinEventDelay|RotLookAt|String(?:Length|Trim)|(?:Start|Stop)Animation|TargetOmega|RequestPermissions|(?:Create|Break)Link|BreakAllLinks|(?:Give|Remove)Inventory|Water|PassTouches|Request(?:Agent|Inventory)Data|TeleportAgent(?:Home|GlobalCoords)?|ModifyLand|CollisionSound|ResetScript|MessageLinked|PushObject|PassCollisions|AxisAngle2Rot|Rot2(?:Axis|Angle)|A(?:cos|sin)|AngleBetween|AllowInventoryDrop|SubStringIndex|List2(?:CSV|Integer|Json|Float|String|Key|Vector|Rot|List(?:Strided)?)|DeleteSubList|List(?:Statistics|Sort|Randomize|(?:Insert|Find|Replace)List)|EdgeOfWorld|AdjustSoundVolume|Key2Name|TriggerSoundLimited|EjectFromLand|(?:CSV|ParseString)2List|OverMyLand|SameGroup|UnSit|Ground(?:Slope|Normal|Contour)|GroundRepel|(?:Set|Remove)VehicleFlags|(?:AvatarOn)?(?:Link)?SitTarget|Script(?:Danger|Profiler)|Dialog|VolumeDetect|ResetOtherScript|RemoteLoadScriptPin|(?:Open|Close)RemoteDataChannel|SendRemoteData|RemoteDataReply|(?:Integer|String)ToBase64|XorBase64|Log(?:10)?|Base64To(?:String|Integer)|ParseStringKeepNulls|RezAtRoot|RequestSimulatorData|ForceMouselook|(?:Load|Release|(?:E|Une)scape)URL|ParcelMedia(?:CommandList|Query)|ModPow|MapDestination|(?:RemoveFrom|AddTo|Reset)Land(?:Pass|Ban)List|(?:Set|Clear)CameraParams|HTTP(?:Request|Response)|TextBox|DetectedTouch(?:UV|Face|Pos|(?:N|Bin)ormal|ST)|(?:MD5|SHA1|DumpList2)String|Request(?:Secure)?URL|Clear(?:Prim|Link)Media|(?:Link)?ParticleSystem|(?:Get|Request)(?:Username|DisplayName)|RegionSayTo|CastRay|GenerateKey|TransferLindenDollars|ManageEstateAccess|(?:Create|Delete)Character|ExecCharacterCmd|Evade|FleeFrom|NavigateTo|PatrolPoints|Pursue|UpdateCharacter|WanderWithin))\b' + lsl_constants_float = r'\b(?:DEG_TO_RAD|PI(?:_BY_TWO)?|RAD_TO_DEG|SQRT2|TWO_PI)\b' + lsl_constants_integer = r'\b(?:JSON_APPEND|STATUS_(?:PHYSICS|ROTATE_[XYZ]|PHANTOM|SANDBOX|BLOCK_GRAB(?:_OBJECT)?|(?:DIE|RETURN)_AT_EDGE|CAST_SHADOWS|OK|MALFORMED_PARAMS|TYPE_MISMATCH|BOUNDS_ERROR|NOT_(?:FOUND|SUPPORTED)|INTERNAL_ERROR|WHITELIST_FAILED)|AGENT(?:_(?:BY_(?:LEGACY_|USER)NAME|FLYING|ATTACHMENTS|SCRIPTED|MOUSELOOK|SITTING|ON_OBJECT|AWAY|WALKING|IN_AIR|TYPING|CROUCHING|BUSY|ALWAYS_RUN|AUTOPILOT|LIST_(?:PARCEL(?:_OWNER)?|REGION)))?|CAMERA_(?:PITCH|DISTANCE|BEHINDNESS_(?:ANGLE|LAG)|(?:FOCUS|POSITION)(?:_(?:THRESHOLD|LOCKED|LAG))?|FOCUS_OFFSET|ACTIVE)|ANIM_ON|LOOP|REVERSE|PING_PONG|SMOOTH|ROTATE|SCALE|ALL_SIDES|LINK_(?:ROOT|SET|ALL_(?:OTHERS|CHILDREN)|THIS)|ACTIVE|PASSIVE|SCRIPTED|CONTROL_(?:FWD|BACK|(?:ROT_)?(?:LEFT|RIGHT)|UP|DOWN|(?:ML_)?LBUTTON)|PERMISSION_(?:RETURN_OBJECTS|DEBIT|OVERRIDE_ANIMATIONS|SILENT_ESTATE_MANAGEMENT|TAKE_CONTROLS|TRIGGER_ANIMATION|ATTACH|CHANGE_LINKS|(?:CONTROL|TRACK)_CAMERA|TELEPORT)|INVENTORY_(?:TEXTURE|SOUND|OBJECT|SCRIPT|LANDMARK|CLOTHING|NOTECARD|BODYPART|ANIMATION|GESTURE|ALL|NONE)|CHANGED_(?:INVENTORY|COLOR|SHAPE|SCALE|TEXTURE|LINK|ALLOWED_DROP|OWNER|REGION(?:_START)?|TELEPORT|MEDIA)|OBJECT_(?:(?:PHYSICS|SERVER|STREAMING)_COST|UNKNOWN_DETAIL|CHARACTER_TIME|PHANTOM|PHYSICS|TEMP_ON_REZ|NAME|DESC|POS|PRIM_EQUIVALENCE|RETURN_(?:PARCEL(?:_OWNER)?|REGION)|ROO?T|VELOCITY|OWNER|GROUP|CREATOR|ATTACHED_POINT|RENDER_WEIGHT|PATHFINDING_TYPE|(?:RUNNING|TOTAL)_SCRIPT_COUNT|SCRIPT_(?:MEMORY|TIME))|TYPE_(?:INTEGER|FLOAT|STRING|KEY|VECTOR|ROTATION|INVALID)|(?:DEBUG|PUBLIC)_CHANNEL|ATTACH_(?:AVATAR_CENTER|CHEST|HEAD|BACK|PELVIS|MOUTH|CHIN|NECK|NOSE|BELLY|[LR](?:SHOULDER|HAND|FOOT|EAR|EYE|[UL](?:ARM|LEG)|HIP)|(?:LEFT|RIGHT)_PEC|HUD_(?:CENTER_[12]|TOP_(?:RIGHT|CENTER|LEFT)|BOTTOM(?:_(?:RIGHT|LEFT))?))|LAND_(?:LEVEL|RAISE|LOWER|SMOOTH|NOISE|REVERT)|DATA_(?:ONLINE|NAME|BORN|SIM_(?:POS|STATUS|RATING)|PAYINFO)|PAYMENT_INFO_(?:ON_FILE|USED)|REMOTE_DATA_(?:CHANNEL|REQUEST|REPLY)|PSYS_(?:PART_(?:BF_(?:ZERO|ONE(?:_MINUS_(?:DEST_COLOR|SOURCE_(ALPHA|COLOR)))?|DEST_COLOR|SOURCE_(ALPHA|COLOR))|BLEND_FUNC_(DEST|SOURCE)|FLAGS|(?:START|END)_(?:COLOR|ALPHA|SCALE|GLOW)|MAX_AGE|(?:RIBBON|WIND|INTERP_(?:COLOR|SCALE)|BOUNCE|FOLLOW_(?:SRC|VELOCITY)|TARGET_(?:POS|LINEAR)|EMISSIVE)_MASK)|SRC_(?:MAX_AGE|PATTERN|ANGLE_(?:BEGIN|END)|BURST_(?:RATE|PART_COUNT|RADIUS|SPEED_(?:MIN|MAX))|ACCEL|TEXTURE|TARGET_KEY|OMEGA|PATTERN_(?:DROP|EXPLODE|ANGLE(?:_CONE(?:_EMPTY)?)?)))|VEHICLE_(?:REFERENCE_FRAME|TYPE_(?:NONE|SLED|CAR|BOAT|AIRPLANE|BALLOON)|(?:LINEAR|ANGULAR)_(?:FRICTION_TIMESCALE|MOTOR_DIRECTION)|LINEAR_MOTOR_OFFSET|HOVER_(?:HEIGHT|EFFICIENCY|TIMESCALE)|BUOYANCY|(?:LINEAR|ANGULAR)_(?:DEFLECTION_(?:EFFICIENCY|TIMESCALE)|MOTOR_(?:DECAY_)?TIMESCALE)|VERTICAL_ATTRACTION_(?:EFFICIENCY|TIMESCALE)|BANKING_(?:EFFICIENCY|MIX|TIMESCALE)|FLAG_(?:NO_DEFLECTION_UP|LIMIT_(?:ROLL_ONLY|MOTOR_UP)|HOVER_(?:(?:WATER|TERRAIN|UP)_ONLY|GLOBAL_HEIGHT)|MOUSELOOK_(?:STEER|BANK)|CAMERA_DECOUPLED))|PRIM_(?:TYPE(?:_(?:BOX|CYLINDER|PRISM|SPHERE|TORUS|TUBE|RING|SCULPT))?|HOLE_(?:DEFAULT|CIRCLE|SQUARE|TRIANGLE)|MATERIAL(?:_(?:STONE|METAL|GLASS|WOOD|FLESH|PLASTIC|RUBBER))?|SHINY_(?:NONE|LOW|MEDIUM|HIGH)|BUMP_(?:NONE|BRIGHT|DARK|WOOD|BARK|BRICKS|CHECKER|CONCRETE|TILE|STONE|DISKS|GRAVEL|BLOBS|SIDING|LARGETILE|STUCCO|SUCTION|WEAVE)|TEXGEN_(?:DEFAULT|PLANAR)|SCULPT_(?:TYPE_(?:SPHERE|TORUS|PLANE|CYLINDER|MASK)|FLAG_(?:MIRROR|INVERT))|PHYSICS(?:_(?:SHAPE_(?:CONVEX|NONE|PRIM|TYPE)))?|(?:POS|ROT)_LOCAL|SLICE|TEXT|FLEXIBLE|POINT_LIGHT|TEMP_ON_REZ|PHANTOM|POSITION|SIZE|ROTATION|TEXTURE|NAME|OMEGA|DESC|LINK_TARGET|COLOR|BUMP_SHINY|FULLBRIGHT|TEXGEN|GLOW|MEDIA_(?:ALT_IMAGE_ENABLE|CONTROLS|(?:CURRENT|HOME)_URL|AUTO_(?:LOOP|PLAY|SCALE|ZOOM)|FIRST_CLICK_INTERACT|(?:WIDTH|HEIGHT)_PIXELS|WHITELIST(?:_ENABLE)?|PERMS_(?:INTERACT|CONTROL)|PARAM_MAX|CONTROLS_(?:STANDARD|MINI)|PERM_(?:NONE|OWNER|GROUP|ANYONE)|MAX_(?:URL_LENGTH|WHITELIST_(?:SIZE|COUNT)|(?:WIDTH|HEIGHT)_PIXELS)))|MASK_(?:BASE|OWNER|GROUP|EVERYONE|NEXT)|PERM_(?:TRANSFER|MODIFY|COPY|MOVE|ALL)|PARCEL_(?:MEDIA_COMMAND_(?:STOP|PAUSE|PLAY|LOOP|TEXTURE|URL|TIME|AGENT|UNLOAD|AUTO_ALIGN|TYPE|SIZE|DESC|LOOP_SET)|FLAG_(?:ALLOW_(?:FLY|(?:GROUP_)?SCRIPTS|LANDMARK|TERRAFORM|DAMAGE|CREATE_(?:GROUP_)?OBJECTS)|USE_(?:ACCESS_(?:GROUP|LIST)|BAN_LIST|LAND_PASS_LIST)|LOCAL_SOUND_ONLY|RESTRICT_PUSHOBJECT|ALLOW_(?:GROUP|ALL)_OBJECT_ENTRY)|COUNT_(?:TOTAL|OWNER|GROUP|OTHER|SELECTED|TEMP)|DETAILS_(?:NAME|DESC|OWNER|GROUP|AREA|ID|SEE_AVATARS))|LIST_STAT_(?:MAX|MIN|MEAN|MEDIAN|STD_DEV|SUM(?:_SQUARES)?|NUM_COUNT|GEOMETRIC_MEAN|RANGE)|PAY_(?:HIDE|DEFAULT)|REGION_FLAG_(?:ALLOW_DAMAGE|FIXED_SUN|BLOCK_TERRAFORM|SANDBOX|DISABLE_(?:COLLISIONS|PHYSICS)|BLOCK_FLY|ALLOW_DIRECT_TELEPORT|RESTRICT_PUSHOBJECT)|HTTP_(?:METHOD|MIMETYPE|BODY_(?:MAXLENGTH|TRUNCATED)|CUSTOM_HEADER|PRAGMA_NO_CACHE|VERBOSE_THROTTLE|VERIFY_CERT)|STRING_(?:TRIM(?:_(?:HEAD|TAIL))?)|CLICK_ACTION_(?:NONE|TOUCH|SIT|BUY|PAY|OPEN(?:_MEDIA)?|PLAY|ZOOM)|TOUCH_INVALID_FACE|PROFILE_(?:NONE|SCRIPT_MEMORY)|RC_(?:DATA_FLAGS|DETECT_PHANTOM|GET_(?:LINK_NUM|NORMAL|ROOT_KEY)|MAX_HITS|REJECT_(?:TYPES|AGENTS|(?:NON)?PHYSICAL|LAND))|RCERR_(?:CAST_TIME_EXCEEDED|SIM_PERF_LOW|UNKNOWN)|ESTATE_ACCESS_(?:ALLOWED_(?:AGENT|GROUP)_(?:ADD|REMOVE)|BANNED_AGENT_(?:ADD|REMOVE))|DENSITY|FRICTION|RESTITUTION|GRAVITY_MULTIPLIER|KFM_(?:COMMAND|CMD_(?:PLAY|STOP|PAUSE|SET_MODE)|MODE|FORWARD|LOOP|PING_PONG|REVERSE|DATA|ROTATION|TRANSLATION)|ERR_(?:GENERIC|PARCEL_PERMISSIONS|MALFORMED_PARAMS|RUNTIME_PERMISSIONS|THROTTLED)|CHARACTER_(?:CMD_(?:(?:SMOOTH_)?STOP|JUMP)|DESIRED_(?:TURN_)?SPEED|RADIUS|STAY_WITHIN_PARCEL|LENGTH|ORIENTATION|ACCOUNT_FOR_SKIPPED_FRAMES|AVOIDANCE_MODE|TYPE(?:_(?:[A-D]|NONE))?|MAX_(?:DECEL|TURN_RADIUS|(?:ACCEL|SPEED)))|PURSUIT_(?:OFFSET|FUZZ_FACTOR|GOAL_TOLERANCE|INTERCEPT)|REQUIRE_LINE_OF_SIGHT|FORCE_DIRECT_PATH|VERTICAL|HORIZONTAL|AVOID_(?:CHARACTERS|DYNAMIC_OBSTACLES|NONE)|PU_(?:EVADE_(?:HIDDEN|SPOTTED)|FAILURE_(?:DYNAMIC_PATHFINDING_DISABLED|INVALID_(?:GOAL|START)|NO_(?:NAVMESH|VALID_DESTINATION)|OTHER|TARGET_GONE|(?:PARCEL_)?UNREACHABLE)|(?:GOAL|SLOWDOWN_DISTANCE)_REACHED)|TRAVERSAL_TYPE(?:_(?:FAST|NONE|SLOW))?|CONTENT_TYPE_(?:ATOM|FORM|HTML|JSON|LLSD|RSS|TEXT|XHTML|XML)|GCNP_(?:RADIUS|STATIC)|(?:PATROL|WANDER)_PAUSE_AT_WAYPOINTS|OPT_(?:AVATAR|CHARACTER|EXCLUSION_VOLUME|LEGACY_LINKSET|MATERIAL_VOLUME|OTHER|STATIC_OBSTACLE|WALKABLE)|SIM_STAT_PCT_CHARS_STEPPED)\b' + lsl_constants_integer_boolean = r'\b(?:FALSE|TRUE)\b' + lsl_constants_rotation = r'\b(?:ZERO_ROTATION)\b' + lsl_constants_string = r'\b(?:EOF|JSON_(?:ARRAY|DELETE|FALSE|INVALID|NULL|NUMBER|OBJECT|STRING|TRUE)|NULL_KEY|TEXTURE_(?:BLANK|DEFAULT|MEDIA|PLYWOOD|TRANSPARENT)|URL_REQUEST_(?:GRANTED|DENIED))\b' + lsl_constants_vector = r'\b(?:TOUCH_INVALID_(?:TEXCOORD|VECTOR)|ZERO_VECTOR)\b' + lsl_invalid_broken = r'\b(?:LAND_(?:LARGE|MEDIUM|SMALL)_BRUSH)\b' + lsl_invalid_deprecated = r'\b(?:ATTACH_[LR]PEC|DATA_RATING|OBJECT_ATTACHMENT_(?:GEOMETRY_BYTES|SURFACE_AREA)|PRIM_(?:CAST_SHADOWS|MATERIAL_LIGHT|TYPE_LEGACY)|PSYS_SRC_(?:INNER|OUTER)ANGLE|VEHICLE_FLAG_NO_FLY_UP|ll(?:Cloud|Make(?:Explosion|Fountain|Smoke|Fire)|RemoteDataSetRegion|Sound(?:Preload)?|XorBase64Strings(?:Correct)?))\b' + lsl_invalid_illegal = r'\b(?:event)\b' + lsl_invalid_unimplemented = r'\b(?:CHARACTER_(?:MAX_ANGULAR_(?:ACCEL|SPEED)|TURN_SPEED_MULTIPLIER)|PERMISSION_(?:CHANGE_(?:JOINTS|PERMISSIONS)|RELEASE_OWNERSHIP|REMAP_CONTROLS)|PRIM_PHYSICS_MATERIAL|PSYS_SRC_OBJ_REL_MASK|ll(?:CollisionSprite|(?:Stop)?PointAt|(?:(?:Refresh|Set)Prim)URL|(?:Take|Release)Camera|RemoteLoadScript))\b' + lsl_reserved_godmode = r'\b(?:ll(?:GodLikeRezObject|Set(?:Inventory|Object)PermMask))\b' + lsl_reserved_log = r'\b(?:print)\b' + lsl_operators = r'\+\+|\-\-|<<|>>|&&?|\|\|?|\^|~|[!%<>=*+\-/]=?' + + tokens = { + 'root': + [ + (r'//.*?\n', Comment.Single), + (r'/\*', Comment.Multiline, 'comment'), + (r'"', String.Double, 'string'), + (lsl_keywords, Keyword), + (lsl_types, Keyword.Type), + (lsl_states, Name.Class), + (lsl_events, Name.Builtin), + (lsl_functions_builtin, Name.Function), + (lsl_constants_float, Keyword.Constant), + (lsl_constants_integer, Keyword.Constant), + (lsl_constants_integer_boolean, Keyword.Constant), + (lsl_constants_rotation, Keyword.Constant), + (lsl_constants_string, Keyword.Constant), + (lsl_constants_vector, Keyword.Constant), + (lsl_invalid_broken, Error), + (lsl_invalid_deprecated, Error), + (lsl_invalid_illegal, Error), + (lsl_invalid_unimplemented, Error), + (lsl_reserved_godmode, Keyword.Reserved), + (lsl_reserved_log, Keyword.Reserved), + (r'\b([a-zA-Z_]\w*)\b', Name.Variable), + (r'(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d*', Number.Float), + (r'(\d+\.\d*|\.\d+)', Number.Float), + (r'0[xX][0-9a-fA-F]+', Number.Hex), + (r'\d+', Number.Integer), + (lsl_operators, Operator), + (r':=?', Error), + (r'[,;{}()\[\]]', Punctuation), + (r'\n+', Whitespace), + (r'\s+', Whitespace) + ], + 'comment': + [ + (r'[^*/]+', Comment.Multiline), + (r'/\*', Comment.Multiline, '#push'), + (r'\*/', Comment.Multiline, '#pop'), + (r'[*/]', Comment.Multiline) + ], + 'string': + [ + (r'\\([nt"\\])', String.Escape), + (r'"', String.Double, '#pop'), + (r'\\.', Error), + (r'[^"\\]+', String.Double), + ] + } + + +class AppleScriptLexer(RegexLexer): + """ + For `AppleScript source code + `_, + including `AppleScript Studio + `_. + Contributed by Andreas Amann . + + .. versionadded:: 1.0 + """ + + name = 'AppleScript' + aliases = ['applescript'] + filenames = ['*.applescript'] + + flags = re.MULTILINE | re.DOTALL + + Identifiers = r'[a-zA-Z]\w*' + + # XXX: use words() for all of these + Literals = ('AppleScript', 'current application', 'false', 'linefeed', + 'missing value', 'pi', 'quote', 'result', 'return', 'space', + 'tab', 'text item delimiters', 'true', 'version') + Classes = ('alias ', 'application ', 'boolean ', 'class ', 'constant ', + 'date ', 'file ', 'integer ', 'list ', 'number ', 'POSIX file ', + 'real ', 'record ', 'reference ', 'RGB color ', 'script ', + 'text ', 'unit types', '(?:Unicode )?text', 'string') + BuiltIn = ('attachment', 'attribute run', 'character', 'day', 'month', + 'paragraph', 'word', 'year') + HandlerParams = ('about', 'above', 'against', 'apart from', 'around', + 'aside from', 'at', 'below', 'beneath', 'beside', + 'between', 'for', 'given', 'instead of', 'on', 'onto', + 'out of', 'over', 'since') + Commands = ('ASCII (character|number)', 'activate', 'beep', 'choose URL', + 'choose application', 'choose color', 'choose file( name)?', + 'choose folder', 'choose from list', + 'choose remote application', 'clipboard info', + 'close( access)?', 'copy', 'count', 'current date', 'delay', + 'delete', 'display (alert|dialog)', 'do shell script', + 'duplicate', 'exists', 'get eof', 'get volume settings', + 'info for', 'launch', 'list (disks|folder)', 'load script', + 'log', 'make', 'mount volume', 'new', 'offset', + 'open( (for access|location))?', 'path to', 'print', 'quit', + 'random number', 'read', 'round', 'run( script)?', + 'say', 'scripting components', + 'set (eof|the clipboard to|volume)', 'store script', + 'summarize', 'system attribute', 'system info', + 'the clipboard', 'time to GMT', 'write', 'quoted form') + References = ('(in )?back of', '(in )?front of', '[0-9]+(st|nd|rd|th)', + 'first', 'second', 'third', 'fourth', 'fifth', 'sixth', + 'seventh', 'eighth', 'ninth', 'tenth', 'after', 'back', + 'before', 'behind', 'every', 'front', 'index', 'last', + 'middle', 'some', 'that', 'through', 'thru', 'where', 'whose') + Operators = ("and", "or", "is equal", "equals", "(is )?equal to", "is not", + "isn't", "isn't equal( to)?", "is not equal( to)?", + "doesn't equal", "does not equal", "(is )?greater than", + "comes after", "is not less than or equal( to)?", + "isn't less than or equal( to)?", "(is )?less than", + "comes before", "is not greater than or equal( to)?", + "isn't greater than or equal( to)?", + "(is )?greater than or equal( to)?", "is not less than", + "isn't less than", "does not come before", + "doesn't come before", "(is )?less than or equal( to)?", + "is not greater than", "isn't greater than", + "does not come after", "doesn't come after", "starts? with", + "begins? with", "ends? with", "contains?", "does not contain", + "doesn't contain", "is in", "is contained by", "is not in", + "is not contained by", "isn't contained by", "div", "mod", + "not", "(a )?(ref( to)?|reference to)", "is", "does") + Control = ('considering', 'else', 'error', 'exit', 'from', 'if', + 'ignoring', 'in', 'repeat', 'tell', 'then', 'times', 'to', + 'try', 'until', 'using terms from', 'while', 'whith', + 'with timeout( of)?', 'with transaction', 'by', 'continue', + 'end', 'its?', 'me', 'my', 'return', 'of', 'as') + Declarations = ('global', 'local', 'prop(erty)?', 'set', 'get') + Reserved = ('but', 'put', 'returning', 'the') + StudioClasses = ('action cell', 'alert reply', 'application', 'box', + 'browser( cell)?', 'bundle', 'button( cell)?', 'cell', + 'clip view', 'color well', 'color-panel', + 'combo box( item)?', 'control', + 'data( (cell|column|item|row|source))?', 'default entry', + 'dialog reply', 'document', 'drag info', 'drawer', + 'event', 'font(-panel)?', 'formatter', + 'image( (cell|view))?', 'matrix', 'menu( item)?', 'item', + 'movie( view)?', 'open-panel', 'outline view', 'panel', + 'pasteboard', 'plugin', 'popup button', + 'progress indicator', 'responder', 'save-panel', + 'scroll view', 'secure text field( cell)?', 'slider', + 'sound', 'split view', 'stepper', 'tab view( item)?', + 'table( (column|header cell|header view|view))', + 'text( (field( cell)?|view))?', 'toolbar( item)?', + 'user-defaults', 'view', 'window') + StudioEvents = ('accept outline drop', 'accept table drop', 'action', + 'activated', 'alert ended', 'awake from nib', 'became key', + 'became main', 'begin editing', 'bounds changed', + 'cell value', 'cell value changed', 'change cell value', + 'change item value', 'changed', 'child of item', + 'choose menu item', 'clicked', 'clicked toolbar item', + 'closed', 'column clicked', 'column moved', + 'column resized', 'conclude drop', 'data representation', + 'deminiaturized', 'dialog ended', 'document nib name', + 'double clicked', 'drag( (entered|exited|updated))?', + 'drop', 'end editing', 'exposed', 'idle', 'item expandable', + 'item value', 'item value changed', 'items changed', + 'keyboard down', 'keyboard up', 'launched', + 'load data representation', 'miniaturized', 'mouse down', + 'mouse dragged', 'mouse entered', 'mouse exited', + 'mouse moved', 'mouse up', 'moved', + 'number of browser rows', 'number of items', + 'number of rows', 'open untitled', 'opened', 'panel ended', + 'parameters updated', 'plugin loaded', 'prepare drop', + 'prepare outline drag', 'prepare outline drop', + 'prepare table drag', 'prepare table drop', + 'read from file', 'resigned active', 'resigned key', + 'resigned main', 'resized( sub views)?', + 'right mouse down', 'right mouse dragged', + 'right mouse up', 'rows changed', 'scroll wheel', + 'selected tab view item', 'selection changed', + 'selection changing', 'should begin editing', + 'should close', 'should collapse item', + 'should end editing', 'should expand item', + 'should open( untitled)?', + 'should quit( after last window closed)?', + 'should select column', 'should select item', + 'should select row', 'should select tab view item', + 'should selection change', 'should zoom', 'shown', + 'update menu item', 'update parameters', + 'update toolbar item', 'was hidden', 'was miniaturized', + 'will become active', 'will close', 'will dismiss', + 'will display browser cell', 'will display cell', + 'will display item cell', 'will display outline cell', + 'will finish launching', 'will hide', 'will miniaturize', + 'will move', 'will open', 'will pop up', 'will quit', + 'will resign active', 'will resize( sub views)?', + 'will select tab view item', 'will show', 'will zoom', + 'write to file', 'zoomed') + StudioCommands = ('animate', 'append', 'call method', 'center', + 'close drawer', 'close panel', 'display', + 'display alert', 'display dialog', 'display panel', 'go', + 'hide', 'highlight', 'increment', 'item for', + 'load image', 'load movie', 'load nib', 'load panel', + 'load sound', 'localized string', 'lock focus', 'log', + 'open drawer', 'path for', 'pause', 'perform action', + 'play', 'register', 'resume', 'scroll', 'select( all)?', + 'show', 'size to fit', 'start', 'step back', + 'step forward', 'stop', 'synchronize', 'unlock focus', + 'update') + StudioProperties = ('accepts arrow key', 'action method', 'active', + 'alignment', 'allowed identifiers', + 'allows branch selection', 'allows column reordering', + 'allows column resizing', 'allows column selection', + 'allows customization', + 'allows editing text attributes', + 'allows empty selection', 'allows mixed state', + 'allows multiple selection', 'allows reordering', + 'allows undo', 'alpha( value)?', 'alternate image', + 'alternate increment value', 'alternate title', + 'animation delay', 'associated file name', + 'associated object', 'auto completes', 'auto display', + 'auto enables items', 'auto repeat', + 'auto resizes( outline column)?', + 'auto save expanded items', 'auto save name', + 'auto save table columns', 'auto saves configuration', + 'auto scroll', 'auto sizes all columns to fit', + 'auto sizes cells', 'background color', 'bezel state', + 'bezel style', 'bezeled', 'border rect', 'border type', + 'bordered', 'bounds( rotation)?', 'box type', + 'button returned', 'button type', + 'can choose directories', 'can choose files', + 'can draw', 'can hide', + 'cell( (background color|size|type))?', 'characters', + 'class', 'click count', 'clicked( data)? column', + 'clicked data item', 'clicked( data)? row', + 'closeable', 'collating', 'color( (mode|panel))', + 'command key down', 'configuration', + 'content(s| (size|view( margins)?))?', 'context', + 'continuous', 'control key down', 'control size', + 'control tint', 'control view', + 'controller visible', 'coordinate system', + 'copies( on scroll)?', 'corner view', 'current cell', + 'current column', 'current( field)? editor', + 'current( menu)? item', 'current row', + 'current tab view item', 'data source', + 'default identifiers', 'delta (x|y|z)', + 'destination window', 'directory', 'display mode', + 'displayed cell', 'document( (edited|rect|view))?', + 'double value', 'dragged column', 'dragged distance', + 'dragged items', 'draws( cell)? background', + 'draws grid', 'dynamically scrolls', 'echos bullets', + 'edge', 'editable', 'edited( data)? column', + 'edited data item', 'edited( data)? row', 'enabled', + 'enclosing scroll view', 'ending page', + 'error handling', 'event number', 'event type', + 'excluded from windows menu', 'executable path', + 'expanded', 'fax number', 'field editor', 'file kind', + 'file name', 'file type', 'first responder', + 'first visible column', 'flipped', 'floating', + 'font( panel)?', 'formatter', 'frameworks path', + 'frontmost', 'gave up', 'grid color', 'has data items', + 'has horizontal ruler', 'has horizontal scroller', + 'has parent data item', 'has resize indicator', + 'has shadow', 'has sub menu', 'has vertical ruler', + 'has vertical scroller', 'header cell', 'header view', + 'hidden', 'hides when deactivated', 'highlights by', + 'horizontal line scroll', 'horizontal page scroll', + 'horizontal ruler view', 'horizontally resizable', + 'icon image', 'id', 'identifier', + 'ignores multiple clicks', + 'image( (alignment|dims when disabled|frame style|scaling))?', + 'imports graphics', 'increment value', + 'indentation per level', 'indeterminate', 'index', + 'integer value', 'intercell spacing', 'item height', + 'key( (code|equivalent( modifier)?|window))?', + 'knob thickness', 'label', 'last( visible)? column', + 'leading offset', 'leaf', 'level', 'line scroll', + 'loaded', 'localized sort', 'location', 'loop mode', + 'main( (bunde|menu|window))?', 'marker follows cell', + 'matrix mode', 'maximum( content)? size', + 'maximum visible columns', + 'menu( form representation)?', 'miniaturizable', + 'miniaturized', 'minimized image', 'minimized title', + 'minimum column width', 'minimum( content)? size', + 'modal', 'modified', 'mouse down state', + 'movie( (controller|file|rect))?', 'muted', 'name', + 'needs display', 'next state', 'next text', + 'number of tick marks', 'only tick mark values', + 'opaque', 'open panel', 'option key down', + 'outline table column', 'page scroll', 'pages across', + 'pages down', 'palette label', 'pane splitter', + 'parent data item', 'parent window', 'pasteboard', + 'path( (names|separator))?', 'playing', + 'plays every frame', 'plays selection only', 'position', + 'preferred edge', 'preferred type', 'pressure', + 'previous text', 'prompt', 'properties', + 'prototype cell', 'pulls down', 'rate', + 'released when closed', 'repeated', + 'requested print time', 'required file type', + 'resizable', 'resized column', 'resource path', + 'returns records', 'reuses columns', 'rich text', + 'roll over', 'row height', 'rulers visible', + 'save panel', 'scripts path', 'scrollable', + 'selectable( identifiers)?', 'selected cell', + 'selected( data)? columns?', 'selected data items?', + 'selected( data)? rows?', 'selected item identifier', + 'selection by rect', 'send action on arrow key', + 'sends action when done editing', 'separates columns', + 'separator item', 'sequence number', 'services menu', + 'shared frameworks path', 'shared support path', + 'sheet', 'shift key down', 'shows alpha', + 'shows state by', 'size( mode)?', + 'smart insert delete enabled', 'sort case sensitivity', + 'sort column', 'sort order', 'sort type', + 'sorted( data rows)?', 'sound', 'source( mask)?', + 'spell checking enabled', 'starting page', 'state', + 'string value', 'sub menu', 'super menu', 'super view', + 'tab key traverses cells', 'tab state', 'tab type', + 'tab view', 'table view', 'tag', 'target( printer)?', + 'text color', 'text container insert', + 'text container origin', 'text returned', + 'tick mark position', 'time stamp', + 'title(d| (cell|font|height|position|rect))?', + 'tool tip', 'toolbar', 'trailing offset', 'transparent', + 'treat packages as directories', 'truncated labels', + 'types', 'unmodified characters', 'update views', + 'use sort indicator', 'user defaults', + 'uses data source', 'uses ruler', + 'uses threaded animation', + 'uses title from previous column', 'value wraps', + 'version', + 'vertical( (line scroll|page scroll|ruler view))?', + 'vertically resizable', 'view', + 'visible( document rect)?', 'volume', 'width', 'window', + 'windows menu', 'wraps', 'zoomable', 'zoomed') + + tokens = { + 'root': [ + (r'\s+', Text), + (u'¬\\n', String.Escape), + (r"'s\s+", Text), # This is a possessive, consider moving + (r'(--|#).*?$', Comment), + (r'\(\*', Comment.Multiline, 'comment'), + (r'[(){}!,.:]', Punctuation), + (u'(«)([^»]+)(»)', + bygroups(Text, Name.Builtin, Text)), + (r'\b((?:considering|ignoring)\s*)' + r'(application responses|case|diacriticals|hyphens|' + r'numeric strings|punctuation|white space)', + bygroups(Keyword, Name.Builtin)), + (u'(-|\\*|\\+|&|≠|>=?|<=?|=|≥|≤|/|÷|\\^)', Operator), + (r"\b(%s)\b" % '|'.join(Operators), Operator.Word), + (r'^(\s*(?:on|end)\s+)' + r'(%s)' % '|'.join(StudioEvents[::-1]), + bygroups(Keyword, Name.Function)), + (r'^(\s*)(in|on|script|to)(\s+)', bygroups(Text, Keyword, Text)), + (r'\b(as )(%s)\b' % '|'.join(Classes), + bygroups(Keyword, Name.Class)), + (r'\b(%s)\b' % '|'.join(Literals), Name.Constant), + (r'\b(%s)\b' % '|'.join(Commands), Name.Builtin), + (r'\b(%s)\b' % '|'.join(Control), Keyword), + (r'\b(%s)\b' % '|'.join(Declarations), Keyword), + (r'\b(%s)\b' % '|'.join(Reserved), Name.Builtin), + (r'\b(%s)s?\b' % '|'.join(BuiltIn), Name.Builtin), + (r'\b(%s)\b' % '|'.join(HandlerParams), Name.Builtin), + (r'\b(%s)\b' % '|'.join(StudioProperties), Name.Attribute), + (r'\b(%s)s?\b' % '|'.join(StudioClasses), Name.Builtin), + (r'\b(%s)\b' % '|'.join(StudioCommands), Name.Builtin), + (r'\b(%s)\b' % '|'.join(References), Name.Builtin), + (r'"(\\\\|\\"|[^"])*"', String.Double), + (r'\b(%s)\b' % Identifiers, Name.Variable), + (r'[-+]?(\d+\.\d*|\d*\.\d+)(E[-+][0-9]+)?', Number.Float), + (r'[-+]?\d+', Number.Integer), + ], + 'comment': [ + ('\(\*', Comment.Multiline, '#push'), + ('\*\)', Comment.Multiline, '#pop'), + ('[^*(]+', Comment.Multiline), + ('[*(]', Comment.Multiline), + ], + } + + +class RexxLexer(RegexLexer): + """ + `Rexx `_ is a scripting language available for + a wide range of different platforms with its roots found on mainframe + systems. It is popular for I/O- and data based tasks and can act as glue + language to bind different applications together. + + .. versionadded:: 2.0 + """ + name = 'Rexx' + aliases = ['rexx', 'arexx'] + filenames = ['*.rexx', '*.rex', '*.rx', '*.arexx'] + mimetypes = ['text/x-rexx'] + flags = re.IGNORECASE + + tokens = { + 'root': [ + (r'\s', Whitespace), + (r'/\*', Comment.Multiline, 'comment'), + (r'"', String, 'string_double'), + (r"'", String, 'string_single'), + (r'[0-9]+(\.[0-9]+)?(e[+-]?[0-9])?', Number), + (r'([a-z_]\w*)(\s*)(:)(\s*)(procedure)\b', + bygroups(Name.Function, Whitespace, Operator, Whitespace, + Keyword.Declaration)), + (r'([a-z_]\w*)(\s*)(:)', + bygroups(Name.Label, Whitespace, Operator)), + include('function'), + include('keyword'), + include('operator'), + (r'[a-z_]\w*', Text), + ], + 'function': [ + (words(( + 'abbrev', 'abs', 'address', 'arg', 'b2x', 'bitand', 'bitor', 'bitxor', + 'c2d', 'c2x', 'center', 'charin', 'charout', 'chars', 'compare', + 'condition', 'copies', 'd2c', 'd2x', 'datatype', 'date', 'delstr', + 'delword', 'digits', 'errortext', 'form', 'format', 'fuzz', 'insert', + 'lastpos', 'left', 'length', 'linein', 'lineout', 'lines', 'max', + 'min', 'overlay', 'pos', 'queued', 'random', 'reverse', 'right', 'sign', + 'sourceline', 'space', 'stream', 'strip', 'substr', 'subword', 'symbol', + 'time', 'trace', 'translate', 'trunc', 'value', 'verify', 'word', + 'wordindex', 'wordlength', 'wordpos', 'words', 'x2b', 'x2c', 'x2d', + 'xrange'), suffix=r'(\s*)(\()'), + bygroups(Name.Builtin, Whitespace, Operator)), + ], + 'keyword': [ + (r'(address|arg|by|call|do|drop|else|end|exit|for|forever|if|' + r'interpret|iterate|leave|nop|numeric|off|on|options|parse|' + r'pull|push|queue|return|say|select|signal|to|then|trace|until|' + r'while)\b', Keyword.Reserved), + ], + 'operator': [ + (r'(-|//|/|\(|\)|\*\*|\*|\\<<|\\<|\\==|\\=|\\>>|\\>|\\|\|\||\||' + r'&&|&|%|\+|<<=|<<|<=|<>|<|==|=|><|>=|>>=|>>|>|¬<<|¬<|¬==|¬=|' + r'¬>>|¬>|¬|\.|,)', Operator), + ], + 'string_double': [ + (r'[^"\n]+', String), + (r'""', String), + (r'"', String, '#pop'), + (r'\n', Text, '#pop'), # Stray linefeed also terminates strings. + ], + 'string_single': [ + (r'[^\'\n]', String), + (r'\'\'', String), + (r'\'', String, '#pop'), + (r'\n', Text, '#pop'), # Stray linefeed also terminates strings. + ], + 'comment': [ + (r'[^*]+', Comment.Multiline), + (r'\*/', Comment.Multiline, '#pop'), + (r'\*', Comment.Multiline), + ] + } + + _c = lambda s: re.compile(s, re.MULTILINE) + _ADDRESS_COMMAND_PATTERN = _c(r'^\s*address\s+command\b') + _ADDRESS_PATTERN = _c(r'^\s*address\s+') + _DO_WHILE_PATTERN = _c(r'^\s*do\s+while\b') + _IF_THEN_DO_PATTERN = _c(r'^\s*if\b.+\bthen\s+do\s*$') + _PROCEDURE_PATTERN = _c(r'^\s*([a-z_]\w*)(\s*)(:)(\s*)(procedure)\b') + _ELSE_DO_PATTERN = _c(r'\belse\s+do\s*$') + _PARSE_ARG_PATTERN = _c(r'^\s*parse\s+(upper\s+)?(arg|value)\b') + PATTERNS_AND_WEIGHTS = ( + (_ADDRESS_COMMAND_PATTERN, 0.2), + (_ADDRESS_PATTERN, 0.05), + (_DO_WHILE_PATTERN, 0.1), + (_ELSE_DO_PATTERN, 0.1), + (_IF_THEN_DO_PATTERN, 0.1), + (_PROCEDURE_PATTERN, 0.5), + (_PARSE_ARG_PATTERN, 0.2), + ) + + def analyse_text(text): + """ + Check for inital comment and patterns that distinguish Rexx from other + C-like languages. + """ + if re.search(r'/\*\**\s*rexx', text, re.IGNORECASE): + # Header matches MVS Rexx requirements, this is certainly a Rexx + # script. + return 1.0 + elif text.startswith('/*'): + # Header matches general Rexx requirements; the source code might + # still be any language using C comments such as C++, C# or Java. + lowerText = text.lower() + result = sum(weight + for (pattern, weight) in RexxLexer.PATTERNS_AND_WEIGHTS + if pattern.search(lowerText)) + 0.01 + return min(result, 1.0) + + +class MOOCodeLexer(RegexLexer): + """ + For `MOOCode `_ (the MOO scripting + language). + + .. versionadded:: 0.9 + """ + name = 'MOOCode' + filenames = ['*.moo'] + aliases = ['moocode', 'moo'] + mimetypes = ['text/x-moocode'] + + tokens = { + 'root': [ + # Numbers + (r'(0|[1-9][0-9_]*)', Number.Integer), + # Strings + (r'"(\\\\|\\"|[^"])*"', String), + # exceptions + (r'(E_PERM|E_DIV)', Name.Exception), + # db-refs + (r'((#[-0-9]+)|(\$\w+))', Name.Entity), + # Keywords + (r'\b(if|else|elseif|endif|for|endfor|fork|endfork|while' + r'|endwhile|break|continue|return|try' + r'|except|endtry|finally|in)\b', Keyword), + # builtins + (r'(random|length)', Name.Builtin), + # special variables + (r'(player|caller|this|args)', Name.Variable.Instance), + # skip whitespace + (r'\s+', Text), + (r'\n', Text), + # other operators + (r'([!;=,{}&|:.\[\]@()<>?]+)', Operator), + # function call + (r'(\w+)(\()', bygroups(Name.Function, Operator)), + # variables + (r'(\w+)', Text), + ] + } + + +class HybrisLexer(RegexLexer): + """ + For `Hybris `_ source code. + + .. versionadded:: 1.4 + """ + + name = 'Hybris' + aliases = ['hybris', 'hy'] + filenames = ['*.hy', '*.hyb'] + mimetypes = ['text/x-hybris', 'application/x-hybris'] + + flags = re.MULTILINE | re.DOTALL + + tokens = { + 'root': [ + # method names + (r'^(\s*(?:function|method|operator\s+)+?)' + r'([a-zA-Z_]\w*)' + r'(\s*)(\()', bygroups(Keyword, Name.Function, Text, Operator)), + (r'[^\S\n]+', Text), + (r'//.*?\n', Comment.Single), + (r'/\*.*?\*/', Comment.Multiline), + (r'@[a-zA-Z_][\w.]*', Name.Decorator), + (r'(break|case|catch|next|default|do|else|finally|for|foreach|of|' + r'unless|if|new|return|switch|me|throw|try|while)\b', Keyword), + (r'(extends|private|protected|public|static|throws|function|method|' + r'operator)\b', Keyword.Declaration), + (r'(true|false|null|__FILE__|__LINE__|__VERSION__|__LIB_PATH__|' + r'__INC_PATH__)\b', Keyword.Constant), + (r'(class|struct)(\s+)', + bygroups(Keyword.Declaration, Text), 'class'), + (r'(import|include)(\s+)', + bygroups(Keyword.Namespace, Text), 'import'), + (words(( + 'gc_collect', 'gc_mm_items', 'gc_mm_usage', 'gc_collect_threshold', + 'urlencode', 'urldecode', 'base64encode', 'base64decode', 'sha1', 'crc32', 'sha2', + 'md5', 'md5_file', 'acos', 'asin', 'atan', 'atan2', 'ceil', 'cos', 'cosh', 'exp', + 'fabs', 'floor', 'fmod', 'log', 'log10', 'pow', 'sin', 'sinh', 'sqrt', 'tan', 'tanh', + 'isint', 'isfloat', 'ischar', 'isstring', 'isarray', 'ismap', 'isalias', 'typeof', + 'sizeof', 'toint', 'tostring', 'fromxml', 'toxml', 'binary', 'pack', 'load', 'eval', + 'var_names', 'var_values', 'user_functions', 'dyn_functions', 'methods', 'call', + 'call_method', 'mknod', 'mkfifo', 'mount', 'umount2', 'umount', 'ticks', 'usleep', + 'sleep', 'time', 'strtime', 'strdate', 'dllopen', 'dlllink', 'dllcall', 'dllcall_argv', + 'dllclose', 'env', 'exec', 'fork', 'getpid', 'wait', 'popen', 'pclose', 'exit', 'kill', + 'pthread_create', 'pthread_create_argv', 'pthread_exit', 'pthread_join', 'pthread_kill', + 'smtp_send', 'http_get', 'http_post', 'http_download', 'socket', 'bind', 'listen', + 'accept', 'getsockname', 'getpeername', 'settimeout', 'connect', 'server', 'recv', + 'send', 'close', 'print', 'println', 'printf', 'input', 'readline', 'serial_open', + 'serial_fcntl', 'serial_get_attr', 'serial_get_ispeed', 'serial_get_ospeed', + 'serial_set_attr', 'serial_set_ispeed', 'serial_set_ospeed', 'serial_write', + 'serial_read', 'serial_close', 'xml_load', 'xml_parse', 'fopen', 'fseek', 'ftell', + 'fsize', 'fread', 'fwrite', 'fgets', 'fclose', 'file', 'readdir', 'pcre_replace', 'size', + 'pop', 'unmap', 'has', 'keys', 'values', 'length', 'find', 'substr', 'replace', 'split', + 'trim', 'remove', 'contains', 'join'), suffix=r'\b'), + Name.Builtin), + (words(( + 'MethodReference', 'Runner', 'Dll', 'Thread', 'Pipe', 'Process', + 'Runnable', 'CGI', 'ClientSocket', 'Socket', 'ServerSocket', + 'File', 'Console', 'Directory', 'Exception'), suffix=r'\b'), + Keyword.Type), + (r'"(\\\\|\\"|[^"])*"', String), + (r"'\\.'|'[^\\]'|'\\u[0-9a-f]{4}'", String.Char), + (r'(\.)([a-zA-Z_]\w*)', + bygroups(Operator, Name.Attribute)), + (r'[a-zA-Z_]\w*:', Name.Label), + (r'[a-zA-Z_$]\w*', Name), + (r'[~^*!%&\[\](){}<>|+=:;,./?\-@]+', Operator), + (r'[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float), + (r'0x[0-9a-f]+', Number.Hex), + (r'[0-9]+L?', Number.Integer), + (r'\n', Text), + ], + 'class': [ + (r'[a-zA-Z_]\w*', Name.Class, '#pop') + ], + 'import': [ + (r'[\w.]+\*?', Name.Namespace, '#pop') + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/shell.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/shell.py new file mode 100644 index 0000000000..1bbfd7a7e5 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/shell.py @@ -0,0 +1,437 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.shell + ~~~~~~~~~~~~~~~~~~~~~ + + Lexers for various shells. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer, RegexLexer, do_insertions, bygroups, include +from pygments.token import Punctuation, \ + Text, Comment, Operator, Keyword, Name, String, Number, Generic +from pygments.util import shebang_matches + + +__all__ = ['BashLexer', 'BashSessionLexer', 'TcshLexer', 'BatchLexer', + 'PowerShellLexer', 'ShellSessionLexer'] + +line_re = re.compile('.*?\n') + + +class BashLexer(RegexLexer): + """ + Lexer for (ba|k|)sh shell scripts. + + .. versionadded:: 0.6 + """ + + name = 'Bash' + aliases = ['bash', 'sh', 'ksh', 'shell'] + filenames = ['*.sh', '*.ksh', '*.bash', '*.ebuild', '*.eclass', + '.bashrc', 'bashrc', '.bash_*', 'bash_*', 'PKGBUILD'] + mimetypes = ['application/x-sh', 'application/x-shellscript'] + + tokens = { + 'root': [ + include('basic'), + (r'`', String.Backtick, 'backticks'), + include('data'), + include('interp'), + ], + 'interp': [ + (r'\$\(\(', Keyword, 'math'), + (r'\$\(', Keyword, 'paren'), + (r'\$\{#?', String.Interpol, 'curly'), + (r'\$#?(\w+|.)', Name.Variable), + ], + 'basic': [ + (r'\b(if|fi|else|while|do|done|for|then|return|function|case|' + r'select|continue|until|esac|elif)(\s*)\b', + bygroups(Keyword, Text)), + (r'\b(alias|bg|bind|break|builtin|caller|cd|command|compgen|' + r'complete|declare|dirs|disown|echo|enable|eval|exec|exit|' + r'export|false|fc|fg|getopts|hash|help|history|jobs|kill|let|' + r'local|logout|popd|printf|pushd|pwd|read|readonly|set|shift|' + r'shopt|source|suspend|test|time|times|trap|true|type|typeset|' + r'ulimit|umask|unalias|unset|wait)\s*\b(?!\.)', + Name.Builtin), + (r'#.*\n', Comment), + (r'\\[\w\W]', String.Escape), + (r'(\b\w+)(\s*)(=)', bygroups(Name.Variable, Text, Operator)), + (r'[\[\]{}()=]', Operator), + (r'<<<', Operator), # here-string + (r'<<-?\s*(\'?)\\?(\w+)[\w\W]+?\2', String), + (r'&&|\|\|', Operator), + ], + 'data': [ + (r'(?s)\$?"(\\\\|\\[0-7]+|\\.|[^"\\$])*"', String.Double), + (r'"', String.Double, 'string'), + (r"(?s)\$'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single), + (r"(?s)'.*?'", String.Single), + (r';', Punctuation), + (r'&', Punctuation), + (r'\|', Punctuation), + (r'\s+', Text), + (r'\d+(?= |\Z)', Number), + (r'[^=\s\[\]{}()$"\'`\\<&|;]+', Text), + (r'<', Text), + ], + 'string': [ + (r'"', String.Double, '#pop'), + (r'(?s)(\\\\|\\[0-7]+|\\.|[^"\\$])+', String.Double), + include('interp'), + ], + 'curly': [ + (r'\}', String.Interpol, '#pop'), + (r':-', Keyword), + (r'\w+', Name.Variable), + (r'[^}:"\'`$\\]+', Punctuation), + (r':', Punctuation), + include('root'), + ], + 'paren': [ + (r'\)', Keyword, '#pop'), + include('root'), + ], + 'math': [ + (r'\)\)', Keyword, '#pop'), + (r'[-+*/%^|&]|\*\*|\|\|', Operator), + (r'\d+#\d+', Number), + (r'\d+#(?! )', Number), + (r'\d+', Number), + include('root'), + ], + 'backticks': [ + (r'`', String.Backtick, '#pop'), + include('root'), + ], + } + + def analyse_text(text): + if shebang_matches(text, r'(ba|z|)sh'): + return 1 + if text.startswith('$ '): + return 0.2 + + +class BashSessionLexer(Lexer): + """ + Lexer for simplistic shell sessions. + + .. versionadded:: 1.1 + """ + + name = 'Bash Session' + aliases = ['console'] + filenames = ['*.sh-session'] + mimetypes = ['application/x-shell-session'] + + def get_tokens_unprocessed(self, text): + bashlexer = BashLexer(**self.options) + + pos = 0 + curcode = '' + insertions = [] + + for match in line_re.finditer(text): + line = match.group() + m = re.match(r'^((?:\(\S+\))?(?:|sh\S*?|\w+\S+[@:]\S+(?:\s+\S+)' + r'?|\[\S+[@:][^\n]+\].+)[$#%])(.*\n?)' , line) + if m: + # To support output lexers (say diff output), the output + # needs to be broken by prompts whenever the output lexer + # changes. + if not insertions: + pos = match.start() + + insertions.append((len(curcode), + [(0, Generic.Prompt, m.group(1))])) + curcode += m.group(2) + elif line.startswith('>'): + insertions.append((len(curcode), + [(0, Generic.Prompt, line[:1])])) + curcode += line[1:] + else: + if insertions: + toks = bashlexer.get_tokens_unprocessed(curcode) + for i, t, v in do_insertions(insertions, toks): + yield pos+i, t, v + yield match.start(), Generic.Output, line + insertions = [] + curcode = '' + if insertions: + for i, t, v in do_insertions(insertions, + bashlexer.get_tokens_unprocessed(curcode)): + yield pos+i, t, v + + +class ShellSessionLexer(Lexer): + """ + Lexer for shell sessions that works with different command prompts + + .. versionadded:: 1.6 + """ + + name = 'Shell Session' + aliases = ['shell-session'] + filenames = ['*.shell-session'] + mimetypes = ['application/x-sh-session'] + + def get_tokens_unprocessed(self, text): + bashlexer = BashLexer(**self.options) + + pos = 0 + curcode = '' + insertions = [] + + for match in line_re.finditer(text): + line = match.group() + m = re.match(r'^((?:\[?\S+@[^$#%]+\]?\s*)[$#%])(.*\n?)', line) + if m: + # To support output lexers (say diff output), the output + # needs to be broken by prompts whenever the output lexer + # changes. + if not insertions: + pos = match.start() + + insertions.append((len(curcode), + [(0, Generic.Prompt, m.group(1))])) + curcode += m.group(2) + else: + if insertions: + toks = bashlexer.get_tokens_unprocessed(curcode) + for i, t, v in do_insertions(insertions, toks): + yield pos+i, t, v + yield match.start(), Generic.Output, line + insertions = [] + curcode = '' + if insertions: + for i, t, v in do_insertions(insertions, + bashlexer.get_tokens_unprocessed(curcode)): + yield pos+i, t, v + + +class BatchLexer(RegexLexer): + """ + Lexer for the DOS/Windows Batch file format. + + .. versionadded:: 0.7 + """ + name = 'Batchfile' + aliases = ['bat', 'batch', 'dosbatch', 'winbatch'] + filenames = ['*.bat', '*.cmd'] + mimetypes = ['application/x-dos-batch'] + + flags = re.MULTILINE | re.IGNORECASE + + tokens = { + 'root': [ + # Lines can start with @ to prevent echo + (r'^\s*@', Punctuation), + (r'^(\s*)(rem\s.*)$', bygroups(Text, Comment)), + (r'".*?"', String.Double), + (r"'.*?'", String.Single), + # If made more specific, make sure you still allow expansions + # like %~$VAR:zlt + (r'%%?[~$:\w]+%?', Name.Variable), + (r'::.*', Comment), # Technically :: only works at BOL + (r'\b(set)(\s+)(\w+)', bygroups(Keyword, Text, Name.Variable)), + (r'\b(call)(\s+)(:\w+)', bygroups(Keyword, Text, Name.Label)), + (r'\b(goto)(\s+)(\w+)', bygroups(Keyword, Text, Name.Label)), + (r'\b(set|call|echo|on|off|endlocal|for|do|goto|if|pause|' + r'setlocal|shift|errorlevel|exist|defined|cmdextversion|' + r'errorlevel|else|cd|md|del|deltree|cls|choice)\b', Keyword), + (r'\b(equ|neq|lss|leq|gtr|geq)\b', Operator), + include('basic'), + (r'.', Text), + ], + 'echo': [ + # Escapes only valid within echo args? + (r'\^\^|\^<|\^>|\^\|', String.Escape), + (r'\n', Text, '#pop'), + include('basic'), + (r'[^\'"^]+', Text), + ], + 'basic': [ + (r'".*?"', String.Double), + (r"'.*?'", String.Single), + (r'`.*?`', String.Backtick), + (r'-?\d+', Number), + (r',', Punctuation), + (r'=', Operator), + (r'/\S+', Name), + (r':\w+', Name.Label), + (r'\w:\w+', Text), + (r'([<>|])(\s*)(\w+)', bygroups(Punctuation, Text, Name)), + ], + } + + +class TcshLexer(RegexLexer): + """ + Lexer for tcsh scripts. + + .. versionadded:: 0.10 + """ + + name = 'Tcsh' + aliases = ['tcsh', 'csh'] + filenames = ['*.tcsh', '*.csh'] + mimetypes = ['application/x-csh'] + + tokens = { + 'root': [ + include('basic'), + (r'\$\(', Keyword, 'paren'), + (r'\$\{#?', Keyword, 'curly'), + (r'`', String.Backtick, 'backticks'), + include('data'), + ], + 'basic': [ + (r'\b(if|endif|else|while|then|foreach|case|default|' + r'continue|goto|breaksw|end|switch|endsw)\s*\b', + Keyword), + (r'\b(alias|alloc|bg|bindkey|break|builtins|bye|caller|cd|chdir|' + r'complete|dirs|echo|echotc|eval|exec|exit|fg|filetest|getxvers|' + r'glob|getspath|hashstat|history|hup|inlib|jobs|kill|' + r'limit|log|login|logout|ls-F|migrate|newgrp|nice|nohup|notify|' + r'onintr|popd|printenv|pushd|rehash|repeat|rootnode|popd|pushd|' + r'set|shift|sched|setenv|setpath|settc|setty|setxvers|shift|' + r'source|stop|suspend|source|suspend|telltc|time|' + r'umask|unalias|uncomplete|unhash|universe|unlimit|unset|unsetenv|' + r'ver|wait|warp|watchlog|where|which)\s*\b', + Name.Builtin), + (r'#.*', Comment), + (r'\\[\w\W]', String.Escape), + (r'(\b\w+)(\s*)(=)', bygroups(Name.Variable, Text, Operator)), + (r'[\[\]{}()=]+', Operator), + (r'<<\s*(\'?)\\?(\w+)[\w\W]+?\2', String), + (r';', Punctuation), + ], + 'data': [ + (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double), + (r"(?s)'(\\\\|\\[0-7]+|\\.|[^'\\])*'", String.Single), + (r'\s+', Text), + (r'[^=\s\[\]{}()$"\'`\\;#]+', Text), + (r'\d+(?= |\Z)', Number), + (r'\$#?(\w+|.)', Name.Variable), + ], + 'curly': [ + (r'\}', Keyword, '#pop'), + (r':-', Keyword), + (r'\w+', Name.Variable), + (r'[^}:"\'`$]+', Punctuation), + (r':', Punctuation), + include('root'), + ], + 'paren': [ + (r'\)', Keyword, '#pop'), + include('root'), + ], + 'backticks': [ + (r'`', String.Backtick, '#pop'), + include('root'), + ], + } + + +class PowerShellLexer(RegexLexer): + """ + For Windows PowerShell code. + + .. versionadded:: 1.5 + """ + name = 'PowerShell' + aliases = ['powershell', 'posh', 'ps1', 'psm1'] + filenames = ['*.ps1','*.psm1'] + mimetypes = ['text/x-powershell'] + + flags = re.DOTALL | re.IGNORECASE | re.MULTILINE + + keywords = ( + 'while validateset validaterange validatepattern validatelength ' + 'validatecount until trap switch return ref process param parameter in ' + 'if global: function foreach for finally filter end elseif else ' + 'dynamicparam do default continue cmdletbinding break begin alias \\? ' + '% #script #private #local #global mandatory parametersetname position ' + 'valuefrompipeline valuefrompipelinebypropertyname ' + 'valuefromremainingarguments helpmessage try catch throw').split() + + operators = ( + 'and as band bnot bor bxor casesensitive ccontains ceq cge cgt cle ' + 'clike clt cmatch cne cnotcontains cnotlike cnotmatch contains ' + 'creplace eq exact f file ge gt icontains ieq ige igt ile ilike ilt ' + 'imatch ine inotcontains inotlike inotmatch ireplace is isnot le like ' + 'lt match ne not notcontains notlike notmatch or regex replace ' + 'wildcard').split() + + verbs = ( + 'write where wait use update unregister undo trace test tee take ' + 'suspend stop start split sort skip show set send select scroll resume ' + 'restore restart resolve resize reset rename remove register receive ' + 'read push pop ping out new move measure limit join invoke import ' + 'group get format foreach export expand exit enter enable disconnect ' + 'disable debug cxnew copy convertto convertfrom convert connect ' + 'complete compare clear checkpoint aggregate add').split() + + commenthelp = ( + 'component description example externalhelp forwardhelpcategory ' + 'forwardhelptargetname functionality inputs link ' + 'notes outputs parameter remotehelprunspace role synopsis').split() + + tokens = { + 'root': [ + # we need to count pairs of parentheses for correct highlight + # of '$(...)' blocks in strings + (r'\(', Punctuation, 'child'), + (r'\s+', Text), + (r'^(\s*#[#\s]*)(\.(?:%s))([^\n]*$)' % '|'.join(commenthelp), + bygroups(Comment, String.Doc, Comment)), + (r'#[^\n]*?$', Comment), + (r'(<|<)#', Comment.Multiline, 'multline'), + (r'@"\n', String.Heredoc, 'heredoc-double'), + (r"@'\n.*?\n'@", String.Heredoc), + # escaped syntax + (r'`[\'"$@-]', Punctuation), + (r'"', String.Double, 'string'), + (r"'([^']|'')*'", String.Single), + (r'(\$|@@|@)((global|script|private|env):)?\w+', + Name.Variable), + (r'(%s)\b' % '|'.join(keywords), Keyword), + (r'-(%s)\b' % '|'.join(operators), Operator), + (r'(%s)-[a-z_]\w*\b' % '|'.join(verbs), Name.Builtin), + (r'\[[a-z_\[][\w. `,\[\]]*\]', Name.Constant), # .net [type]s + (r'-[a-z_]\w*', Name), + (r'\w+', Name), + (r'[.,;@{}\[\]$()=+*/\\&%!~?^`|<>-]|::', Punctuation), + ], + 'child': [ + (r'\)', Punctuation, '#pop'), + include('root'), + ], + 'multline': [ + (r'[^#&.]+', Comment.Multiline), + (r'#(>|>)', Comment.Multiline, '#pop'), + (r'\.(%s)' % '|'.join(commenthelp), String.Doc), + (r'[#&.]', Comment.Multiline), + ], + 'string': [ + (r"`[0abfnrtv'\"$`]", String.Escape), + (r'[^$`"]+', String.Double), + (r'\$\(', Punctuation, 'child'), + (r'""', String.Double), + (r'[`$]', String.Double), + (r'"', String.Double, '#pop'), + ], + 'heredoc-double': [ + (r'\n"@', String.Heredoc, '#pop'), + (r'\$\(', Punctuation, 'child'), + (r'[^@\n]+"]', String.Heredoc), + (r".", String.Heredoc), + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/smalltalk.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/smalltalk.py new file mode 100644 index 0000000000..4e78ac073a --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/smalltalk.py @@ -0,0 +1,195 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.smalltalk + ~~~~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for Smalltalk and related languages. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, include, bygroups, default +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['SmalltalkLexer', 'NewspeakLexer'] + + +class SmalltalkLexer(RegexLexer): + """ + For `Smalltalk `_ syntax. + Contributed by Stefan Matthias Aust. + Rewritten by Nils Winter. + + .. versionadded:: 0.10 + """ + name = 'Smalltalk' + filenames = ['*.st'] + aliases = ['smalltalk', 'squeak', 'st'] + mimetypes = ['text/x-smalltalk'] + + tokens = { + 'root': [ + (r'(<)(\w+:)(.*?)(>)', bygroups(Text, Keyword, Text, Text)), + include('squeak fileout'), + include('whitespaces'), + include('method definition'), + (r'(\|)([\w\s]*)(\|)', bygroups(Operator, Name.Variable, Operator)), + include('objects'), + (r'\^|\:=|\_', Operator), + # temporaries + (r'[\]({}.;!]', Text), + ], + 'method definition': [ + # Not perfect can't allow whitespaces at the beginning and the + # without breaking everything + (r'([a-zA-Z]+\w*:)(\s*)(\w+)', + bygroups(Name.Function, Text, Name.Variable)), + (r'^(\b[a-zA-Z]+\w*\b)(\s*)$', bygroups(Name.Function, Text)), + (r'^([-+*/\\~<>=|&!?,@%]+)(\s*)(\w+)(\s*)$', + bygroups(Name.Function, Text, Name.Variable, Text)), + ], + 'blockvariables': [ + include('whitespaces'), + (r'(:)(\s*)(\w+)', + bygroups(Operator, Text, Name.Variable)), + (r'\|', Operator, '#pop'), + default('#pop'), # else pop + ], + 'literals': [ + (r"'(''|[^'])*'", String, 'afterobject'), + (r'\$.', String.Char, 'afterobject'), + (r'#\(', String.Symbol, 'parenth'), + (r'\)', Text, 'afterobject'), + (r'(\d+r)?-?\d+(\.\d+)?(e-?\d+)?', Number, 'afterobject'), + ], + '_parenth_helper': [ + include('whitespaces'), + (r'(\d+r)?-?\d+(\.\d+)?(e-?\d+)?', Number), + (r'[-+*/\\~<>=|&#!?,@%\w:]+', String.Symbol), + # literals + (r"'(''|[^'])*'", String), + (r'\$.', String.Char), + (r'#*\(', String.Symbol, 'inner_parenth'), + ], + 'parenth': [ + # This state is a bit tricky since + # we can't just pop this state + (r'\)', String.Symbol, ('root', 'afterobject')), + include('_parenth_helper'), + ], + 'inner_parenth': [ + (r'\)', String.Symbol, '#pop'), + include('_parenth_helper'), + ], + 'whitespaces': [ + # skip whitespace and comments + (r'\s+', Text), + (r'"(""|[^"])*"', Comment), + ], + 'objects': [ + (r'\[', Text, 'blockvariables'), + (r'\]', Text, 'afterobject'), + (r'\b(self|super|true|false|nil|thisContext)\b', + Name.Builtin.Pseudo, 'afterobject'), + (r'\b[A-Z]\w*(?!:)\b', Name.Class, 'afterobject'), + (r'\b[a-z]\w*(?!:)\b', Name.Variable, 'afterobject'), + (r'#("(""|[^"])*"|[-+*/\\~<>=|&!?,@%]+|[\w:]+)', + String.Symbol, 'afterobject'), + include('literals'), + ], + 'afterobject': [ + (r'! !$', Keyword, '#pop'), # squeak chunk delimiter + include('whitespaces'), + (r'\b(ifTrue:|ifFalse:|whileTrue:|whileFalse:|timesRepeat:)', + Name.Builtin, '#pop'), + (r'\b(new\b(?!:))', Name.Builtin), + (r'\:=|\_', Operator, '#pop'), + (r'\b[a-zA-Z]+\w*:', Name.Function, '#pop'), + (r'\b[a-zA-Z]+\w*', Name.Function), + (r'\w+:?|[-+*/\\~<>=|&!?,@%]+', Name.Function, '#pop'), + (r'\.', Punctuation, '#pop'), + (r';', Punctuation), + (r'[\])}]', Text), + (r'[\[({]', Text, '#pop'), + ], + 'squeak fileout': [ + # Squeak fileout format (optional) + (r'^"(""|[^"])*"!', Keyword), + (r"^'(''|[^'])*'!", Keyword), + (r'^(!)(\w+)( commentStamp: )(.*?)( prior: .*?!\n)(.*?)(!)', + bygroups(Keyword, Name.Class, Keyword, String, Keyword, Text, Keyword)), + (r"^(!)(\w+(?: class)?)( methodsFor: )('(?:''|[^'])*')(.*?!)", + bygroups(Keyword, Name.Class, Keyword, String, Keyword)), + (r'^(\w+)( subclass: )(#\w+)' + r'(\s+instanceVariableNames: )(.*?)' + r'(\s+classVariableNames: )(.*?)' + r'(\s+poolDictionaries: )(.*?)' + r'(\s+category: )(.*?)(!)', + bygroups(Name.Class, Keyword, String.Symbol, Keyword, String, Keyword, + String, Keyword, String, Keyword, String, Keyword)), + (r'^(\w+(?: class)?)(\s+instanceVariableNames: )(.*?)(!)', + bygroups(Name.Class, Keyword, String, Keyword)), + (r'(!\n)(\].*)(! !)$', bygroups(Keyword, Text, Keyword)), + (r'! !$', Keyword), + ], + } + + +class NewspeakLexer(RegexLexer): + """ + For `Newspeak ` syntax. + + .. versionadded:: 1.1 + """ + name = 'Newspeak' + filenames = ['*.ns2'] + aliases = ['newspeak', ] + mimetypes = ['text/x-newspeak'] + + tokens = { + 'root': [ + (r'\b(Newsqueak2)\b', Keyword.Declaration), + (r"'[^']*'", String), + (r'\b(class)(\s+)(\w+)(\s*)', + bygroups(Keyword.Declaration, Text, Name.Class, Text)), + (r'\b(mixin|self|super|private|public|protected|nil|true|false)\b', + Keyword), + (r'(\w+\:)(\s*)([a-zA-Z_]\w+)', + bygroups(Name.Function, Text, Name.Variable)), + (r'(\w+)(\s*)(=)', + bygroups(Name.Attribute, Text, Operator)), + (r'<\w+>', Comment.Special), + include('expressionstat'), + include('whitespace') + ], + + 'expressionstat': [ + (r'(\d+\.\d*|\.\d+|\d+[fF])[fF]?', Number.Float), + (r'\d+', Number.Integer), + (r':\w+', Name.Variable), + (r'(\w+)(::)', bygroups(Name.Variable, Operator)), + (r'\w+:', Name.Function), + (r'\w+', Name.Variable), + (r'\(|\)', Punctuation), + (r'\[|\]', Punctuation), + (r'\{|\}', Punctuation), + + (r'(\^|\+|\/|~|\*|<|>|=|@|%|\||&|\?|!|,|-|:)', Operator), + (r'\.|;', Punctuation), + include('whitespace'), + include('literals'), + ], + 'literals': [ + (r'\$.', String), + (r"'[^']*'", String), + (r"#'[^']*'", String.Symbol), + (r"#\w+:?", String.Symbol), + (r"#(\+|\/|~|\*|<|>|=|@|%|\||&|\?|!|,|-)+", String.Symbol) + ], + 'whitespace': [ + (r'\s+', Text), + (r'"[^"]*"', Comment) + ], + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/snobol.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/snobol.py new file mode 100644 index 0000000000..88455f93c8 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/snobol.py @@ -0,0 +1,83 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.snobol + ~~~~~~~~~~~~~~~~~~~~~~ + + Lexers for the SNOBOL language. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +from pygments.lexer import RegexLexer, bygroups +from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ + Number, Punctuation + +__all__ = ['SnobolLexer'] + + +class SnobolLexer(RegexLexer): + """ + Lexer for the SNOBOL4 programming language. + + Recognizes the common ASCII equivalents of the original SNOBOL4 operators. + Does not require spaces around binary operators. + + .. versionadded:: 1.5 + """ + + name = "Snobol" + aliases = ["snobol"] + filenames = ['*.snobol'] + mimetypes = ['text/x-snobol'] + + tokens = { + # root state, start of line + # comments, continuation lines, and directives start in column 1 + # as do labels + 'root': [ + (r'\*.*\n', Comment), + (r'[+.] ', Punctuation, 'statement'), + (r'-.*\n', Comment), + (r'END\s*\n', Name.Label, 'heredoc'), + (r'[A-Za-z$][\w$]*', Name.Label, 'statement'), + (r'\s+', Text, 'statement'), + ], + # statement state, line after continuation or label + 'statement': [ + (r'\s*\n', Text, '#pop'), + (r'\s+', Text), + (r'(?<=[^\w.])(LT|LE|EQ|NE|GE|GT|INTEGER|IDENT|DIFFER|LGT|SIZE|' + r'REPLACE|TRIM|DUPL|REMDR|DATE|TIME|EVAL|APPLY|OPSYN|LOAD|UNLOAD|' + r'LEN|SPAN|BREAK|ANY|NOTANY|TAB|RTAB|REM|POS|RPOS|FAIL|FENCE|' + r'ABORT|ARB|ARBNO|BAL|SUCCEED|INPUT|OUTPUT|TERMINAL)(?=[^\w.])', + Name.Builtin), + (r'[A-Za-z][\w.]*', Name), + # ASCII equivalents of original operators + # | for the EBCDIC equivalent, ! likewise + # \ for EBCDIC negation + (r'\*\*|[?$.!%*/#+\-@|&\\=]', Operator), + (r'"[^"]*"', String), + (r"'[^']*'", String), + # Accept SPITBOL syntax for real numbers + # as well as Macro SNOBOL4 + (r'[0-9]+(?=[^.EeDd])', Number.Integer), + (r'[0-9]+(\.[0-9]*)?([EDed][-+]?[0-9]+)?', Number.Float), + # Goto + (r':', Punctuation, 'goto'), + (r'[()<>,;]', Punctuation), + ], + # Goto block + 'goto': [ + (r'\s*\n', Text, "#pop:2"), + (r'\s+', Text), + (r'F|S', Keyword), + (r'(\()([A-Za-z][\w.]*)(\))', + bygroups(Punctuation, Name.Label, Punctuation)) + ], + # everything after the END statement is basically one + # big heredoc. + 'heredoc': [ + (r'.*\n', String.Heredoc) + ] + } diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/special.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/special.py new file mode 100644 index 0000000000..bd86904432 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/special.py @@ -0,0 +1,100 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.special + ~~~~~~~~~~~~~~~~~~~~~~~ + + Special lexers. + + :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. + :license: BSD, see LICENSE for details. +""" + +import re + +from pygments.lexer import Lexer +from pygments.token import Token, Error, Text +from pygments.util import get_choice_opt, text_type, BytesIO + + +__all__ = ['TextLexer', 'RawTokenLexer'] + + +class TextLexer(Lexer): + """ + "Null" lexer, doesn't highlight anything. + """ + name = 'Text only' + aliases = ['text'] + filenames = ['*.txt'] + mimetypes = ['text/plain'] + + def get_tokens_unprocessed(self, text): + yield 0, Text, text + + +_ttype_cache = {} + +line_re = re.compile(b'.*?\n') + + +class RawTokenLexer(Lexer): + """ + Recreate a token stream formatted with the `RawTokenFormatter`. This + lexer raises exceptions during parsing if the token stream in the + file is malformed. + + Additional options accepted: + + `compress` + If set to ``"gz"`` or ``"bz2"``, decompress the token stream with + the given compression algorithm before lexing (default: ``""``). + """ + name = 'Raw token data' + aliases = ['raw'] + filenames = [] + mimetypes = ['application/x-pygments-tokens'] + + def __init__(self, **options): + self.compress = get_choice_opt(options, 'compress', + ['', 'none', 'gz', 'bz2'], '') + Lexer.__init__(self, **options) + + def get_tokens(self, text): + if isinstance(text, text_type): + # raw token stream never has any non-ASCII characters + text = text.encode('ascii') + if self.compress == 'gz': + import gzip + gzipfile = gzip.GzipFile('', 'rb', 9, BytesIO(text)) + text = gzipfile.read() + elif self.compress == 'bz2': + import bz2 + text = bz2.decompress(text) + + # do not call Lexer.get_tokens() because we do not want Unicode + # decoding to occur, and stripping is not optional. + text = text.strip(b'\n') + b'\n' + for i, t, v in self.get_tokens_unprocessed(text): + yield t, v + + def get_tokens_unprocessed(self, text): + length = 0 + for match in line_re.finditer(text): + try: + ttypestr, val = match.group().split(b'\t', 1) + except ValueError: + val = match.group().decode('ascii', 'replace') + ttype = Error + else: + ttype = _ttype_cache.get(ttypestr) + if not ttype: + ttype = Token + ttypes = ttypestr.split('.')[1:] + for ttype_ in ttypes: + if not ttype_ or not ttype_[0].isupper(): + raise ValueError('malformed token name') + ttype = getattr(ttype, ttype_) + _ttype_cache[ttypestr] = ttype + val = val[2:-2].decode('unicode-escape') + yield length, ttype, val + length += len(val) diff --git a/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/sql.py b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/sql.py new file mode 100644 index 0000000000..98425cd298 --- /dev/null +++ b/sources_non_forked/vim-wakatime/plugin/packages/wakatime/packages/pygments_py2/pygments/lexers/sql.py @@ -0,0 +1,598 @@ +# -*- coding: utf-8 -*- +""" + pygments.lexers.sql + ~~~~~~~~~~~~~~~~~~~ + + Lexers for various SQL dialects and related interactive sessions. + + Postgres specific lexers: + + `PostgresLexer` + A SQL lexer for the PostgreSQL dialect. Differences w.r.t. the SQL + lexer are: + + - keywords and data types list parsed from the PG docs (run the + `_postgres_builtins` module to update them); + - Content of $-strings parsed using a specific lexer, e.g. the content + of a PL/Python function is parsed using the Python lexer; + - parse PG specific constructs: E-strings, $-strings, U&-strings, + different operators and punctuation. + + `PlPgsqlLexer` + A lexer for the PL/pgSQL language. Adds a few specific construct on + top of the PG SQL lexer (such as <