MCPcopy Create free account
hub / github.com/cel-expr/cel-cpp / FormatField

Function FormatField

tools/cel_unparser.cc:75–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

73}
74
75std::string FormatField(absl::string_view field) {
76 if (ReservedFieldIdentifiers().contains(field) ||
77 !RE2::FullMatch(field, *kSimpleIdentifierPattern)) {
78 return absl::StrCat(kBackQuote, field, kBackQuote);
79 }
80 return std::string(field);
81}
82
83class Unparser {
84 public:

Callers 3

VisitSelectMethod · 0.85
VisitOptSelectMethod · 0.85
VisitCreateStructMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected