diff options
author | Ayke van Laethem <[email protected]> | 2024-07-10 13:42:21 +0200 |
---|---|---|
committer | Ron Evans <[email protected]> | 2024-08-11 01:48:11 -0700 |
commit | 2e76cd3687df0f6a4ea8d042589ced1d22f4ea78 (patch) | |
tree | 0dca13e2a3642f2986e6ee341c24cea963f7c5dc /main_test.go | |
parent | 2eb39785fe9d0188e444fd1eb29f1ce2c7a89419 (diff) | |
download | tinygo-2e76cd3687df0f6a4ea8d042589ced1d22f4ea78.tar.gz tinygo-2e76cd3687df0f6a4ea8d042589ced1d22f4ea78.zip |
builder: interpret linker error messages
This shows nicely formatted error messages for missing symbol names and
for out-of-flash, out-of-RAM conditions (on microcontrollers with
limited flash/RAM).
Unfortunately the missing symbol name errors aren't available on Windows
and WebAssembly because the linker doesn't report source locations yet.
This is something that I could perhaps improve in LLD.
Diffstat (limited to 'main_test.go')
-rw-r--r-- | main_test.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/main_test.go b/main_test.go index 057e008e8..ccd490d62 100644 --- a/main_test.go +++ b/main_test.go @@ -8,7 +8,6 @@ import ( "bytes" "errors" "flag" - "fmt" "io" "os" "os/exec" @@ -696,7 +695,8 @@ func TestMain(m *testing.M) { // Invoke a specific tool. err := builder.RunTool(os.Args[1], os.Args[2:]...) if err != nil { - fmt.Fprintln(os.Stderr, err) + // The tool should have printed an error message already. + // Don't print another error message here. os.Exit(1) } os.Exit(0) |