diff --git a/checker/src/main/java/org/checkerframework/checker/resourceleak/MustCallConsistencyAnalyzer.java b/checker/src/main/java/org/checkerframework/checker/resourceleak/MustCallConsistencyAnalyzer.java index 0a02f52513ef..b9a68de18427 100644 --- a/checker/src/main/java/org/checkerframework/checker/resourceleak/MustCallConsistencyAnalyzer.java +++ b/checker/src/main/java/org/checkerframework/checker/resourceleak/MustCallConsistencyAnalyzer.java @@ -1540,7 +1540,7 @@ private void checkReassignmentToField(Set obligations, AssignmentNod formatMissingMustCallMethods(mcValues), "field " + lhsElement.getSimpleName().toString(), lhsElement.asType().toString(), - "Field assignment outside method or declaration might overwrite field's" + "field assignment outside method or declaration might overwrite field's" + " current value"); return; } @@ -1667,7 +1667,7 @@ && varTrackedInObligations(obligations, (LocalVariableNode) receiver)) formatMissingMustCallMethods(mcValues), "field " + lhsElement.getSimpleName().toString(), lhsElement.asType().toString(), - " Non-final owning field might be overwritten"); + "non-final owning field might be overwritten"); } } } @@ -2045,9 +2045,9 @@ private void propagateObligationsToSuccessorBlock( // exit, but that doesn't seem to provide additional helpful // information. "regular method exit" - : "possible exceptional exit due to " + : "possible exceptional exit before required method call, triggered by " + ((ExceptionBlock) currentBlock).getNode().getTree() - + " with exception type " + + " throwing exception type " + exceptionType; // Computed outside the Obligation loop for efficiency. AccumulationStore regularStoreOfSuccessor = cmAtf.getInput(successor).getRegularStore(); diff --git a/checker/src/main/java/org/checkerframework/checker/resourceleak/messages.properties b/checker/src/main/java/org/checkerframework/checker/resourceleak/messages.properties index a9df3c247117..d611635c54cb 100644 --- a/checker/src/main/java/org/checkerframework/checker/resourceleak/messages.properties +++ b/checker/src/main/java/org/checkerframework/checker/resourceleak/messages.properties @@ -1,4 +1,4 @@ -required.method.not.called=@MustCall %s may not have been invoked on %s or any of its aliases.%nThe type of object is: %s.%nReason for going out of scope: %s +required.method.not.called=Required %s may not have been invoked on %s or any of its aliases.%nThe type of object is: %s.%nReason for going out of scope: %s missing.creates.mustcall.for=Method %s re-assigns the non-final, owning field %s.%s, but does not have a corresponding @CreatesMustCallFor annotation. incompatible.creates.mustcall.for=Method %s re-assigns the non-final, owning field %s.%s, but its @CreatesMustCallFor annotation targets %s. reset.not.owning=Calling method %s resets the must-call obligations of the expression %s, which is non-owning. Either annotate its declaration with an @Owning annotation, extract it into a local variable, or write a corresponding @CreatesMustCallFor annotation on the method that encloses this statement. diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index d5f4d358af06..e99c2b15aba8 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -11,6 +11,7 @@ Optional Checker. **Closed issues:** +eisop#1542. Version 3.49.5-eisop1 (April 26, 2026) --------------------------------------