diff options
| author | 2024-04-23 18:33:17 -0700 | |
|---|---|---|
| committer | 2024-05-01 17:29:13 -0700 | |
| commit | 2e85e1b37bb9bd6f432614873ed74c9a5d53d45f (patch) | |
| tree | d450582363edff63683a7e9747043ccdadc17be6 /libs/gui/DisplayLuts.cpp | |
| parent | 23550ef3ad955f435cf0d2d16d21f31ecd448dae (diff) | |
ftl: non_null improvements
* Disallow NonNull<bool> by checking for nullptr, instead of false.
* Add an "operator bool()" to work like other smart pointers.
* Add [[nodiscard]] where it makes sense.
* Implement the full set of comparison operations, and allow
comparisons between NonNull<P> and another type Q. This allows the
use of NonNull<P> in sorted containers like std::set, and allows
easier lookup via unwrapped pointers.
* Specialize std::hash for NonNull. This allows the use of NonNull<P> in
hashed containers like std::unordered_set.
Test: atest ftl_test
Bug: 185536303
Change-Id: Ib1090e393ea5f5641be2cd9c61011049039ea615
Diffstat (limited to 'libs/gui/DisplayLuts.cpp')
0 files changed, 0 insertions, 0 deletions