MCPcopy Create free account
hub / github.com/apache/impala / SubstituteArg

Method SubstituteArg

be/src/gutil/strings/substitute.h:76–77  ·  view source on GitHub ↗

We must explicitly overload char* so that the compiler doesn't try to cast it to bool to construct a DynamicSubstituteArg. Might as well overload const string& as well, since this allows us to avoid a temporary object.

Source from the content-addressed store, hash-verified

74 // overload const string& as well, since this allows us to avoid a temporary
75 // object.
76 inline SubstituteArg(const char* value) // NOLINT(runtime/explicit)
77 : text_(value), size_(value == NULL ? 0 : strlen(text_)) {}
78 inline SubstituteArg(const string& value) // NOLINT(runtime/explicit)
79 : text_(value.data()), size_(value.size()) {}
80 inline SubstituteArg(const StringPiece& value) // NOLINT(runtime/explicit)

Callers

nothing calls this directly

Calls 8

FastInt32ToBufferLeftFunction · 0.85
FastUInt32ToBufferLeftFunction · 0.85
FastInt64ToBufferLeftFunction · 0.85
FastUInt64ToBufferLeftFunction · 0.85
FloatToBufferFunction · 0.85
DoubleToBufferFunction · 0.85
dataMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected