Class RLCCalledMethodsTransfer
java.lang.Object
org.checkerframework.dataflow.cfg.node.AbstractNodeVisitor<TransferResult<AccumulationValue,AccumulationStore>,TransferInput<AccumulationValue,AccumulationStore>>
org.checkerframework.framework.flow.CFAbstractTransfer<AccumulationValue,AccumulationStore,AccumulationTransfer>
org.checkerframework.common.accumulation.AccumulationTransfer
org.checkerframework.checker.calledmethods.CalledMethodsTransfer
org.checkerframework.checker.rlccalledmethods.RLCCalledMethodsTransfer
- All Implemented Interfaces:
ForwardTransferFunction<AccumulationValue,,AccumulationStore> TransferFunction<AccumulationValue,,AccumulationStore> NodeVisitor<TransferResult<AccumulationValue,AccumulationStore>, TransferInput<AccumulationValue, AccumulationStore>>
The transfer function for the resource-leak extension to the called-methods type system.
-
Field Summary
Fields inherited from class org.checkerframework.checker.calledmethods.CalledMethodsTransfer
javaLangExceptionTypeFields inherited from class org.checkerframework.common.accumulation.AccumulationTransfer
atypeFactoryFields inherited from class org.checkerframework.framework.flow.CFAbstractTransfer
analysis, sequentialSemantics -
Constructor Summary
ConstructorsConstructorDescriptionCreate a new resource leak transfer function. -
Method Summary
Modifier and TypeMethodDescriptionvoidupdateStoreWithTempVar(TransferResult<AccumulationValue, AccumulationStore> result, Node node) This method either creates or looks up the temp var t for node, and then updates the store to give t the same type as node.visitMethodInvocation(MethodInvocationNode node, TransferInput<AccumulationValue, AccumulationStore> input) visitObjectCreation(ObjectCreationNode node, TransferInput<AccumulationValue, AccumulationStore> input) visitSwitchExpressionNode(SwitchExpressionNode node, TransferInput<AccumulationValue, AccumulationStore> input) visitTernaryExpression(TernaryExpressionNode node, TransferInput<AccumulationValue, AccumulationStore> input) Methods inherited from class org.checkerframework.checker.calledmethods.CalledMethodsTransfer
accumulate, isWpiEnabledForRLC, shouldPerformWholeProgramInference, shouldPerformWholeProgramInferenceMethods inherited from class org.checkerframework.framework.flow.CFAbstractTransfer
addInformationFromPreconditions, createTransferResult, createTransferResult, finishValue, finishValue, getNarrowedValue, getValueFromFactory, getWidenedValue, initialStore, insertIntoStores, insertIntoStoresPermitNonDeterministic, isNotFullyInitializedReceiver, moreSpecificValue, processCommonAssignment, processConditionalPostconditions, processPostconditions, recreateTransferResult, recreateTransferResult, setFixedInitialStore, splitAssignments, strengthenAnnotationOfEqualTo, usesSequentialSemantics, visitAnyPattern, visitArrayAccess, visitAssignment, visitCase, visitClassName, visitConditionalNot, visitDeconstructorPattern, visitEqualTo, visitExpressionStatement, visitFieldAccess, visitInstanceOf, visitLambdaResultExpression, visitLocalVariable, visitNarrowingConversion, visitNode, visitNotEqual, visitReturn, visitStringConversion, visitThis, visitVariableDeclaration, visitWideningConversionMethods inherited from class org.checkerframework.dataflow.cfg.node.AbstractNodeVisitor
visitArrayCreation, visitArrayType, visitAssertionError, visitBitwiseAnd, visitBitwiseComplement, visitBitwiseOr, visitBitwiseXor, visitBooleanLiteral, visitCharacterLiteral, visitClassDeclaration, visitConditionalAnd, visitConditionalOr, visitDoubleLiteral, visitExplicitThis, visitFloatingDivision, visitFloatingRemainder, visitFloatLiteral, visitGreaterThan, visitGreaterThanOrEqual, visitImplicitThis, visitIntegerDivision, visitIntegerLiteral, visitIntegerRemainder, visitLeftShift, visitLessThan, visitLessThanOrEqual, visitLongLiteral, visitMarker, visitMemberReference, visitMethodAccess, visitNullChk, visitNullLiteral, visitNumericalAddition, visitNumericalMinus, visitNumericalMultiplication, visitNumericalPlus, visitNumericalSubtraction, visitPackageName, visitParameterizedType, visitPrimitiveType, visitShortLiteral, visitSignedRightShift, visitStringConcatenate, visitStringLiteral, visitSuper, visitSynchronized, visitThrow, visitTypeCast, visitUnsignedRightShift, visitValueLiteralMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.checkerframework.dataflow.cfg.node.NodeVisitor
visitArrayCreation, visitArrayType, visitAssertionError, visitBitwiseAnd, visitBitwiseComplement, visitBitwiseOr, visitBitwiseXor, visitBooleanLiteral, visitCharacterLiteral, visitClassDeclaration, visitConditionalAnd, visitConditionalOr, visitDoubleLiteral, visitExplicitThis, visitFloatingDivision, visitFloatingRemainder, visitFloatLiteral, visitGreaterThan, visitGreaterThanOrEqual, visitImplicitThis, visitIntegerDivision, visitIntegerLiteral, visitIntegerRemainder, visitLeftShift, visitLessThan, visitLessThanOrEqual, visitLongLiteral, visitMarker, visitMemberReference, visitMethodAccess, visitNullChk, visitNullLiteral, visitNumericalAddition, visitNumericalMinus, visitNumericalMultiplication, visitNumericalPlus, visitNumericalSubtraction, visitPackageName, visitParameterizedType, visitPrimitiveType, visitShortLiteral, visitSignedRightShift, visitStringConcatenate, visitStringLiteral, visitSuper, visitSynchronized, visitThrow, visitTypeCast, visitUnsignedRightShift
-
Constructor Details
-
RLCCalledMethodsTransfer
Create a new resource leak transfer function.- Parameters:
analysis- the analysis. Its type factory must be aRLCCalledMethodsAnnotatedTypeFactory.
-
-
Method Details
-
visitTernaryExpression
public TransferResult<AccumulationValue,AccumulationStore> visitTernaryExpression(TernaryExpressionNode node, TransferInput<AccumulationValue, AccumulationStore> input) - Specified by:
visitTernaryExpressionin interfaceNodeVisitor<TransferResult<AccumulationValue,AccumulationStore>, TransferInput<AccumulationValue, AccumulationStore>> - Overrides:
visitTernaryExpressionin classCFAbstractTransfer<AccumulationValue,AccumulationStore, AccumulationTransfer>
-
visitSwitchExpressionNode
public TransferResult<AccumulationValue,AccumulationStore> visitSwitchExpressionNode(SwitchExpressionNode node, TransferInput<AccumulationValue, AccumulationStore> input) - Specified by:
visitSwitchExpressionNodein interfaceNodeVisitor<TransferResult<AccumulationValue,AccumulationStore>, TransferInput<AccumulationValue, AccumulationStore>> - Overrides:
visitSwitchExpressionNodein classCFAbstractTransfer<AccumulationValue,AccumulationStore, AccumulationTransfer>
-
visitMethodInvocation
public TransferResult<AccumulationValue,AccumulationStore> visitMethodInvocation(MethodInvocationNode node, TransferInput<AccumulationValue, AccumulationStore> input) - Specified by:
visitMethodInvocationin interfaceNodeVisitor<TransferResult<AccumulationValue,AccumulationStore>, TransferInput<AccumulationValue, AccumulationStore>> - Overrides:
visitMethodInvocationin classCalledMethodsTransfer
-
visitObjectCreation
public TransferResult<AccumulationValue,AccumulationStore> visitObjectCreation(ObjectCreationNode node, TransferInput<AccumulationValue, AccumulationStore> input) - Specified by:
visitObjectCreationin interfaceNodeVisitor<TransferResult<AccumulationValue,AccumulationStore>, TransferInput<AccumulationValue, AccumulationStore>> - Overrides:
visitObjectCreationin classCFAbstractTransfer<AccumulationValue,AccumulationStore, AccumulationTransfer>
-
updateStoreWithTempVar
public void updateStoreWithTempVar(TransferResult<AccumulationValue, AccumulationStore> result, Node node) This method either creates or looks up the temp var t for node, and then updates the store to give t the same type as node. Temporary variables are supported for expressions throughout this checker (and the Must Call Checker) to enable refinement of their types. See the documentation ofMustCallConsistencyAnalyzerfor more details.- Parameters:
result- the transfer result containing the store to be modifiednode- the node to be assigned to a temporary variable
-