mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-07-31 19:30:03 +00:00
eliminate all old evaluation bundled helpers, eliminate old fragmented eval caches; move all to unified evaluation cache
This commit is contained in:
@@ -4,51 +4,6 @@
|
||||
#ifndef EVAL_PARSE_H
|
||||
#define EVAL_PARSE_H
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Parse Results
|
||||
|
||||
typedef struct E_Parse E_Parse;
|
||||
struct E_Parse
|
||||
{
|
||||
E_TokenArray tokens;
|
||||
E_Token *last_token;
|
||||
E_Expr *expr;
|
||||
E_Expr *last_expr;
|
||||
E_MsgList msgs;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Parse Evaluation State
|
||||
|
||||
typedef struct E_ParseCacheNode E_ParseCacheNode;
|
||||
struct E_ParseCacheNode
|
||||
{
|
||||
E_ParseCacheNode *next;
|
||||
String8 string;
|
||||
E_Parse parse;
|
||||
};
|
||||
|
||||
typedef struct E_ParseCacheSlot E_ParseCacheSlot;
|
||||
struct E_ParseCacheSlot
|
||||
{
|
||||
E_ParseCacheNode *first;
|
||||
E_ParseCacheNode *last;
|
||||
};
|
||||
|
||||
typedef struct E_ParseState E_ParseState;
|
||||
struct E_ParseState
|
||||
{
|
||||
Arena *arena;
|
||||
U64 arena_eval_start_pos;
|
||||
U64 cache_slots_count;
|
||||
E_ParseCacheSlot *cache_slots;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Globals
|
||||
|
||||
thread_static E_ParseState *e_parse_state = 0;
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Tokenization Functions
|
||||
|
||||
@@ -86,10 +41,4 @@ internal E_Parse e_push_type_parse_from_text_tokens(Arena *arena, String8 text,
|
||||
internal E_Parse e_push_parse_from_string_tokens__prec(Arena *arena, String8 text, E_TokenArray tokens, S64 max_precedence, U64 max_chain_count);
|
||||
internal E_Parse e_push_parse_from_string(Arena *arena, String8 text);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Parse Cache Functions
|
||||
|
||||
internal void e_parse_eval_begin(void);
|
||||
internal E_Parse e_parse_from_string(String8 string);
|
||||
|
||||
#endif // EVAL_PARSE_H
|
||||
|
||||
Reference in New Issue
Block a user