[PATCH] D11288: [llgo] cmd/gllgo: handle/ignore more flags

Peter Collingbourne peter at pcc.me.uk
Fri Jul 17 01:04:37 PDT 2015


pcc added inline comments.

================
Comment at: cmd/gllgo/gllgo.go:329
@@ +328,3 @@
+			// Not generally useful for Go, since the language provides
+			// memory-safe guarantees. Ignore.
+
----------------
You might want to add a TODO to enable the stack protector anyway; it could still be useful for protecting against the scenario where a C library called via cgo is manipulated into overwriting a Go stack frame.

================
Comment at: cmd/gllgo/gllgo.go:331-335
@@ +330,7 @@
+
+		case strings.HasPrefix(args[0], "-Wformat"):
+			// Purview of "go vet". Ignore.
+
+		case strings.HasPrefix(args[0], "-Werror="):
+			// Go doesn't do warnings. Ignore.
+
----------------
It may be simpler to ignore everything beginning with `-W`, as some other distribution may be using some other set of warning flags.


http://reviews.llvm.org/D11288







More information about the llvm-commits mailing list