Class OperationInstr
java.lang.Object
org.ek9lang.compiler.ir.instructions.OperationInstr
- All Implemented Interfaces:
Comparable<OperationInstr>, INode
An operation on some sort on a Construct.
By this we are talking about methods and operators, but also constructors and 'init' operations.
For example in the case of normal classes/traits/components etc. this would just be a method.
In the case of a function it would also be a method but with a name of 'call' and the normal function signature would be applied (to the 'call' operation).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(INodeVisitor visitor) intgetBody()The resolved, arity-aware backend method name for this operation — the name a back-end MUST emit for the DEFINITION, and never re-derive from the operator glyph.setBody(BasicBlockInstr basicBlockBody) toString()
-
Constructor Details
-
OperationInstr
-
-
Method Details
-
getBody
-
setBody
-
getSymbol
-
getResolvedMethodName
The resolved, arity-aware backend method name for this operation — the name a back-end MUST emit for the DEFINITION, and never re-derive from the operator glyph. MirrorsCallDetails.methodNameon the call side so both planes agree. In particular the arity-overloadedoperator -resolves to_negatewhen arg-less (unary negate) and_subwhen arg-bearing (binary subtract) — the IR carries the correct name so the back-ends stop deducing (and stop mis-deducing arg-less-as_sub). Computed lazily from the symbol so the method's parameter list is always fully populated by read time. Non-operator methods return their plain name.- Returns:
- the resolved runtime method name for this operation
-
getDebugInfo
-
toString
-
accept
-
compareTo
- Specified by:
compareToin interfaceComparable<OperationInstr>
-