aboutsummaryrefslogtreecommitdiff
path: root/include/cru/parse
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2021-09-11 16:31:54 +0800
committercrupest <crupest@outlook.com>2021-09-11 16:31:54 +0800
commit4511eab66574b8047376a1f612e84e57d2040a95 (patch)
treedd789dc75ee242f776de5613d0c52453c6f36414 /include/cru/parse
parent9e4a90f53ed4260ee8b27c326f0c7e11036e733f (diff)
downloadcru-4511eab66574b8047376a1f612e84e57d2040a95.tar.gz
cru-4511eab66574b8047376a1f612e84e57d2040a95.tar.bz2
cru-4511eab66574b8047376a1f612e84e57d2040a95.zip
...
Diffstat (limited to 'include/cru/parse')
-rw-r--r--include/cru/parse/Grammar.hpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/cru/parse/Grammar.hpp b/include/cru/parse/Grammar.hpp
index dd4741df..5935e703 100644
--- a/include/cru/parse/Grammar.hpp
+++ b/include/cru/parse/Grammar.hpp
@@ -21,6 +21,9 @@ class Grammar : public Object {
Production* CreateProduction(String name, Nonterminal* left,
std::vector<Symbol*> right);
+ bool RemoveSymbol(Symbol* symbol);
+ bool RemoveProduction(Production* production);
+
public: // Getters
Nonterminal* GetStartSymbol() const { return start_symbol_; }
const std::vector<Terminal*>& GetTerminals() const { return terminals_; }