     else if this.isIdent(c)
       node.type = "ident"
       node.text = this.matchIdent()
+    else
+      throw new Error("UNEXPECTED TOKEN: #{c}")
 
     node
 

class Node
  type: undefined     # 'number'/'binop'/'unaryop'
  token: undefined    # The token



p = new MathParser()
prettyPrint p.parse "**3"

# Export these so I can test them
exports.MathParser = MathParser
