types.c (1051B)
1 #include <scc/scc.h> 2 3 #include "../cc2.h" 4 5 6 Type int8type = { 7 .flags = SIGNF | INTF, 8 .size = 1, 9 .align = 1 10 }; 11 12 Type int16type = { 13 .flags = SIGNF | INTF, 14 .size = 2, 15 .align = 2 16 }; 17 18 Type int32type = { 19 .flags = SIGNF | INTF, 20 .size = 4, 21 .align = 4 22 }; 23 24 Type int64type = { 25 .flags = SIGNF | INTF, 26 .size = 8, 27 .align = 4 28 }; 29 30 Type uint8type = { 31 .flags = INTF, 32 .size = 1, 33 .align = 1 34 }; 35 36 Type uint16type = { 37 .flags = INTF, 38 .size = 2, 39 .align = 2 40 }; 41 42 Type uint32type = { 43 .flags = INTF, 44 .size = 4, 45 .align = 2 46 }; 47 48 Type uint64type = { 49 .flags = INTF, 50 .size = 8, 51 .align = 4 52 }; 53 54 Type ptrtype = { 55 .flags = INTF, 56 .size = 4, 57 .align = 4 58 }; 59 60 Type booltype = { 61 .flags = INTF, 62 .size = 1, 63 .align = 1 64 }; 65 66 Type float32type = { 67 .flags = FLOATF, 68 .size = 4, 69 .align = 4 70 }; 71 72 Type float64type = { 73 .flags = FLOATF, 74 .size = 8, 75 .align = 4 76 }; 77 78 Type float80type = { 79 .flags = FLOATF, 80 .size = 12, 81 .align = 4 82 }; 83 84 Type voidtype = { 85 .size = 0, 86 .align = 0 87 }; 88 89 Type arg_type = { 90 .size = 4, 91 .align = 4 92 };