by phantombeta » Mon Dec 10, 2018 2:56 am
The
ArrayReserve template used for the direct native version of
DynArray*.Reserve doesn't return anything, leading to random bugs, as the function is actually supposed to return the value returned by TArray::Reserve.
The [url=https://github.com/coelckers/gzdoom/blob/8a4b8cc2ca3f77cd40a61ef58ba4e6483b9abbaf/src/scripting/backend/dynarrays.cpp#L124]ArrayReserve[/url] template used for the direct native version of [url=https://github.com/coelckers/gzdoom/blob/8a4b8cc2ca3f77cd40a61ef58ba4e6483b9abbaf/src/scripting/backend/dynarrays.cpp#L219]DynArray*.Reserve[/url] doesn't return anything, leading to random bugs, as the function is actually supposed to return the value returned by TArray::Reserve.