ladybird/AK
Jonne Ransijn 75b482bbb9 AK: Fix "assignment from temporary" check of Optional::operator=
There was an existing check to ensure that `U` was an lvalue reference,
but when this check fails, overload resolution will just move right on
to the copy asignment operator, which will cause the temporary to be
assigned anyway.

Disallowing `Optional<T&>`s to be created from temporaries entirely
would be undesired, since existing code has valid reasons for creating
`Optional<T&>`s from temporaries, such as for function call arguments.

This fix explicitly deletes the `Optional::operator=(U&&)` operator,
so overload resolution stops.
2024-11-24 23:04:34 -07:00
..
.clang-tidy
AK+Swift.swift AK: Add an extension to construct an AK.String from a Swift.String 2024-11-19 14:32:11 -07:00
AllOf.h
AnyOf.h
Array.h AK: Add to_array() 2024-02-11 18:53:00 +01:00
Assertions.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Assertions.h AK: Remove clang-tidy warnings for VERIFY(a || b) lines 2024-11-09 17:55:03 +01:00
Atomic.h LibJS: Implement tc39/proposal-atomics-microwait (Atomics.pause) 2024-11-03 08:05:58 -05:00
AtomicRefCounted.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Backtrace.h.in AK+CMake: Use the find module to find the correct backtrace(3) header 2024-07-01 10:15:24 -06:00
Badge.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Base64.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Base64.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
BigIntBase.h AK: Move generalized internals of UFixedBigIntDivision to BigIntBase 2024-03-25 14:26:29 -06:00
BinaryHeap.h AK: Introduce IntrusiveBinaryHeap and reimplement BinaryHeap using it 2024-02-25 17:24:36 -07:00
BinarySearch.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
BitCast.h AK: Use bit_cast in SIMDExtras.h/AK::Detail::byte_reverse_impl 2024-07-17 09:56:13 -06:00
Bitmap.h LibGfx: Clean up #include directives 2024-11-20 21:13:23 +01:00
BitmapView.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
BitStream.h AK: Add BigEndianInputBitStream::bits_until_next_byte_boundary() 2024-02-12 14:08:56 +01:00
BufferedStream.h AK: Don't move trivially copyable types in BufferedStream methods 2024-04-30 13:22:56 +02:00
BuiltinWrappers.h AK: Fix doc comment for bit_scan_forward 2023-10-11 14:36:48 -04:00
BumpAllocator.h
ByteBuffer.h AK: Use simdutf when appending UTF-16 to StringBuilder 2024-10-30 10:28:24 +01:00
ByteReader.h
ByteString.cpp AK: Remove DeprecatedStringCodePointIterator 2024-11-14 23:06:42 +01:00
ByteString.h AK: Remove DeprecatedStringCodePointIterator 2024-11-14 23:06:42 +01:00
CharacterTypes.h AK: Add is_ascii_c0_control_or_space 2024-08-05 17:21:26 +01:00
Checked.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
CheckedFormatString.h AK: Enable format string checking in Clang builds 2024-05-29 13:34:15 -06:00
CircularBuffer.cpp
CircularBuffer.h
CircularQueue.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
CMakeLists.txt AK: Port LexicalPath to Windows 2024-11-09 12:42:27 -07:00
Concepts.h
ConstrainedStream.cpp
ConstrainedStream.h AK: Add remaining method to ConstrainedStream 2024-07-09 14:22:31 +02:00
CopyOnWrite.h AK+LibURL: Move CopyOnWrite<T> from LibURL to AK 2024-09-10 13:51:28 +02:00
CountingStream.cpp
CountingStream.h
COWVector.h AK+LibRegex+LibWasm: Remove the non-const COWVector::operator[] 2024-03-12 17:10:47 +01:00
DateConstants.h
Debug.h.in LibDNS: Hide some debug logs behind DNS_DEBUG 2024-11-20 21:37:58 +01:00
DefaultDelete.h
Demangle.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
DeprecatedFlyString.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
DeprecatedFlyString.h AK: Pass (Deprecated)FlyString::is_one_of arguments by reference 2024-10-27 12:03:04 -04:00
Diagnostics.h
DisjointChunks.h AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
DistinctNumeric.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
DOSPackedTime.cpp
DOSPackedTime.h
DoublyLinkedList.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Endian.h AK: Support non-native endianness in Utf16View 2024-07-18 19:43:57 +02:00
EnumBits.h
Enumerate.h AK: Introduce AK::enumerate 2024-03-23 09:02:58 -04:00
Error.cpp LibCore: Add Windows version of DirIterator 2024-10-19 18:14:48 -06:00
Error.h LibCore: Add Windows version of DirIterator 2024-10-19 18:14:48 -06:00
Find.h AK: Add missing using statements to Find.h 2024-05-06 17:32:19 +02:00
FixedArray.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
FixedPoint.h AK: Stop exporting AK::FixedPoint into the global namespace 2024-07-18 09:43:38 +01:00
FloatingPoint.h Meta: Update my email address everywhere 2024-11-01 12:14:53 +01:00
FloatingPointStringConversions.cpp AK: Implement floating-point conversions for big-endian 2024-07-05 09:47:08 -06:00
FloatingPointStringConversions.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
FlyString.cpp AK: Add template specializations for Optional<{,Fly}String> 2024-10-31 23:26:22 +01:00
FlyString.h AK: Add template specializations for Optional<{,Fly}String> 2024-10-31 23:26:22 +01:00
Format.cpp AK: Add 16-bit float type 2024-11-10 14:48:20 -07:00
Format.h AK: Add 16-bit float type 2024-11-10 14:48:20 -07:00
Forward.h AK: Remove DeprecatedStringCodePointIterator 2024-11-14 23:06:42 +01:00
Function.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
GenericLexer.cpp AK: Avoid returning null StringViews instead of empty views 2024-11-05 14:01:45 +00:00
GenericLexer.h AK: Avoid returning null StringViews instead of empty views 2024-11-05 14:01:45 +00:00
GenericShorthands.h
HashFunctions.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
HashMap.h AK: Add OrderedHashMap::take_first() 2024-10-24 20:55:08 +02:00
HashTable.h Meta: Update my email address everywhere 2024-11-01 12:14:53 +01:00
Hex.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Hex.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
IDAllocator.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
InsertionSort.h
IntegralMath.h AK: Fix off by one error in integral ceil_log2() 2024-05-21 09:31:17 +02:00
IntrusiveDetails.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
IntrusiveList.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
IntrusiveListRelaxedConst.h
IntrusiveRedBlackTree.h
IPv4Address.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
IPv6Address.h AK: Disable implicit conversion from char* -> ipv4 -> ipv6 2024-11-20 21:37:58 +01:00
IterationDecision.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Iterator.h AK+LibJS: Add [[nodiscard]] to operator* in common types 2024-10-25 09:15:28 +02:00
JsonArray.h AK: Allow creating a JsonArray with an initial size 2024-11-03 17:51:58 +01:00
JsonArraySerializer.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
JsonObject.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
JsonObject.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
JsonObjectSerializer.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
JsonParser.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
JsonParser.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
JsonValue.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
JsonValue.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
kmalloc.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
kmalloc.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
LEB128.h AK/LEB128: Speed up reading unsigned LEB128 values 2024-07-27 08:19:51 +02:00
LexicalPath.cpp AK: Add LexicalPath::is_root() 2024-11-19 22:07:01 -07:00
LexicalPath.h AK: Add LexicalPath::is_root() 2024-11-19 22:07:01 -07:00
LexicalPathWindows.cpp AK: Add LexicalPath::is_root() 2024-11-19 22:07:01 -07:00
LsanSuppressions.h LibGfx+LibWeb: Replace remaining OpenType implementation with Skia 2024-09-05 19:21:52 +02:00
Math.h AK: Implement floating-point conversions for big-endian 2024-07-05 09:47:08 -06:00
MaybeOwned.h AK: Allow creating a MaybeOwned<Superclass> from a MaybeOwned<Subclass> 2024-03-25 20:35:00 +01:00
MemMem.h
Memory.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
MemoryStream.cpp AK: Use an enum to specify the open mode instead of a bool 2023-11-08 18:19:34 +01:00
MemoryStream.h AK: Use an enum to specify the open mode instead of a bool 2023-11-08 18:19:34 +01:00
NeverDestroyed.h AK: Include missing StdLibExtras from NeverDestroyed 2024-11-19 14:32:11 -07:00
NoAllocationGuard.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
Noncopyable.h AK: Move "conditional xtor" pattern into a macro 2024-10-31 23:26:22 +01:00
NonnullOwnPtr.h AK+LibJS: Add [[nodiscard]] to operator* in common types 2024-10-25 09:15:28 +02:00
NonnullRawPtr.h AK: Add NonnullRawPtr<T> abstraction 2024-11-06 09:43:15 +00:00
NonnullRefPtr.h AK+LibJS: Add [[nodiscard]] to operator* in common types 2024-10-25 09:15:28 +02:00
NumberFormat.cpp AK+LibJS: Don't use Temporal for console.time() and console.timeLog() 2024-11-18 17:46:41 -05:00
NumberFormat.h AK+LibJS: Don't use Temporal for console.time() and console.timeLog() 2024-11-18 17:46:41 -05:00
NumericLimits.h AK: Add 16-bit float type 2024-11-10 14:48:20 -07:00
Optional.h AK: Fix "assignment from temporary" check of Optional::operator= 2024-11-24 23:04:34 -07:00
OptionParser.cpp AK: Update OptionParser::m_arg_index by substracting skipped args 2024-02-06 00:08:30 +01:00
OptionParser.h
OwnPtr.h AK+LibJS: Add [[nodiscard]] to operator* in common types 2024-10-25 09:15:28 +02:00
Platform.h AK: Provide more complete definitions for AK_OS_WINDOWS 2024-10-16 12:15:31 -06:00
Queue.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
QuickSelect.h
QuickSort.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Random.cpp Everywhere: Use east const in more places 2024-04-19 06:31:19 -04:00
Random.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
RecursionDecision.h
RedBlackTree.h Everywhere: Use east const in more places 2024-04-19 06:31:19 -04:00
RefCounted.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
RefPtr.h AK+LibJS: Add [[nodiscard]] to operator* in common types 2024-10-25 09:15:28 +02:00
Result.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
ReverseIterator.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
ScopedValueRollback.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
ScopeGuard.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
ScopeLogger.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
SegmentedVector.h AK+LibWeb: Use segmented vector to store commands in RecordingPainter 2023-12-30 23:02:46 +01:00
SIMD.h AK: Add introspection helpers to SIMD.h 2024-07-17 09:56:13 -06:00
SIMDExtras.h AK/SIMDExtras: Fix masking logic in shuffle_or_0 2024-07-27 15:02:37 +02:00
SIMDMath.h AK: Remove the SIMD version of rsqrt() too, for good measure 2024-01-30 10:02:33 +01:00
Singleton.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
SinglyLinkedList.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
SinglyLinkedListSizePolicy.h
SipHash.cpp Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
SipHash.h AK: Implement SipHash as the default hash algorithm for most use cases 2023-10-01 11:06:36 +03:30
SourceGenerator.h AK: Allow escaping of keys in SourceGenerator 2024-07-09 11:21:07 +02:00
SourceLocation.h AK: Add copy assignment operator for SourceLocation 2023-09-24 14:55:32 +02:00
Span.h AK: Allow comparing spans of different constness 2024-08-13 14:11:05 +02:00
Stack.h
StackInfo.cpp AK: Use getrlimit() to find the correct main thread stack size on macOS 2024-11-10 19:12:59 +01:00
StackInfo.h
Statistics.h AK: Export Statistics to the global namespace 2024-05-18 18:30:07 +02:00
StdLibExtraDetails.h AK: Add 16-bit float type 2024-11-10 14:48:20 -07:00
StdLibExtras.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Stream.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Stream.h AK: Add a Stream::write_until_depleted overload for string types 2024-04-04 11:23:21 +02:00
String.cpp AK+LibWeb: Add {Fly,}String::to_ascii_{upper,lower}_case() 2024-10-14 20:47:35 +02:00
String.h AK+LibUnicode: Add a method to trim non-ASCII whitespace from a String 2024-11-03 20:42:46 -05:00
StringBase.cpp AK: Add template specializations for Optional<{,Fly}String> 2024-10-31 23:26:22 +01:00
StringBase.h AK: Add template specializations for Optional<{,Fly}String> 2024-10-31 23:26:22 +01:00
StringBuilder.cpp AK: Add StringBuilder::append_repeated(StringView, size_t) 2024-11-09 12:42:27 -07:00
StringBuilder.h AK: Add StringBuilder::append_repeated(StringView, size_t) 2024-11-09 12:42:27 -07:00
StringData.h AK: Construct Strings from StringBuilder without re-allocating the data 2024-07-20 06:45:49 +02:00
StringFloatingPointConversions.cpp
StringFloatingPointConversions.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
StringHash.h AK: Implement SipHash as the default hash algorithm for most use cases 2023-10-01 11:06:36 +03:30
StringImpl.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
StringImpl.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
StringUtils.cpp Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
StringUtils.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
StringView.cpp Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
StringView.h AK: Ensure empty StringViews all compare as equal 2024-11-15 23:18:29 +01:00
Swift.h AK: Add missing swift/bridging empty defines for non-Swift compilers 2024-11-19 14:32:11 -07:00
TemporaryChange.h AK: Make TemporaryChange not copy the old value twice 2024-10-10 23:53:48 +01:00
Time.cpp AK: Implement now_time_from_clock for Windows 2024-10-16 12:15:31 -06:00
Time.h AK: Implement now_time_from_clock for Windows 2024-10-16 12:15:31 -06:00
Traits.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Trie.h Everywhere: Remove all KERNEL #defines 2024-06-18 09:36:25 +02:00
Try.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
Tuple.h AK: Make IndexSequence use size_t 2024-02-11 18:53:00 +01:00
TypeCasts.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
TypedTransfer.h
TypeList.h AK: Make IndexSequence use size_t 2024-02-11 18:53:00 +01:00
Types.h AK: Define pid_t on Windows 2024-11-19 14:40:03 -07:00
UFixedBigInt.h Everywhere: Use east const in more places 2024-04-19 06:31:19 -04:00
UFixedBigIntDivision.h AK: Move generalized internals of UFixedBigIntDivision to BigIntBase 2024-03-25 14:26:29 -06:00
UnicodeUtils.h AK: Use simdutf when appending UTF-16 to StringBuilder 2024-10-30 10:28:24 +01:00
Utf8View.cpp AK: Add ASCII fast path for Utf8View::contains 2024-10-27 16:13:36 +01:00
Utf8View.h AK: Add Utf8View::for_each_split_view() method 2024-11-15 23:18:29 +01:00
Utf16View.cpp AK+Meta: Update simdutf to version 5.5.0 2024-09-19 15:48:57 -04:00
Utf16View.h AK: Use simdutf when appending UTF-16 to StringBuilder 2024-10-30 10:28:24 +01:00
Utf32View.cpp AK: Add a comparison operator for Utf32View 2024-10-20 08:50:01 +02:00
Utf32View.h AK: Add a comparison operator for Utf32View 2024-10-20 08:50:01 +02:00
Variant.h AK: Move "conditional xtor" pattern into a macro 2024-10-31 23:26:22 +01:00
Vector.h LibWeb: Implement linear easing according to latest spec 2024-11-05 10:41:29 +00:00
Weakable.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00
WeakPtr.h Meta: Update my e-mail address everywhere 2024-10-04 13:19:50 +02:00