We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c8d2280 commit 5f9524eCopy full SHA for 5f9524e
whilelang/parse.py
@@ -5,8 +5,15 @@
5
pad = regex(r'[^\S\r\n]')
6
7
Newline = regex(r"\n")
8
-Next = (Newline.at_least(1)
9
- | eof).desc("at least one newline or the end of file")
+_Next = (Newline.at_least(1)
+ | eof).desc("at least one newline or the end of file")
10
+
11
12
+@generate
13
+def Next():
14
+ yield Comment | _Next >> Comment | _Next
15
16
17
Comment = string("#") >> (regex(r'[\S]') | pad).many().concat() >> Next
18
19
woc = whitespace << Comment.optional() << whitespace
0 commit comments