Class ObjectAccessFinalStep
java.lang.Object
org.ek9lang.compiler.support.ObjectAccessFinalStep
- All Implemented Interfaces:
Function<EK9Parser.ObjectAccessExpressionContext, EK9Parser.ObjectAccessTypeContext>
public final class ObjectAccessFinalStep
extends Object
implements Function<EK9Parser.ObjectAccessExpressionContext, EK9Parser.ObjectAccessTypeContext>
THE final
.step of an objectAccessExpression chain - .name in getHolder().name - or
null when the chain has no steps. Use this, never a hand-written walk to the last link.
Grammar:
objectAccessExpression : objectAccessStart objectAccess objectAccess : objectAccessType objectAccess? // RECURSIVE objectAccessType : DOT (identifier | operationCall)
The other questions about the same chain are EndsWithOperationCall, ReachesFinalStepThroughCall
and ObjectAccessStepCount - phase 3 (AssignmentStatementOrError, E07895) and phase 7
(AssignmentStmtGenerator) ask the same ones, so the two cannot drift. Was ObjectAccessChain.finalStep
(no-statics lane S3, 2026-10-29), which also replaced four hand-written walks to the last link (phase 3
InstructionBlockVariablesOrError, phase 5 PreIRListener and
MakesIdentifierSubsequentAccessSafe, MCP PropertyWriteSites): objectAccessType is not
optional in the grammar, so on any parsed chain every walk stops at the same last link.
-
Constructor Details
-
ObjectAccessFinalStep
public ObjectAccessFinalStep()
-
-
Method Details
-
apply
- Specified by:
applyin interfaceFunction<EK9Parser.ObjectAccessExpressionContext, EK9Parser.ObjectAccessTypeContext>
-