Compute transitions for regex pattern rules
This commit is contained in:
parent
040ec86000
commit
ecd317ccd9
13 changed files with 206 additions and 23 deletions
|
|
@ -2,10 +2,23 @@
|
|||
|
||||
namespace tree_sitter {
|
||||
namespace rules {
|
||||
bool Rule::operator==(const rule_ptr other) const {
|
||||
return true;
|
||||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& stream, const Rule &rule)
|
||||
{
|
||||
stream << rule.to_string();
|
||||
return stream;
|
||||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& stream, const rule_ptr &rule)
|
||||
{
|
||||
if (rule.get() == nullptr)
|
||||
stream << std::string("<NULL rule>");
|
||||
else
|
||||
stream << rule->to_string();
|
||||
return stream;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue