Class StructuredReturn
- java.lang.Object
-
- org.benf.cfr.reader.bytecode.analysis.structured.statement.AbstractStructuredStatement
-
- org.benf.cfr.reader.bytecode.analysis.structured.statement.StructuredReturn
-
- All Implemented Interfaces:
HasByteCodeLoc,Matcher<StructuredStatement>,BoxingProcessor,StructuredStatement,Dumpable,TypeUsageCollectable
public class StructuredReturn extends AbstractStructuredStatement implements BoxingProcessor
-
-
Field Summary
Fields Modifier and Type Field Description private JavaTypeInstancefnReturnTypeprivate Expressionvalue
-
Constructor Summary
Constructors Constructor Description StructuredReturn(BytecodeLoc loc)StructuredReturn(BytecodeLoc loc, Expression value, JavaTypeInstance fnReturnType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapplyNonArgExpressionRewriter(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers, StatementContainer statementContainer, ExpressionRewriterFlags flags)booleancanFall()voidcollectTypeUsages(TypeUsageCollector collector)Dumperdump(Dumper dumper)booleanequals(java.lang.Object obj)BytecodeLocgetCombinedLoc()ExpressiongetValue()voidlinearizeInto(java.util.List<StructuredStatement> out)booleanmatch(MatchIterator<StructuredStatement> matchIterator, MatchResultCollector matchResultCollector)booleanrewriteBoxing(PrimitiveBoxingRewriter boxingRewriter)voidrewriteExpressions(ExpressionRewriter expressionRewriter)voidtraceLocalVariableScope(LValueScopeDiscoverer scopeDiscoverer)voidtransformStructuredChildren(StructuredStatementTransformer transformer, StructuredScope scope)-
Methods inherited from class org.benf.cfr.reader.bytecode.analysis.structured.statement.AbstractStructuredStatement
addLoc, alwaysDefines, canDefine, claimBlock, fallsNopToNext, findCreatedHere, getBreakableBlockOrNull, getContainer, getInline, getLoc, informBlockHeirachy, inlineable, isEffectivelyNOP, isProperlyStructured, isRecursivelyStructured, isScopeBlock, markCreator, setContainer, suggestName, supportsBreak, supportsContinueBreak, toString, transformStructuredChildrenInReverse
-
-
-
-
Field Detail
-
value
private Expression value
-
fnReturnType
private final JavaTypeInstance fnReturnType
-
-
Constructor Detail
-
StructuredReturn
public StructuredReturn(BytecodeLoc loc)
-
StructuredReturn
public StructuredReturn(BytecodeLoc loc, Expression value, JavaTypeInstance fnReturnType)
-
-
Method Detail
-
getCombinedLoc
public BytecodeLoc getCombinedLoc()
- Specified by:
getCombinedLocin interfaceHasByteCodeLoc
-
collectTypeUsages
public void collectTypeUsages(TypeUsageCollector collector)
- Specified by:
collectTypeUsagesin interfaceTypeUsageCollectable
-
getValue
public Expression getValue()
-
transformStructuredChildren
public void transformStructuredChildren(StructuredStatementTransformer transformer, StructuredScope scope)
- Specified by:
transformStructuredChildrenin interfaceStructuredStatement
-
linearizeInto
public void linearizeInto(java.util.List<StructuredStatement> out)
- Specified by:
linearizeIntoin interfaceStructuredStatement
-
traceLocalVariableScope
public void traceLocalVariableScope(LValueScopeDiscoverer scopeDiscoverer)
- Specified by:
traceLocalVariableScopein interfaceStructuredStatement
-
rewriteBoxing
public boolean rewriteBoxing(PrimitiveBoxingRewriter boxingRewriter)
- Specified by:
rewriteBoxingin interfaceBoxingProcessor
-
applyNonArgExpressionRewriter
public void applyNonArgExpressionRewriter(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers, StatementContainer statementContainer, ExpressionRewriterFlags flags)
- Specified by:
applyNonArgExpressionRewriterin interfaceBoxingProcessor
-
rewriteExpressions
public void rewriteExpressions(ExpressionRewriter expressionRewriter)
- Specified by:
rewriteExpressionsin interfaceStructuredStatement
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
canFall
public boolean canFall()
- Specified by:
canFallin interfaceStructuredStatement- Overrides:
canFallin classAbstractStructuredStatement
-
match
public boolean match(MatchIterator<StructuredStatement> matchIterator, MatchResultCollector matchResultCollector)
- Specified by:
matchin interfaceMatcher<StructuredStatement>- Overrides:
matchin classAbstractStructuredStatement
-
-