Browse Source

LibJS: Move the "other" optional completion in the move constructor

Otherwise, we invoke a non-trival copy. Caught by clangd.
Timothy Flynn 2 years ago
parent
commit
ba97f6a0d3
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Userland/Libraries/LibJS/Runtime/Completion.h

+ 1 - 1
Userland/Libraries/LibJS/Runtime/Completion.h

@@ -140,7 +140,7 @@ public:
     }
 
     Optional(Optional&& other)
-        : m_value(other.m_value)
+        : m_value(move(other.m_value))
     {
     }