main: refactor error messages to use FileCheck-like patterns

Match the error messages in testdata/errors/*.go like LLVM FileCheck,
which includes regular expressions.

I believe this is much more flexible, and LLVM uses it in nearly all of
their tests so it must work quite well for compilers.
This commit is contained in:
Ayke van Laethem
2024-07-12 14:30:15 +02:00
committed by Ron Evans
parent 208eb1a817
commit e409950492
2 changed files with 31 additions and 11 deletions
+1 -1
View File
@@ -5,4 +5,4 @@ import _ "github.com/tinygo-org/tinygo/testdata/errors/invaliddep"
func main() {
}
// ERROR: invaliddep/invaliddep.go:1:1: expected 'package', found ppackage
// ERROR: invaliddep{{[\\/]}}invaliddep.go:1:1: expected 'package', found ppackage