Misc cruft.

This commit is contained in:
Simon Forman
2022-09-07 09:28:30 -07:00
parent 779ea5c7e5
commit d6818620e3
4 changed files with 20 additions and 5 deletions
+10 -3
View File
@@ -45,9 +45,16 @@ from joy.utils.snippets import (
)
BRACKETS = r'\[|\]'
BLANKS = r'\s+'
WORDS = r'[^[\]\s]+'
BRACKETS = r'\[|\]' # Left or right square bracket.
BLANKS = r'\s+' # One-or-more blankspace.
WORDS = (
'[' # Character class
'^' # not a
'[' # left square bracket nor a
'\]' # right square bracket (escaped so it doesn't close the character class)
'\s' # nor blankspace
']+' # end character class, one-or-more.
)
token_scanner = Scanner([