Modify because destructors do cause it to use mem

This commit is contained in:
rtldg 2025-03-02 03:20:46 +00:00
parent 57929cabcf
commit 4b87f92ed0

View File

@ -1303,7 +1303,19 @@ static_assert(false, "Missing registers saving for linux");
//
//
// Result: we cannot detect if it should be register or memory without knowing the layout of the object.
return false;
//
//
// It doesn't seem like constructors or copy-constructors matter much.
if ((pi.flags & PassInfo::PassFlag_ODtor) != 0)
{
pi.flags |= PassInfo::PassFlag_RetMem;
return true;
}
else
{
return false;
}
#endif
}
}