summaryrefslogtreecommitdiff
path: root/pygments
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | tcl lexer: no error for @ or , (#1834)Akuli2021-06-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * tcl lexer: no error for @ or , * examplefiles --> snippets * rename test file to convention
* | | | Remove unicorn token types (fixes #1816.)Matthäus G. Chajdas2021-06-206-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | The PR #1819 provides a tool to identify unique token types. This PR aims to remove the most obvious cases of unicorn styles which are used in a single lexer only.
* | | | Add procfile lexer (#1808)sblondon2021-06-202-0/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add Procfile Lexer * add unit tests for ProcfileLexer * add Procfile lexer author * Document Procfile as supported language * add Procfile.output file * merge Profile files; update output file * Add versionadded info * Fix typo (processus -> processes) * detect Integer only * split Text from Whitespace
* | | | Use the correct whitespace token for the C family.Matthäus G. Chajdas2021-06-201-3/+3
| | | | | | | | | | | | | | | | The CFamilyLexer was matching whitespace as Text instead of Whitespace.
* | | | Fix CFamilyLexer preprocessor tokenization errors (#1830)Henrik Lievonen2021-06-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CFamilyLexer failed to tokenize preprocessor macros when they were preceded by line break surrounded by spaces. This was the case because prerpocessor regex rule expected to start at the beginning of the line, but the space regex rule matched also the whitespace after the line break. Now the space rule has been refined not to match the line break. Because of this, the preprocessor regex rule correctly matches prerpocessor tokens even when they are preceded by white spaces, at the cost of adding some more tokens in the token stream in some cases. This change preserves the behavior of invalid preprocessor usage failing to tokenize.
* | | | Small updates to the meson lexer.Matthäus G. Chajdas2021-06-201-1/+3
| | | |
* | | | Add Meson build language support (#1823)ldrumm2021-06-202-0/+154
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add a Meson language lexer * update the mappings * Add meson to the list of supported languages * Add a meson.build example file
* | | | Added Swift concurrency keywords (#1842)Filip Němeček2021-06-201-2/+2
| | | |
* | | | Rust: fix lexing of "break" and "continue"Georg Brandl2021-06-201-1/+1
| | | | | | | | | | | | | | | | fixes #1843
* | | | Add lexers.specials.OutputLexer. (#1836)Walter Dörwald2021-06-072-2/+16
| | | |
* | | | Correctly highlight multiline console input, even without PS2 prompt (#1833)Jesse Tan2021-06-041-4/+7
| | | |
* | | | Add golang alias for the Go language (#1827)Situphen2021-05-312-2/+2
| | | |
* | | | Update LLVM lexer to use keywords of LLVM 12.0. (#1824)Fraser Cormack2021-05-311-57/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The keywords are based on the extraction of keywords the LLVM 12.0 lexer source code. They were taken from the `KEYWORD` and `INSTKEYWORD` macros for the 'Keyword' tokens, and 'Type' tokens were from the `TYPEKEYWORD` macro. The keywords were then sorted against the current set. Due to formatting issues in the arrays, the actual Type diff is: ``` diff +x86_mmx +x86_amx ``` and the Keyword diff is: ``` diff +aarch64_sve_vector_pcs +aarch64_vector_pcs +alwaysInline +amdgpu_gfx +blockcount +byref +callbr +canAutoHide +cfguard_checkcc +dso_local_equivalent +fneg +mustprogress +nocallback +nofree +noInline +nomerge +noprofile +nosync +noundef +null_pointer_is_valid +param +params +partition +preallocated +sanitize_memtag +speculative_load_hardening +tailcc +typeidCompatibleVTable +varFlags +vcall_visibility +virtFunc +vscale +vTableFuncs +x ```
* | | | TNT: fix reliance on "assert" stmt, handle recursionGeorg Brandl2021-05-301-15/+25
|/ / /
* | | Prepare 2.9.0 release.2.9.0Matthäus G. Chajdas2021-05-031-1/+1
| | |
* | | Add support for elixir phoenix leex templates (#1577)Jason S2021-05-022-2/+2
| | |
* | | groovy lexer: detect quoted function names (#1765)Alison Winters2021-05-021-6/+12
| | | | | | | | | | | | | | | | | | | | | * groovy lexer: parse keywords before function names like java * groovy lexer: detect quoted function names * changes: update groovy lexer
* | | encode `str` into `bytes` for `_lookup_ctag` argument; (#1724)Cyker Way2021-05-021-1/+1
| | | | | | | | | | | | | | | | | | check source code of `python-ctags` and `python-ctags3` to see what argument type is expected (answer: `char *`); guess this is python 2 legacy; but now it should work in python 3;
* | | Support Terraform 0.14 syntax (#1756)Leonardo Giordani2021-05-021-36/+93
| | | | | | | | | | | | | | | * Support Terraform 0.14 syntax * Use \S instead of [^\s]
* | | Support for OMG IDL (#1595)Fred Hornsey2021-05-023-4/+101
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Support for OMG IDL Lexer for [Object Management Group Interface Definition Language](https://www.omg.org/spec/IDL/About-IDL/). * Allow Whitespace Before include in C Preprocessor It wasn't highlighting the included filename the same as if there was no space before the include, but now it is. * Update omg-idl Tests to Latest Requirements * Update omg-idl versionadded to 2.9 Since I just realized this missed the 2.8 release. * Add Missing Operators to omg-idl
* | | Add gruvbox styles (#1763)Aaron Moore2021-05-022-0/+109
| | | | | | | | | | | | | | | * add gruvbox light and dark themes * update changes for gruvbox style
* | | add "from" and "as" to js and ts keywords (#1741)Mestery2021-05-021-3/+3
| | | | | | | | | Also removed invalid "AS" from TypeScript lexer.
* | | uniformize aliases order (#1780)Mestery2021-04-2626-100/+100
| | | | | | | | | | | | | | | * uniformize aliases order * LighttpdConfLexer: add lighttpd.conf filename
* | | Improve PromQL lexer with new test cases (#1783)Pablo Seminario2021-04-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Fix PromQL lexer to support values enclosed within single quotes Values for labels could now be enclosed within single or double quotes. * Fix a typo into the lables regex for PromQL lexer The correct label matching operator is `!~` instead of `~!`.
* | | native: darker line numbers (#1779)Matthias Geier2021-04-191-0/+1
| | |
* | | friendly: lighter line numbers (#1778)Matthias Geier2021-04-191-0/+1
| | |
* | | Detect multiline patterns in velocity lexer text analysis (#1776)Andy2021-04-171-3/+3
| | |
* | | Fix style problems with new lexers.Georg Brandl2021-04-163-34/+38
| | |
* | | MIME lexer: remove analyse_textGeorg Brandl2021-04-161-21/+6
| | | | | | | | | | | | | | | The current implementation is broken, and it is not easy to find a good one for such a generic format.
* | | AMDGPU: Updated modifier tokenization. (#1775)Thomas Symalla2021-04-151-2/+6
| | | | | | | | | | | | | | | | | | | | | * Added new modifier tokenizer. * Add expected output for the AMDGPU test. * Used "words" function.
* | | Rust: fix raw string tokenGeorg Brandl2021-04-121-1/+1
| | | | | | | | | | | | Fixes #1771
* | | Fix python lexer parsing floats incorrectly (#1768)Liam Stevens2021-04-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | * lexers: python: add test cases for floats * lexers: python: fix float lexing * lexer:python:fixed test syntax Co-authored-by: Aidan Do <giahuydo99@gmail.com>
* | | Don't mix foreground for background in _deprecated_ansicolors lookup (#1748)Petr Viktorin2021-04-071-1/+1
| | |
* | | Swift lexer: add 'associatedtype' keyword (#1767)Lukas Kollmer2021-04-071-2/+2
| |/ |/|
* | lexers: devicetree: allow node label without root node (#1755)Gerard Marull-Paretas2021-04-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lexers: devicetree: allow node label without root node It is sometimes useful to render DeviceTree snippets such as: foo: bar@1234 { foo = "bar"; }; However the snipper shown above does not render properly unless it is enclosed on a root node, i.e. /{ foo: bar@1234 { foo = "bar"; }; }; Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no> * tests: add devicetree lexer test for fragments out of root node Signed-off-by: Gerard Marull-Paretas <gerard.marull@nordicsemi.no>
* | Fix #1416: add WebAssembly lexer (#1564)Jendrik2021-04-042-0/+121
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add WebAssembly lexer * avoid test failure by using the default function instead of an empty regex * address small issues * fix WebAssembly string escapes * change WebAssembly multiline comment parsing * update copyright year * set versionadded to 2.9 * change WebAssembly tests to use the new test system * change WebAssembly unit test to use snippets
* | PowerShell: lex ':' (#1758)amitkummer2021-03-281-1/+1
| |
* | Filename to <th> if linenos=table (fixes #1757) (#1759)Andy Pearce2021-03-281-3/+14
| | | | | | | | | | | | | | | | | | * Filename to <th> if linenos=table (fixes #1757) * Emit `<th>` for `filename` if `linenos=table`. * Added test cases for filename inclusion. * Updated CHANGES
* | Update CHANGES.Matthäus G. Chajdas2021-03-211-0/+2
| |
* | Add NestedText lexer (#1578)Kale Kundert2021-03-212-1/+25
| | | | | | | | | | | | | | | | | | * Add NestedText lexer * Add NestedText to list of supported languages * Add some more test cases * Update tests.
* | Leading underscore in APL variable names (GNU, Dyalog) (#1747)Stefan Kruger2021-03-152-4/+7
| | | | | | | | | | | | | | | | | | | | | | * Two small tweaks to the APL lexer: 1. Add all APL file suffixes 2. Allow leading _ in variable names (GNU APL, Dyalog) * Build mappings to pick up new file extensions * Add tests for APL: 1. Leading underscores for variables OK (Dyalog, GNU)
* | Update CHANGES.Matthäus G. Chajdas2021-03-141-1/+1
| | | | | | | | Also fixes the versionadded macro.
* | Add a teal lexer (#1671)iscke2021-03-142-0/+89
| | | | | | | | | | | | | | | | | | * Add a teal lexer * fix an indent * convert tests, fix version, alias * fix examplefile
* | Added ThingsDB Language support (#1295)Georg Brandl2021-03-142-0/+119
| | | | | | | | | | | | | | | | | | | | | | | | * Added ThingsDB Language support * Update ThingsDB language * add comments to syntax * Update to new test system. Co-authored-by: Jeroen van der Heijden <joente@gmail.com> Co-authored-by: Matthäus G. Chajdas <dev@anteru.net>
* | Add KuinLexer (#1300)Georg Brandl2021-03-142-0/+300
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add KuinLexer * Add golden test output. * Update mapfiles. * Update URL. * Fix regex lint failures. Co-authored-by: tatt61880 <tatt61880@gmail.com> Co-authored-by: Matthäus G. Chajdas <dev@anteru.net>
* | Update CHANGES, versionadded.Matthäus G. Chajdas2021-03-142-2/+2
| |
* | Add apdl and gcode lexers (#1714)Averter2021-03-143-0/+482
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add apdl and gcode lexers * Added requested changes except words function * Added requested changes except words function * Added words function to handle lists of keywords * Add two testing example files * Delete two_dimensional_truss.ans * Delete coupled_example.ans * Create example1apdl.ans * Create example2apdl.ans * General cleanup of apdlexer and creation of mapfiles * Escaped backslashes in string literals on apdlexer * Removed backslashes. None was necessary in the first place * Added apdl aliase and a * based command in the test file * Forgot to create the map files * Tested version. Also removed an unused function from apdlexer * Added examples for gcode and golden output * Trimming of gcode files to a few dozens of lines * Removed duplicates from elafunb
* | Update the Chapel lexer (#1743)Engin Kayraklioglu2021-03-141-29/+53
| | | | | | | | | | | | | | | | | | * Update the Chapel lexer Signed-off-by: Engin Kayraklioglu <e-kayrakli@users.noreply.github.com> * Update the test Signed-off-by: Engin Kayraklioglu <e-kayrakli@users.noreply.github.com>
* | Refactor CFamilyLexer (#1746)amitkummer2021-03-141-10/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Remove duplicate lines in state * Refactor ident regex for readability Refactor ident regex changed in c1a0d82 to improve readability. Refactor namespaced_ident regex added in c1a0d82 to improve readability. * Fix inline keword lexing * Fix indentation * Refactor CLexer keywords to 'keywords' state
* | Minted compatibility patch (#1737)Jean-François B2021-03-061-6/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Fix #1735 pull request * LaTeX: workaround to ensure compatibility with minted This reverts already merged #1735 (after a commit from #1736 to fix it) and applies the first envisioned method discussed in #1734. The reason is that the #1735-#1736 method only partially repairs the minted compatibility. Minted queries from Pygments the stylesheet with a command prefix equal to the style name, which may contain (at least, so far) characters such as - and _, which are not normally allowed in LaTeX macros. So it modifies the meaning of - and _ before telling LaTeX to input the Pygments provided stylesheet. Restoring the normal meaning of - from inside the stylesheet must be carefully localized: at top and bottom of stylesheets some macros will use in their names the - and there the - must be the weird minted one, not the normal one. The #1735-#1736 method thus does fix compatibility with minted but *only* for those style names not using a -, but it creates another issue if used with e.g. style "paraiso-dark" which has a - character in its name. "De guerre lasse", I feel it is simpler to use the somewhat strange very localized hotfix of prefixing - by \string at the one spot where we need it to be its normal self. Hence this PR. Fix #1734.