Skip to content

Commit

Permalink
Make sure that the optional is reset instead of assigned the 0 value.
Browse files Browse the repository at this point in the history
Signed-off-by: Danila Fedorin <[email protected]>
  • Loading branch information
DanilaFe committed May 15, 2024
1 parent ae448e0 commit c0fb173
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/lib/resolution/can-pass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1001,7 +1001,7 @@ CanPassResult CanPassResult::canPass(Context* context,
// the formal. This suggests a generic actual being passed to the
// formal; this is typically not allowed, but in this case
// (canAcceptGenericActuals) it is. So, it's not an error.
got.failReason_ = {};
got.failReason_ = chpl::optional<PassingFailureReason>();
return got;
}
if (!got.passes() && formalQT.isParam()) {
Expand Down

0 comments on commit c0fb173

Please sign in to comment.