Gridview not deallocating on removing / memory leak

System: SDK 1.11.1, on M1 iMac, Nova, macOS 12.4

Expected: When creating a gridview, and then subsequently setting it to nil, it's expected that the memory is properly released (or, that there is a dedicated :remove function on ui.gridview?)

Repro: Run the below project, press A repeatedly to create and remove gridviews. Check malloc map to see consistent increases in heap usage.

Notes: I'm pretty green with memory allocation stuff, so I may not understand how Lua or the SDK is supposed to handle things when set to nil. If there's a proper way to "destroy" something like this and I'm not aware, please let me know ! (137.9 KB)


Update: As of the 1.12.0 update, this "leak" (or whatever was happening) is fixed! I couldn't find anything specific in the changelog that mentioned anything about changes to gridview, but I'm glad it's fixed. :slight_smile: Thank you devs !

1 Like