MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / PushDot

Method PushDot

extern/re2/re2/parse.cc:455–464  ·  view source on GitHub ↗

Pushes a . onto the stack.

Source from the content-addressed store, hash-verified

453
454// Pushes a . onto the stack.
455bool Regexp::ParseState::PushDot() {
456 if ((flags_ & DotNL) && !(flags_ & NeverNL))
457 return PushSimpleOp(kRegexpAnyChar);
458 // Rewrite . into [^\n]
459 Regexp* re = new Regexp(kRegexpCharClass, flags_ & ~FoldCase);
460 re->ccb_ = new CharClassBuilder;
461 re->ccb_->AddRange(0, '\n' - 1);
462 re->ccb_->AddRange('\n' + 1, rune_max_);
463 return PushRegexp(re);
464}
465
466// Pushes a regexp with the given op (and no args) onto the stack.
467bool Regexp::ParseState::PushSimpleOp(RegexpOp op) {

Callers 1

ParseMethod · 0.80

Calls 1

AddRangeMethod · 0.80

Tested by

no test coverage detected