nodes.coffee is continuing to roll along -- maybe a tenth implemented

This commit is contained in:
Jeremy Ashkenas
2010-02-08 19:49:39 -05:00
parent 135620b14a
commit aabfba9599
7 changed files with 730 additions and 699 deletions

View File

@@ -232,13 +232,13 @@ lex::token: (tag, value) ->
# Look at a tag in the current token stream.
lex::tag: (index, tag) ->
return unless tok: this.tokens[this.tokens.length - (index || 1)]
return unless tok: this.tokens[this.tokens.length - (index or 1)]
return tok[0]: tag if tag?
tok[0]
# Look at a value in the current token stream.
lex::value: (index, val) ->
return unless tok: this.tokens[this.tokens.length - (index || 1)]
return unless tok: this.tokens[this.tokens.length - (index or 1)]
return tok[1]: val if val?
tok[1]