mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-11 06:23:39 +00:00
cgo: improve typedef/struct/enum support
Typedefs are now Go type aliases. And C.struct_ and C.union_ prefixed records work correctly now, even when they're not in a typedef.
This commit is contained in:
committed by
Ron Evans
parent
4bd1b9e53d
commit
35af33ead7
Vendored
+5
@@ -15,6 +15,11 @@ typedef struct collection {
|
||||
unsigned char c;
|
||||
} collection_t;
|
||||
|
||||
struct point {
|
||||
int x;
|
||||
int y;
|
||||
};
|
||||
|
||||
// linked list
|
||||
typedef struct list_t {
|
||||
int n;
|
||||
|
||||
Reference in New Issue
Block a user