FastLED 3.9.15
Loading...
Searching...
No Matches

◆ operator->()

template<typename Key, typename T, typename Hash = Hash<Key>, typename KeyEqual = EqualTo<Key>, int INLINED_COUNT = FASTLED_HASHMAP_INLINED_COUNT>
pointer fl::HashMap< Key, T, Hash, KeyEqual, INLINED_COUNT >::const_iterator::operator-> ( ) const
inline

Definition at line 167 of file hash_map.h.

167 {
168 // Use reinterpret_cast since pair<const Key, T> and pair<Key, T> are different types
169 // but have the same memory layout, then destroy/reconstruct to avoid assignment issues
171 auto& mutable_cached = *reinterpret_cast<mutable_value_type*>(&_cached_value);
172 mutable_cached.~mutable_value_type();
173 new (&mutable_cached) mutable_value_type(operator*());
174 return &_cached_value;
175 }

References _cached_value.