| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | |
| | |
| | |
| | |
| | | |
Highlighting as Keyword.Declaration is consistent with the
RacketLexer.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Previously, #; awaited an S-expression but could not cope with a
simple datum like a number literal. While at it, also support R6RS
brackets for S-expressions.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This enriches the space of recognized builtins.
Note that this also fixes the space after a builtin being included in
the token.
|
| | |
| | |
| | |
| | |
| | | |
Many number literals were not recognized previously, such as
fractions, infinities, hex and complex literals.
|
| | |
| | |
| | |
| | |
| | | |
Move string parsing to a dedicated state so it can recognize string escapes.
Add support for various kinds of escapes.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
`anchorlinenos=True`, (#2026)
the generated anchor links should be `#foo-42` and not `#-42`.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* Support comments in JSON
This deviates from the JSON specification but doesn't affect valid JSON.
* Update the JSON parser and tests to reach 100% code and branch coverage
* Note work on JSON lexer
* Fix a roundtrip error identified by a random test input in CI
* Note that comments are supported, and that no validation is performed
|
| | | |
|
| | | |
|
|\ \ \
| |/ / |
|
| | | |
|
| |/ |
|
|/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Remove unused variable
This variable is unused since the first commit to this file
in the commit history, so it's probably safe to remove it.
* Lex identifier as label only if it's at line start
* Stop matching identifiers that begin with a digit
This is so we don't match numbers as labels with the new labels rule.
* Add label tests
* Fix existing tests
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Java: fix lexing of 'record' soft keyword
Refactor the Java lexer to treat `record` as a soft keyword.
Previously, the lexer assumed record is a reserved word, even though
it is a soft keyword which can be used as a variable name.
This refactor lexes record as a keyword only if it appears at the
beggining of the line, with some potential other keywords like public
and private preceding it.
* Remove repetition in capture group
* Update test output
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Detect function with return types of more than a single word length
(like `unsigned int` or `long long`).
|
|
|
|
|
|
|
|
|
| |
* Add square, angle and single underscore to punct; simplify string regex
* Add dollar as operator in LOAD DDL; add pipe as op for resused edge names
* Add to test file to test recent lexer fixes
* Added PR# to new test cases
|
|\
| |
| |
| | |
https://github.com/blu-base/pygments into blu-base-lexers_gh
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
|\ \
| | |
| | | |
Python: lex soft keywords
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Some notes:
- This approach is not perfect, but it's rather simple and I can't
think of an edge case.
- I did not use the `words` function to create the regex matching the
keywords list, because it returns a capturing group (`()`) and it
needs to be non-capturing here (because of `bygroups` usage).
- I chose to go to the 'soft-keywords-inner' state after both
`match` and `case`, even though it's unnecessary for `match`
(the inner state catches the `_` wildcard keyword which appears
only after a `case`).
This is mostly harmless and saves us from writing the 'soft-keywords'
regex twice each for `match` and `case` with the extra inner state
just for `case`.
The only piece of code this will lex incorrectly is `match _:`
(`_` will be lexed as keyword). I doubt though that pattern mathcing
will be used like this.
|
| | |
| | |
| | |
| | | |
Since https://github.com/python/cpython/pull/27037, they can include
tildes in addition to the carets.
|
| | |
| | |
| | |
| | |
| | | |
* Fix single and multiline comment regex for GSQL
* Add examples for end-of-line and multiline comments with embedded keywords
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* Add a tooltips option to HtmlFormmater.
* Rename option tooltips to debug_token_types.
* Use explicit if block.
* Fix check.
* Document how to use the new debug_token_types option for the HTML formatter.
* Remove output redirection from example call.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
- Add pitch language names to builtins. They are not highlighted
specially in the default style, but can be in a custom style.
- Refactor matching of builtins in order to avoid confusion between
dim chord modifier and \dim dynamic command.
- Support grob subproperties.
- Add segno repeat type.
- While at it, update builtins for latest version.
|
| | | |
|
|\ \ \
| | | |
| | | |
| | | | |
https://github.com/zaibacu/pygments into zaibacu-master
|
| | | | |
|
| | | | |
|
| |\ \ \ |
|
| | | | | |
|
| | | | | |
|