]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/cgo: change comments in generated C code to be C-style
authorAndy Maloney <asmaloney@gmail.com>
Thu, 6 Aug 2015 15:45:53 +0000 (11:45 -0400)
committerIan Lance Taylor <iant@golang.org>
Wed, 26 Aug 2015 00:01:08 +0000 (00:01 +0000)
Change-Id: I3889eda72ae0f57117f1d4299e3574f8bf68be67
Reviewed-on: https://go-review.googlesource.com/13310
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/cmd/cgo/out.go

index 90a744196228e1e93c53e97a01984adb64efde02..4a371fe702a989d1ca1a22d07e1a0b38efc30797 100644 (file)
@@ -1193,9 +1193,11 @@ func (p *Package) cgoType(e ast.Expr) *Type {
 }
 
 const gccProlog = `
-// Usual nonsense: if x and y are not equal, the type will be invalid
-// (have a negative array count) and an inscrutable error will come
-// out of the compiler and hopefully mention "name".
+/*
+  If x and y are not equal, the type will be invalid
+  (have a negative array count) and an inscrutable error will come
+  out of the compiler and hopefully mention "name".
+*/
 #define __cgo_compile_assert_eq(x, y, name) typedef char name[(x-y)*(x-y)*-2+1];
 
 // Check at compile time that the sizes we use match our expectations.
@@ -1376,8 +1378,10 @@ typedef double GoFloat64;
 typedef __complex float GoComplex64;
 typedef __complex double GoComplex128;
 
-// static assertion to make sure the file is being used on architecture
-// at least with matching size of GoInt.
+/*
+  static assertion to make sure the file is being used on architecture
+  at least with matching size of GoInt.
+*/
 typedef char _check_for_GOINTBITS_bit_pointer_matching_GoInt[sizeof(void*)==GOINTBITS/8 ? 1:-1];
 
 typedef struct { char *p; GoInt n; } GoString;