mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 00:17:46 +00:00
LibJS: Use move semantics more when creating Reference objects
Turns a bunch of FlyString copies into moves.
This commit is contained in:
parent
6704961c82
commit
0d2c3f62d3
5 changed files with 18 additions and 18 deletions
|
@ -70,15 +70,15 @@ public:
|
|||
: m_type(Type::String)
|
||||
, m_string(FlyString(string))
|
||||
{
|
||||
VERIFY(!string.is_null());
|
||||
VERIFY(!m_string.is_null());
|
||||
}
|
||||
|
||||
PropertyName(FlyString const& string, StringMayBeNumber string_may_be_number = StringMayBeNumber::Yes)
|
||||
PropertyName(FlyString string, StringMayBeNumber string_may_be_number = StringMayBeNumber::Yes)
|
||||
: m_type(Type::String)
|
||||
, m_string_may_be_number(string_may_be_number == StringMayBeNumber::Yes)
|
||||
, m_string(string)
|
||||
, m_string(move(string))
|
||||
{
|
||||
VERIFY(!string.is_null());
|
||||
VERIFY(!m_string.is_null());
|
||||
}
|
||||
|
||||
PropertyName(Symbol& symbol)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue