mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-09 13:33:39 +00:00
cgo: implement char type
This type is a bit more difficult because it can be signed or unsigned depending on the target platform.
This commit is contained in:
committed by
Ron Evans
parent
b2e96fc35a
commit
9c46ac4eed
Vendored
+1
@@ -40,6 +40,7 @@ func main() {
|
||||
println("complex float:", C.globalComplexFloat)
|
||||
println("complex double:", C.globalComplexDouble)
|
||||
println("complex long double:", C.globalComplexLongDouble)
|
||||
println("char match:", C.globalChar == 100)
|
||||
|
||||
// complex types
|
||||
println("struct:", C.int(unsafe.Sizeof(C.globalStruct)) == C.globalStructSize, C.globalStruct.s, C.globalStruct.l, C.globalStruct.f)
|
||||
|
||||
Reference in New Issue
Block a user