Merge branch 'master' into separate-build-phase
This commit is contained in:
commit
1fef0c5000
@ -145,16 +145,17 @@ func (p *choiceParser) nodeID() int { return p.id }
|
||||
|
||||
func (p *choiceParser) parse(t Trace, c *context) {
|
||||
t = t.Extend(p.name)
|
||||
t.Out1("parsing", c.offset)
|
||||
t.Out1("parsing choice", c.offset)
|
||||
|
||||
// TODO: don't add documentation
|
||||
if p.commit&Documentation != 0 {
|
||||
t.Out1("fail, doc")
|
||||
c.fail(c.offset)
|
||||
return
|
||||
}
|
||||
|
||||
if m, ok := c.fromStore(p.id); ok {
|
||||
t.Out1("found in cache", m)
|
||||
t.Out1("found in store, match:", m)
|
||||
return
|
||||
}
|
||||
|
||||
@ -207,7 +208,7 @@ func (p *choiceParser) parse(t Trace, c *context) {
|
||||
if match {
|
||||
c.success(to)
|
||||
c.include(from, p.id)
|
||||
t.Out1("success")
|
||||
t.Out1("choice, success")
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -9,7 +9,7 @@ import (
|
||||
)
|
||||
|
||||
func TestMML(t *testing.T) {
|
||||
testTrace(t, "mml.parser", "mml", 0, []testItem{{
|
||||
testTrace(t, "mml.parser", "mml", 1, []testItem{{
|
||||
msg: "empty",
|
||||
node: &Node{Name: "mml"},
|
||||
}, {
|
||||
|
@ -172,9 +172,8 @@ func (p *sequenceParser) nodeID() int { return p.id }
|
||||
|
||||
func (p *sequenceParser) parse(t Trace, c *context) {
|
||||
t = t.Extend(p.name)
|
||||
t.Out1("parsing", c.offset)
|
||||
|
||||
if p.commit&Documentation != 0 {
|
||||
t.Out1("fail, doc")
|
||||
c.fail(c.offset)
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user