Return a string reference with leading whitespace removed.
Synopsis
Declared in <bdlb_stringrefutil.h>
static
bslstl::StringRef
ltrim(bslstl::StringRef const& string);
Description
Return a bslstl::StringRef object referring to the substring of (the referent data of) the specified string that excludes all leading whitespace. See {Whitespace Character Specification}. If string consists entirely of whitespace, return a zero‐length reference to the end of string (i.e., bslstl::StringRef(string.end(), 0)).
Return Value
string reference with leading whitespace removed
Parameters
Name |
Description |
string |
string whose leading whitespace is trimmed |
Created with MrDocs