Converts the given string into a boolean, returning true if successful.
Declared in <absl/strings/numbers.h>
[[nodiscard]]
bool
SimpleAtob(
std::string_view str,
bool* out);
The following case-insensitive strings are interpreted as boolean true: "true", "t", "yes", "y", "1". The following case-insensitive strings are interpreted as boolean false: "false", "f", "no", "n", "0". If any errors are encountered, this function returns false, leaving out in an unspecified state.
| Name | Description |
|---|---|
| str | The string to parse. |
| out | The location that receives the parsed value. |