You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Lower priority, since this can (likely) be added in a backwards-compatible way and thus shouldn't block 0.3.0 release.
Disconnecting by passing in the same function again is unreliable, especially for closures and other ad-hoc FnMut objects. Ideally we could go for such an API:
let handle = self.signals().my_signal().connect(...);
handle.disconnect();
Maybe related, we should check what to do with connected signals once their object dies (e.g. through queue_free).
At the moment, connected signals panic with:
{Class}::bind_mut: access to instance with ID {id} after it has been freed
Maybe auto-disconnect is an option in cases where the object is known to godot-rust (passed in as connect_self/connect_other argument)? Or a detection + more precise warning + advice to disconnect signals on death?
Related to #1000
The text was updated successfully, but these errors were encountered: