mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-19 16:47:28 +01:00
Merge Break and Continue as Jump.
This commit is contained in:
1 parent
23020e7d60
commit
d9fc8a1114
3 files changed
+14
-35
No files matched your search
+2
-6
@@ -403,13 +403,9 @@ func (p *parser) parseStatement1() (*a.Node, error) {
|
||||
case t.IDAssert, t.IDPre, t.IDPost:
|
||||
return p.parseAssertNode()
|
||||
|
||||
case t.IDBreak:
|
||||
case t.IDBreak, t.IDContinue:
|
||||
p.src = p.src[1:]
|
||||
return a.NewBreak().Node(), nil
|
||||
|
||||
case t.IDContinue:
|
||||
p.src = p.src[1:]
|
||||
return a.NewContinue().Node(), nil
|
||||
return a.NewJump(x).Node(), nil
|
||||
|
||||
case t.IDWhile:
|
||||
p.src = p.src[1:]
|
||||
|
||||
Reference in new issue
Block a user