De-indent a string.
Declared in <folly/String.h>
std::string
stripLeftMargin(std::string s);
Strips the leading and the trailing whitespace-only lines. Then looks for the least indented non-whitespace-only line and removes its amount of leading whitespace from every line. Assumes leading whitespace is either all spaces or all tabs.
Purpose: including a multiline string literal in source code, indented to the level expected from context.
The de-indented string.
| Name | Description |
|---|---|
| s | The string to de-indent. |