| ... | @@ -165,6 +165,7 @@ pub const Error = union(enum) { | ... | @@ -165,6 +165,7 @@ pub const Error = union(enum) { |
| 165 | ExpectedLoopExpr: ExpectedLoopExpr, | 165 | ExpectedLoopExpr: ExpectedLoopExpr, |
| 166 | ExpectedDerefOrUnwrap: ExpectedDerefOrUnwrap, | 166 | ExpectedDerefOrUnwrap: ExpectedDerefOrUnwrap, |
| 167 | ExpectedSuffixOp: ExpectedSuffixOp, | 167 | ExpectedSuffixOp: ExpectedSuffixOp, |
| | 168 | ExpectedBlockOrField: ExpectedBlockOrField, |
| 168 | DeclBetweenFields: DeclBetweenFields, | 169 | DeclBetweenFields: DeclBetweenFields, |
| 169 | InvalidAnd: InvalidAnd, | 170 | InvalidAnd: InvalidAnd, |
| 170 | | 171 | |
| ... | @@ -215,6 +216,7 @@ pub const Error = union(enum) { | ... | @@ -215,6 +216,7 @@ pub const Error = union(enum) { |
| 215 | .ExpectedLoopExpr => |*x| return x.render(tokens, stream), | 216 | .ExpectedLoopExpr => |*x| return x.render(tokens, stream), |
| 216 | .ExpectedDerefOrUnwrap => |*x| return x.render(tokens, stream), | 217 | .ExpectedDerefOrUnwrap => |*x| return x.render(tokens, stream), |
| 217 | .ExpectedSuffixOp => |*x| return x.render(tokens, stream), | 218 | .ExpectedSuffixOp => |*x| return x.render(tokens, stream), |
| | 219 | .ExpectedBlockOrField => |*x| return x.render(tokens, stream), |
| 218 | .DeclBetweenFields => |*x| return x.render(tokens, stream), | 220 | .DeclBetweenFields => |*x| return x.render(tokens, stream), |
| 219 | .InvalidAnd => |*x| return x.render(tokens, stream), | 221 | .InvalidAnd => |*x| return x.render(tokens, stream), |
| 220 | } | 222 | } |
| ... | @@ -267,6 +269,7 @@ pub const Error = union(enum) { | ... | @@ -267,6 +269,7 @@ pub const Error = union(enum) { |
| 267 | .ExpectedLoopExpr => |x| return x.token, | 269 | .ExpectedLoopExpr => |x| return x.token, |
| 268 | .ExpectedDerefOrUnwrap => |x| return x.token, | 270 | .ExpectedDerefOrUnwrap => |x| return x.token, |
| 269 | .ExpectedSuffixOp => |x| return x.token, | 271 | .ExpectedSuffixOp => |x| return x.token, |
| | 272 | .ExpectedBlockOrField => |x| return x.token, |
| 270 | .DeclBetweenFields => |x| return x.token, | 273 | .DeclBetweenFields => |x| return x.token, |
| 271 | .InvalidAnd => |x| return x.token, | 274 | .InvalidAnd => |x| return x.token, |
| 272 | } | 275 | } |
| ... | @@ -306,6 +309,7 @@ pub const Error = union(enum) { | ... | @@ -306,6 +309,7 @@ pub const Error = union(enum) { |
| 306 | pub const ExpectedLoopExpr = SingleTokenError("Expected loop expression, found '{}'"); | 309 | pub const ExpectedLoopExpr = SingleTokenError("Expected loop expression, found '{}'"); |
| 307 | pub const ExpectedDerefOrUnwrap = SingleTokenError("Expected pointer dereference or optional unwrap, found '{}'"); | 310 | pub const ExpectedDerefOrUnwrap = SingleTokenError("Expected pointer dereference or optional unwrap, found '{}'"); |
| 308 | pub const ExpectedSuffixOp = SingleTokenError("Expected pointer dereference, optional unwrap, or field access, found '{}'"); | 311 | pub const ExpectedSuffixOp = SingleTokenError("Expected pointer dereference, optional unwrap, or field access, found '{}'"); |
| | 312 | pub const ExpectedBlockOrField = SingleTokenError("Expected block or field, found '{}'"); |
| 309 | | 313 | |
| 310 | pub const ExpectedParamType = SimpleError("Expected parameter type"); | 314 | pub const ExpectedParamType = SimpleError("Expected parameter type"); |
| 311 | pub const ExpectedPubItem = SimpleError("Expected function or variable declaration after pub"); | 315 | pub const ExpectedPubItem = SimpleError("Expected function or variable declaration after pub"); |