Update Swift.test.stg

This commit is contained in:
janyou 2016-11-11 21:48:45 +08:00 committed by parrt
parent 033e5ed136
commit d1dbfccdd6
1 changed files with 15 additions and 1 deletions

View File

@ -346,8 +346,22 @@ let walker = ParseTreeWalker()
try! walker.walk(LeafListener(), <s>)
>>
TreeNodeWithAltNumField(X) ::= <<
// TODO
@parser::members {
open class MyRuleNode: ParserRuleContext {
public var altNum: Int = 0
override
public init(_ parent: ParserRuleContext?, _ invokingStateNumber: Int) {
super.init(parent, invokingStateNumber)
}
override
open func getAltNumber() -> Int { return altNum }
override
open func setAltNumber(_ altNum: Int) { self.altNum = altNum }
}
}
>>
TokenGetterListener(X) ::= <<