[serialize] Fix copy() calling operator=
9f610ae239 (commitcomment-33944686)
This commit is contained in:
parent
6492b2345c
commit
1c56b5d1d8
|
@ -375,7 +375,7 @@ struct hb_serialize_context_t
|
||||||
(Type *, src.copy (this, hb_forward<Ts> (ds)...))
|
(Type *, src.copy (this, hb_forward<Ts> (ds)...))
|
||||||
|
|
||||||
template <typename Type> auto
|
template <typename Type> auto
|
||||||
_copy (const Type &src, hb_priority<0>) -> decltype (&(src = src))
|
_copy (const Type &src, hb_priority<0>) -> decltype (&(hb_declval<Type> () = src))
|
||||||
{
|
{
|
||||||
Type *ret = this->allocate_size<Type> (sizeof (Type));
|
Type *ret = this->allocate_size<Type> (sizeof (Type));
|
||||||
if (unlikely (!ret)) return nullptr;
|
if (unlikely (!ret)) return nullptr;
|
||||||
|
|
Loading…
Reference in New Issue