Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
duckdb_re2::EmptyStringWalker Class Reference
Inheritance diagram for duckdb_re2::EmptyStringWalker:
Collaboration diagram for duckdb_re2::EmptyStringWalker:

Public Member Functions

virtual bool PostVisit (Regexp *re, bool parent_arg, bool pre_arg, bool *child_args, int nchild_args)
virtual bool ShortVisit (Regexp *re, bool a)
Public Member Functions inherited from duckdb_re2::Regexp::Walker< bool >
virtual bool PreVisit (Regexp *re, bool parent_arg, bool *stop)
virtual bool PostVisit (Regexp *re, bool parent_arg, bool pre_arg, bool *child_args, int nchild_args)
virtual bool Copy (bool arg)
bool Walk (Regexp *re, bool top_arg)
bool WalkExponential (Regexp *re, bool top_arg, int max_visits)
void Reset ()
bool stopped_early ()

Private Member Functions

 EmptyStringWalker (const EmptyStringWalker &)=delete
EmptyStringWalker & operator= (const EmptyStringWalker &)=delete

Constructor & Destructor Documentation

◆ EmptyStringWalker()

duckdb_re2::EmptyStringWalker::EmptyStringWalker ( )
inline
465153{}

Member Function Documentation

◆ PostVisit()

bool duckdb_re2::EmptyStringWalker::PostVisit ( Regexp * re,
bool parent_arg,
bool pre_arg,
bool * child_args,
int nchild_args )
virtual
465176 {
465177 switch (re->op()) {
465178 case kRegexpNoMatch: // never empty
465179 case kRegexpLiteral:
465180 case kRegexpAnyChar:
465181 case kRegexpAnyByte:
465182 case kRegexpCharClass:
465183 case kRegexpLiteralString:
465184 return false;
465185
465186 case kRegexpEmptyMatch: // always empty
465187 case kRegexpBeginLine: // always empty, when they match
465188 case kRegexpEndLine:
465189 case kRegexpNoWordBoundary:
465190 case kRegexpWordBoundary:
465191 case kRegexpBeginText:
465192 case kRegexpEndText:
465193 case kRegexpStar: // can always be empty
465194 case kRegexpQuest:
465195 case kRegexpHaveMatch:
465196 return true;
465197
465198 case kRegexpConcat: // can be empty if all children can
465199 for (int i = 0; i < nchild_args; i++)
465200 if (!child_args[i])
465201 return false;
465202 return true;
465203
465204 case kRegexpAlternate: // can be empty if any child can
465205 for (int i = 0; i < nchild_args; i++)
465206 if (child_args[i])
465207 return true;
465208 return false;
465209
465210 case kRegexpPlus: // can be empty if the child can
465211 case kRegexpCapture:
465212 return child_args[0];
465213
465214 case kRegexpRepeat: // can be empty if child can or is x{0}
465215 return child_args[0] || re->min() == 0;
465216 }
465217 return false;
465218}

◆ ShortVisit()

virtual bool duckdb_re2::EmptyStringWalker::ShortVisit ( Regexp * re,
bool a )
inlinevirtual

Implements duckdb_re2::Regexp::Walker< bool >.

465158 {
465159 // Should never be called: we use Walk(), not WalkExponential().
465160#ifndef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
465161 LOG(DFATAL) << "EmptyStringWalker::ShortVisit called";
465162#endif
465163 return a;
465164 }

The documentation for this class was generated from the following file: