Read and interpret configuration settings from a stream.
Declared in <common/args.h>
[[nodiscard, requires_capability(0x7f2e381ab9e8)]]
bool
ReadConfigStream(
std::istream& stream,
std::string const& filepath,
std::string& error,
bool ignore_invalid_keys = false);
true if the stream was parsed successfully.
The return value should not be discarded.
| Name | Description |
|---|---|
| stream | The input stream to read config lines from. |
| filepath | Path used for error messages and section tracking. |
| error | Populated with a message if parsing fails. |
| ignore_invalid_keys | Skip unknown keys instead of failing. |