all: add testing for compiler error messages

This is needed for some improvements I'm going to make next.

This commit also refactors error handling slightly to make it more
easily testable, this should hopefully not result in any actual changes
in behavior.
This commit is contained in:
Ayke van Laethem
2024-07-09 17:16:32 +02:00
committed by Ayke
parent 7ac1ca0ae2
commit 8a357af3d8
6 changed files with 141 additions and 19 deletions
+7
View File
@@ -0,0 +1,7 @@
package main
func main(var) { // syntax error
}
// ERROR: # command-line-arguments
// ERROR: syntax.go:3:11: expected ')', found 'var'