From 1c630655b2beb0f4b84fb7e1bc034ba62520be37 Mon Sep 17 00:00:00 2001 From: _ov4 Date: Mon, 21 Sep 2026 04:50:06 +0000 Subject: fix name typo, and remove outdated parse --- include/lexer/symbol_property.h | 48 ----------------------------------------- 1 file changed, 48 deletions(-) delete mode 100644 include/lexer/symbol_property.h (limited to 'include/lexer/symbol_property.h') diff --git a/include/lexer/symbol_property.h b/include/lexer/symbol_property.h deleted file mode 100644 index c933605..0000000 --- a/include/lexer/symbol_property.h +++ /dev/null @@ -1,48 +0,0 @@ -#pragma once - -#include -#include - -#include "lexer/enum_type.h" - -using namespace std; - -namespace ov4 -{ - -class T_property -{ -public: - bool continuable = true; - - // -1 means it's NOT operator - // any positive values mean it's operator - int pivot_priority = -1; - - // require: MUST - // accept: optional, but if it doesn't accept, but there is indeed a child, then error - child_existence_type left; - child_existence_type right; - - enum_token_type enum_type = TEXT; -}; - -inline const unordered_map symbol_property = { - - // bracket - {"(", {.continuable = false, .enum_type = LEFT_BRACKET}}, - {")", {.continuable = false, .enum_type = RIGHT_BRACKET}}, - - // operator - {"&", {.continuable = true, .pivot_priority = 2000, .left = child_existence_type::EXIST, .right = child_existence_type::NOT_EXIST, .enum_type = ASYNC}}, - {"|", {.continuable = true, .pivot_priority = 100, .left = child_existence_type::EXIST, .right = child_existence_type::EXIST, .enum_type = PIPE}}, - {"&&", {.continuable = true, .pivot_priority = 1000, .left = child_existence_type::EXIST, .right = child_existence_type::EXIST, .enum_type = LOGIC_AND}}, - {"||", {.continuable = true, .pivot_priority = 1000, .left = child_existence_type::EXIST, .right = child_existence_type::EXIST, .enum_type = LOGIC_OR}}, - -}; - -string symbol_enum2string(enum_token_type e); - -bool symbol_contains_enum_type(enum_token_type e); - -} -- cgit v1.3.1-4-g156e