[#absl-SetFlag-0d] = xref:absl.adoc[absl]::SetFlag :relfileprefix: ../ :mrdocs: Sets the value of an `absl::Flag` to the value `v`. Do not construct an `absl::Flag<T>` directly and call `absl::SetFlag()`; instead, use the flag's variable name (e.g. `FLAGS_name`). This function is thread‐safe, but is potentially expensive. Avoid setting flags in general, but especially within performance‐critical code. == Synopsis Declared in `<absl/flags/flag.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<typename T> void SetFlag( xref:absl/Flag.adoc[absl::Flag<T>]* flag, T const& v); ---- == Parameters [cols="1,4"] |=== | Name| Description | *flag* | The flag to update. | *v* | The new value to assign to `flag`. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#