mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-07-24 00:17:52 +00:00
eval expressions: unary +, correctly lex exponentiated numerics
This commit is contained in:
@@ -14,7 +14,7 @@ str8_lit_comp("CharLiteral"),
|
||||
str8_lit_comp("Symbol"),
|
||||
};
|
||||
|
||||
String8 e_expr_kind_strings[47] =
|
||||
String8 e_expr_kind_strings[48] =
|
||||
{
|
||||
str8_lit_comp("Nil"),
|
||||
str8_lit_comp("Ref"),
|
||||
@@ -26,6 +26,7 @@ str8_lit_comp("Cast"),
|
||||
str8_lit_comp("Sizeof"),
|
||||
str8_lit_comp("Typeof"),
|
||||
str8_lit_comp("ByteSwap"),
|
||||
str8_lit_comp("Pos"),
|
||||
str8_lit_comp("Neg"),
|
||||
str8_lit_comp("LogNot"),
|
||||
str8_lit_comp("BitNot"),
|
||||
@@ -80,7 +81,7 @@ str8_lit_comp("Insufficient evaluation machine stack space."),
|
||||
str8_lit_comp("Malformed bytecode."),
|
||||
};
|
||||
|
||||
E_OpInfo e_expr_kind_op_info_table[47] =
|
||||
E_OpInfo e_expr_kind_op_info_table[48] =
|
||||
{
|
||||
{ E_OpKind_Null, 0, str8_lit_comp(""), str8_lit_comp(""), str8_lit_comp("") },
|
||||
{ E_OpKind_Null, 0, str8_lit_comp(""), str8_lit_comp(""), str8_lit_comp("") },
|
||||
@@ -92,6 +93,7 @@ E_OpInfo e_expr_kind_op_info_table[47] =
|
||||
{ E_OpKind_UnaryPrefix, 1, str8_lit_comp("sizeof"), str8_lit_comp("("), str8_lit_comp(")") },
|
||||
{ E_OpKind_UnaryPrefix, 1, str8_lit_comp("typeof"), str8_lit_comp("("), str8_lit_comp(")") },
|
||||
{ E_OpKind_UnaryPrefix, 1, str8_lit_comp("bswap"), str8_lit_comp("("), str8_lit_comp(")") },
|
||||
{ E_OpKind_UnaryPrefix, 2, str8_lit_comp("+"), str8_lit_comp(""), str8_lit_comp("") },
|
||||
{ E_OpKind_UnaryPrefix, 2, str8_lit_comp("-"), str8_lit_comp(""), str8_lit_comp("") },
|
||||
{ E_OpKind_UnaryPrefix, 2, str8_lit_comp("!"), str8_lit_comp(""), str8_lit_comp("") },
|
||||
{ E_OpKind_UnaryPrefix, 2, str8_lit_comp("~"), str8_lit_comp(""), str8_lit_comp("") },
|
||||
|
||||
@@ -101,6 +101,7 @@ E_ExprKind_Cast,
|
||||
E_ExprKind_Sizeof,
|
||||
E_ExprKind_Typeof,
|
||||
E_ExprKind_ByteSwap,
|
||||
E_ExprKind_Pos,
|
||||
E_ExprKind_Neg,
|
||||
E_ExprKind_LogNot,
|
||||
E_ExprKind_BitNot,
|
||||
@@ -159,9 +160,9 @@ E_InterpretationCode_COUNT,
|
||||
|
||||
C_LINKAGE_BEGIN
|
||||
extern String8 e_token_kind_strings[6];
|
||||
extern String8 e_expr_kind_strings[47];
|
||||
extern String8 e_expr_kind_strings[48];
|
||||
extern String8 e_interpretation_code_display_strings[11];
|
||||
extern E_OpInfo e_expr_kind_op_info_table[47];
|
||||
extern E_OpInfo e_expr_kind_op_info_table[48];
|
||||
extern U8 e_kind_basic_byte_size_table[56];
|
||||
extern String8 e_kind_basic_string_table[56];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user