[#llvm-has_single_bit] = xref:llvm.adoc[llvm]::has_single_bit :relfileprefix: ../ :mrdocs: Return true if `Value` is a non‐zero power of two. == Synopsis Declared in `<llvm/ADT/bit.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template<typename T> requires std::is_unsigned_v<T> [[nodiscard]] constexpr bool has_single_bit(T Value) noexcept; ---- == Return Value True if `Value` is a non‐zero power of two. [NOTE] ==== The return value https://en.cppreference.com/cpp/language/attributes/nodiscard[should not be discarded^]. ==== == Parameters [cols="1,4"] |=== | Name| Description | *Value* | Unsigned value to test. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#