Open jcburley opened 6 years ago
E.g. given:
#include <stdio.h> int main() { printf("num1=%d, num2=%u\n", 3, 4); return 0; }
The .go file excerpt reads:
func main() { noarch.Printf((&[]byte("num1=%d, num2=%u\n\x00")[0]), int32(3), int32(4)) return }
That looks correct enough (to me), but the resulting executable prints:
num1=3, num2=%!u(int32=4)
That should read num1=3, num2=4.
num1=3, num2=4
This appears to be due to relying on fmt.Printf(), which evidently does not support %u (%d would suffice, so I've changed my code to use that). See:
fmt.Printf()
%u
%d
https://golang.org/pkg/fmt/
Duplicate issue: #94
E.g. given:
The .go file excerpt reads:
That looks correct enough (to me), but the resulting executable prints:
That should read
num1=3, num2=4
.