mirror of
https://codeberg.org/ProgramSnail/lang.git
synced 2025-12-06 06:58:46 +00:00
match builder fix
This commit is contained in:
parent
7be3722824
commit
4bf3406892
1 changed files with 1 additions and 3 deletions
|
|
@ -155,7 +155,6 @@ Node BuilderTask<Node>::operator()(const ParserNode &parser_node,
|
||||||
Node BuilderTask<nodes::Match::Case>::operator()(const ParserNode &parser_node,
|
Node BuilderTask<nodes::Match::Case>::operator()(const ParserNode &parser_node,
|
||||||
const Args &) {
|
const Args &) {
|
||||||
Log::Context logc(executor.log(), Log::Area::kParse);
|
Log::Context logc(executor.log(), Log::Area::kParse);
|
||||||
std::cout << "!!!!!!!!!!!!!!!!!!!!!!!!!!!!";
|
|
||||||
|
|
||||||
std::string case_kind = parser_node.nth_child(0).get_value();
|
std::string case_kind = parser_node.nth_child(0).get_value();
|
||||||
|
|
||||||
|
|
@ -196,7 +195,6 @@ Node BuilderTask<nodes::Match>::operator()(const ParserNode &parser_node,
|
||||||
const Args &) {
|
const Args &) {
|
||||||
Log::Context logc(executor.log(), Log::Area::kParse);
|
Log::Context logc(executor.log(), Log::Area::kParse);
|
||||||
|
|
||||||
std::cout << "????????????????";
|
|
||||||
std::vector<nodes::NodeId /*nodes::Match::Case*/> cases; // TODO
|
std::vector<nodes::NodeId /*nodes::Match::Case*/> cases; // TODO
|
||||||
|
|
||||||
auto current_node = parser_node.nth_named_child(1);
|
auto current_node = parser_node.nth_named_child(1);
|
||||||
|
|
@ -208,7 +206,7 @@ Node BuilderTask<nodes::Match>::operator()(const ParserNode &parser_node,
|
||||||
|
|
||||||
return Build(
|
return Build(
|
||||||
nodes::Match{
|
nodes::Match{
|
||||||
.value = Run<nodes::Match::Case>(parser_node.nth_named_child(
|
.value = Run<Node>(parser_node.nth_named_child(
|
||||||
0)), // TODO: is_scoped info (always false ??)
|
0)), // TODO: is_scoped info (always false ??)
|
||||||
.cases = std::move(cases),
|
.cases = std::move(cases),
|
||||||
},
|
},
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue