added default values to enums
This commit is contained in:
parent
7922fbc8b7
commit
70859e0a6a
|
@ -11,9 +11,9 @@
|
||||||
*/
|
*/
|
||||||
typedef enum PrimitiveType_t {
|
typedef enum PrimitiveType_t {
|
||||||
// 4 byte signed integer in two's complement
|
// 4 byte signed integer in two's complement
|
||||||
Int,
|
Int =0,
|
||||||
// 4 byte IEEE-754 single precision
|
// 4 byte IEEE-754 single precision
|
||||||
Float
|
Float =1
|
||||||
} PrimitiveType;
|
} PrimitiveType;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -21,10 +21,10 @@ typedef enum PrimitiveType_t {
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
typedef enum Sign_t {
|
typedef enum Sign_t {
|
||||||
// type has a sign bit
|
|
||||||
Signed,
|
|
||||||
// type has no sign bit
|
// type has no sign bit
|
||||||
Unsigned
|
Unsigned = 0,
|
||||||
|
// type has a sign bit
|
||||||
|
Signed = 1
|
||||||
} Sign;
|
} Sign;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -387,7 +387,7 @@ typedef struct Operation_t {
|
||||||
union OperationImplementation {
|
union OperationImplementation {
|
||||||
ArithmeticOperator arithmetic;
|
ArithmeticOperator arithmetic;
|
||||||
RelationalOperator relational;
|
RelationalOperator relational;
|
||||||
BooleanOperator boolean;
|
BooleanOperator boolean;
|
||||||
LogicalOperator logical;
|
LogicalOperator logical;
|
||||||
BitwiseOperator bitwise;
|
BitwiseOperator bitwise;
|
||||||
} impl;
|
} impl;
|
||||||
|
|
Loading…
Reference in New Issue