Make error "foo" an expression.

This commit is contained in:
Nigel Tao committed 2017-10-27 13:00:13 +11:00
1 parent 9a8508857f
commit 7cefcccc98
7 files changed
+73 -16

No files matched your search

+3
View File
@@ -239,6 +239,9 @@ const MaxExprDepth = 255
// For selectors, like "LHS.ID1", ID0 is IDDot.
//
// For lists, like "$(0, 1, 2)", ID0 is IDDollar.
//
// For statuses, like `error "foo"` and `"suspension "bar"`, ID0 is the keyword
// and ID1 is the message.
type Expr Node
func (n *Expr) Node() *Node { return (*Node)(n) }