LibJS: Delete unused operator=
s in SafeFunction
This commit is contained in:
parent
70919dbed7
commit
ee29a21ae8
Notes:
sideshowbarker
2024-07-17 16:42:19 +09:00
Author: https://github.com/kalenikaliaksandr Commit: https://github.com/SerenityOS/serenity/commit/ee29a21ae8 Pull-request: https://github.com/SerenityOS/serenity/pull/20614
1 changed files with 0 additions and 19 deletions
|
@ -83,25 +83,6 @@ public:
|
|||
|
||||
explicit operator bool() const { return !!callable_wrapper(); }
|
||||
|
||||
template<typename CallableType>
|
||||
SafeFunction& operator=(CallableType&& callable)
|
||||
requires((AK::IsFunctionObject<CallableType> && IsCallableWithArguments<CallableType, Out, In...>))
|
||||
{
|
||||
clear();
|
||||
init_with_callable(forward<CallableType>(callable), CallableKind::FunctionObject);
|
||||
return *this;
|
||||
}
|
||||
|
||||
template<typename FunctionType>
|
||||
SafeFunction& operator=(FunctionType f)
|
||||
requires((AK::IsFunctionPointer<FunctionType> && IsCallableWithArguments<RemovePointer<FunctionType>, Out, In...>))
|
||||
{
|
||||
clear();
|
||||
if (f)
|
||||
init_with_callable(move(f), CallableKind::FunctionPointer);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SafeFunction& operator=(nullptr_t)
|
||||
{
|
||||
clear();
|
||||
|
|
Loading…
Add table
Reference in a new issue