mirror of
https://github.com/yhirose/cpp-peglib.git
synced 2024-12-22 20:05:31 +00:00
Fixed build errors.
This commit is contained in:
parent
be60c69729
commit
37fe8bd1ff
4
peglib.h
4
peglib.h
@ -1213,7 +1213,7 @@ private:
|
||||
AssignIDToDefinition assignId;
|
||||
holder_->accept(assignId);
|
||||
|
||||
Context cxt(s, n, assignId.ids.size(, enablePackratParsing);
|
||||
Context cxt(s, n, assignId.ids.size(), enablePackratParsing);
|
||||
auto len = holder_->parse(s, n, sv, cxt, dt);
|
||||
return Result{ success(len), len, cxt.error_pos, cxt.message_pos, cxt.message };
|
||||
}
|
||||
@ -1328,7 +1328,7 @@ inline void WeakHolder::accept(Visitor& v) { v.visit(*this); }
|
||||
inline void Holder::accept(Visitor& v) { v.visit(*this); }
|
||||
inline void DefinitionReference::accept(Visitor& v) { v.visit(*this); }
|
||||
|
||||
inline void DefinitionIDs::visit(Holder& ope) {
|
||||
inline void AssignIDToDefinition::visit(Holder& ope) {
|
||||
auto p = (void*)ope.outer_;
|
||||
if (ids.find(p) != ids.end()) {
|
||||
return;
|
||||
|
@ -172,7 +172,7 @@ TEST_CASE("Visit test", "[general]")
|
||||
TAG_NAME <= oom(seq(npd(chr(']')), dot()));
|
||||
WS <= zom(cls(" \t"));
|
||||
|
||||
DefinitionIDs defIds;
|
||||
AssignIDToDefinition defIds;
|
||||
ROOT.accept(defIds);
|
||||
|
||||
REQUIRE(defIds.ids.size() == 4);
|
||||
|
Loading…
Reference in New Issue
Block a user