summaryrefslogtreecommitdiff
path: root/syntax-highlight
Commit message (Collapse)AuthorAgeFilesLines
* Add WAT lexer.David Thompson2023-09-191-0/+60
|
* Add first pass at a JavaScript lexer.David Thompson2023-09-151-0/+74
|
* Add Lisp lexer.David Thompson2022-10-051-0/+100
|
* Add css lexer.Julien Lepiller2021-08-212-8/+604
|
* Add gitignore lexer.Julien Lepiller2021-07-141-0/+42
|
* lexers: Add lex-consume-until.Julien Lepiller2021-07-141-0/+39
| | | | | * syntax-highlight/lexers.scm (lex-consume-until, token-append): New variables.
* scheme: Fix variable export.David Thompson2021-01-051-1/+1
|
* Add C lexer.David Thompson2018-03-101-0/+108
|
* Delete parsers modules.David Thompson2016-02-161-224/+0
| | | | | * syntax-highlight/parsers.scm: Delete. * Makefile.am (SOURCES): Delete it.
* Rewrite highlighters in terms of lexers.David Thompson2016-02-162-170/+136
|
* Add lexers module.David Thompson2016-02-161-0/+333
| | | | | | | | This starts the transition away from the flawed parser combinators to something really similar, but more capable. * syntax-highlight/lexers.scm: New file. * Makefile.am(SOURCES): Add it.
* Add (syntax-highlight utils) module.David Thompson2015-10-212-2/+38
| | | | | | | * syntax-highlight.scm (string->stream): Move it. * syntax-highlight/parsers.scm (stream->string): Likewise. * syntax-highlight/utils.scm: New file. * Makefile.am (SOURCES): Add it.
* xml: Reverse order of operations issue.David Thompson2015-10-211-1/+1
| | | | | | | Try to parse close tags before open tags. * syntax-highlight/xml.scm (xml-highlighter): Switch order of 'parse-close-tag' and 'parse-open-tag'.
* Add XML highlighter.David Thompson2015-10-191-0/+111
| | | | | | * syntax-highlight/xml.scm: New file * Makefile.am (SOURCES): Add it. * README ("Supported Languages"): Add "XML."
* parsers: Fix variable shadowing issue.David Thompson2015-10-191-5/+5
| | | | | | | | | | 'parse-either' and 'parse-both' shadowed the 'stream' variable, causing failure cases to sometimes return the wrong stream. That is, a stream that has consumed input characters, not the original stream. * syntax-highlight/parsers.scm (parse-either, parse-both): Use 'remainder' variable for leftover stream variables rather than shadowing 'stream'.
* parsers: Add parse-maybe.David Thompson2015-10-191-0/+11
| | | | * syntax-highlight/parsers.scm (parse-maybe): New procedure.
* parsers: Remove parse-never.David Thompson2015-10-192-10/+5
| | | | | | | | | | This was a thinko. It's redundant with 'parse-fail'. * syntax-highlight/parsers.scm (parse-never): Delete. (parse-fail): Rewrite docstring. (parse-any, parse-each): Use 'parse-fail'. * syntax-highlight/scheme.scm (parse-specials, parse-openers, parse-closers): Likewise.
* scheme: Allow for custom special symbols.David Thompson2015-10-181-4/+14
| | | | | | | | | The 'make-scheme-highlighter' procedure lets the user override what the set of special symbols and regexps are, useful for adding/removing context-specific symbols. * syntax-highlight/scheme.scm (make-scheme-highlighter): New procedure. (scheme-highlighter): Define in terms of 'make-scheme-highlighter'.
* scheme: Tag symbols beginning with "define" as special.David Thompson2015-10-181-4/+33
| | | | | | * syntax-highlight/scheme.scm (parse-symbol-chars, parse-specials/regexp): New procedures. (parse-keyword): Use 'parse-symbol-chars'.
* parsers: Add parse-regexp.David Thompson2015-10-181-0/+10
| | | | * syntax-highlight/parsers.scm (parse-regexp): New procedure.
* parsers: Add parse-filter.David Thompson2015-10-181-0/+10
| | | | * syntax-highlight/parsers.scm (parse-filter): New procedure.
* parsers: Fix typo in docstring.David Thompson2015-10-181-1/+1
| | | | * syntax-highlight/parsers.scm (tagged-parser): Fix typo in docstring.
* scheme: Remove commented code.David Thompson2015-10-181-7/+0
| | | | * syntax-highlight/scheme.scm: Remove commented code.
* parsers: Fix parse-delimited.David Thompson2015-10-181-1/+2
| | | | | | | | The 'until' string needs to be reversed before stringification, since the rest of the character list is in reverse order. * syntax-highlight/parsers.scm (parse-delimited): Reverse 'until' string when stringifying.
* First commit!David Thompson2015-10-172-0/+300