Browse code

core: kemi - added long type and field to xval union

Daniel-Constantin Mierla authored on 24/11/2022 08:56:15
Showing 1 changed files
... ...
@@ -30,10 +30,11 @@
30 30
 #define SR_KEMIP_INT	(1<<0)	/* type integer */
31 31
 #define SR_KEMIP_STR	(1<<1)	/* type str* */
32 32
 #define SR_KEMIP_BOOL	(1<<2)	/* type boolean (0/1) */
33
-#define SR_KEMIP_XVAL	(1<<3)	/* type extended value (integer, str*, ...) */
34
-#define SR_KEMIP_NULL	(1<<4)	/* type NULL */
35
-#define SR_KEMIP_DICT	(1<<5)	/* type dictionary */
36
-#define SR_KEMIP_ARRAY	(1<<6)	/* type array */
33
+#define SR_KEMIP_LONG	(1<<3)	/* type long integer */
34
+#define SR_KEMIP_XVAL	(1<<4)	/* type extended value (integer, str*, ...) */
35
+#define SR_KEMIP_NULL	(1<<5)	/* type NULL */
36
+#define SR_KEMIP_DICT	(1<<6)	/* type dictionary */
37
+#define SR_KEMIP_ARRAY	(1<<7)	/* type array */
37 38
 
38 39
 #define SR_KEMI_FALSE	0
39 40
 #define SR_KEMI_TRUE	1
... ...
@@ -65,6 +66,7 @@ typedef struct sr_kemi_module {
65 66
 
66 67
 typedef union {
67 68
 	int n;
69
+	long l;
68 70
 	str s;
69 71
 } sr_kemi_val_t;
70 72
 
... ...
@@ -75,6 +77,7 @@ typedef struct sr_kemi_dict_item
75 77
 	int vtype;
76 78
 	union {
77 79
 		int n;
80
+		long l;
78 81
 		str s;
79 82
 		struct sr_kemi_dict_item *dict;
80 83
 	} v;
... ...
@@ -84,6 +87,7 @@ typedef struct sr_kemi_xval {
84 87
 	int vtype;
85 88
 	union {
86 89
 		int n;
90
+		long l;
87 91
 		str s;
88 92
 		sr_kemi_dict_item_t *dict;
89 93
 	} v;