cgo: implement bool/float/complex types

This commit is contained in:
Ayke van Laethem
2019-02-08 19:56:43 +01:00
committed by Ron Evans
parent fab38a0749
commit da345e8723
5 changed files with 64 additions and 14 deletions
+7
View File
@@ -1,6 +1,13 @@
#include "main.h"
int global = 3;
_Bool globalBool = 1;
_Bool globalBool2 = 10; // test narrowing
float globalFloat = 3.1;
double globalDouble = 3.2;
_Complex float globalComplexFloat = 4.1+3.3i;
_Complex double globalComplexDouble = 4.2+3.4i;
_Complex double globalComplexLongDouble = 4.3+3.5i;
int fortytwo() {
return 42;