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
This shouldn't error with 'field is never initialized'.
The real use case for this is of the form:
new() {
res = some_operation();
if res.is_err() {
fail "This is a specific and helpful error message about the failure of some_operation().";
} else {
some_local = res.get();
}
}
This can be worked around by initializing some_local to a placeholder value, but the type of some_local may not provide a convenient one. It can also be worked around in this specific case by not casing, and just setting some_local = res.get(), at the cost of a less useful error message.