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
ConvertError::new() seems to have disappeared, and I cannot find a simple way to construct a ConvertError. The constructors that would be appropriate seem to be private. There is ConvertError::with_cause but I don't have a Box<dyn Error + Send + Sync>.
This was changed in #634, im not entirely sure why though? Or well apparently there is this comment:
// Constructors are private (or hidden) as only the library or its proc-macros should construct this type.
Which is a weird change to make imo, when i made the ConvertError type the intent was that people could use it to provide some custom errors in their manual FromGodot impls. That's why the FromGodot impl is hardcoded to return this error type instead of something more generic, because it's publicly constructible. Otherwise what are people supposed to do if they wanna fallibly convert a godot-type into their own custom type? Should they implement TryFrom and do like foo.try_into() instead? @Bromeon idk what your intent was here
I'm trying to migrate the following code to the latest version:
ConvertError::new()
seems to have disappeared, and I cannot find a simple way to construct aConvertError
. The constructors that would be appropriate seem to be private. There isConvertError::with_cause
but I don't have aBox<dyn Error + Send + Sync>
.Searching the repo I've seen this pattern:
But
FromGodotError
also seems to be private.Am I missing something or is this really no longer constructible on user side?
The text was updated successfully, but these errors were encountered: