1
0
forked from GitHub/gf-core

started a new database-backed runtime from scratch

This commit is contained in:
krangelov
2021-07-30 12:08:28 +02:00
parent 155657709a
commit 8f0a1b8fee
117 changed files with 1637 additions and 41288 deletions

30
src/runtime/c/expr.h Normal file
View File

@@ -0,0 +1,30 @@
#ifndef EXPR_H_
#define EXPR_H_
#include "variant.h"
// PgfLiteral
typedef variant PgfLiteral;
typedef enum {
PGF_LITERAL_STR,
PGF_LITERAL_INT,
PGF_LITERAL_FLT,
PGF_LITERAL_NUM_TAGS
} PgfLiteralTag;
typedef struct {
char val[0]; // a flexible array that contains the value
} PgfLiteralStr;
typedef struct {
int val;
} PgfLiteralInt;
typedef struct {
double val;
} PgfLiteralFlt;
#endif /* EXPR_H_ */