6# 4g: parsing (outside caller)
11Parse a cord with a given `++rule` and crash if the `++cord` isn't entirely
24The value of the parse result, or crash.
29 ++ rash |*({naf/@ sab/rule} (scan (trip naf) sab)) ::
35 > (rash 'I was the world in which I walked, and what I saw' (star (shim 0 200)))
36 "I was the world in which I walked, and what I saw"
37 > (rash 'abc' (just 'a'))
41 > (rash 'abc' (jest 'abc'))
43 `> (rash 'abc' (jest 'ab'))
55Parse a given with a given rule and produce null if the cord isn't
68The value of the parse result, or null.
73 ++ rush |*({naf/@ sab/rule} (rust (trip naf) sab))
79 > (rush 'I was the world in which I walked, and what I saw' (star (shim 0 200)))
80 [~ "I was the world in which I walked, and what I saw"]
81 > (rush 'abc' (just 'a'))
83 > (rush 'abc' (jest 'abc'))
85 > (rush 'abc' (jest 'ac'))
87 > (rush 'abc' (jest 'ab'))
97Parse a `++tape` with a given `++rule` and produce null if the `++tape` isn't
115 ++ rust |* {los/tape sab/rule}
116 =+ vex=((full sab) [[1 1] los])
117 ?~(q.vex ~ [~ u=p.u.q.vex])
123 > (rust "I was the world in which I walked, and what I saw" (star (shim 0 200)))
124 [~ "I was the world in which I walked, and what I saw"]
125 > (rust "Or heard or felt came not but from myself;" (star (shim 0 200)))
126 [~ "Or heard or felt came not but from myself;"]
127 > (rust "And there I found myself more truly and more strange." (jest 'And there I'))
137Parse a `++tape` with a given `++rule` and crash if the `++tape` isn't entirely
150Either a `++tape` or a crash.
155 ++ scan |* {los/tape sab/rule}
156 =+ vex=((full sab) [[1 1] los])
158 ~_ (show [%m '{%d %d}'] p.p.vex q.p.vex ~)
159 ~|('syntax-error' !!)
165 > (scan "I was the world in which I walked, and what I saw" (star (shim 0 200)))
166 "I was the world in which I walked, and what I saw"
167 > (scan "Or heard or felt came not but from myself;" (star (shim 0 200)))
168 "Or heard or felt came not but from myself;"
169 > (scan "And there I found myself more truly and more strange." (jest 'And there I'))
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list