Class ParameterizedOperationDetailContextOrError

java.lang.Object
org.ek9lang.compiler.phase7.support.ParameterizedOperationDetailContextOrError
All Implemented Interfaces:
BiFunction<MethodSymbol, EK9Parser.AggregatePartsContext, EK9Parser.OperationDetailsContext>

public class ParameterizedOperationDetailContextOrError extends Object implements BiFunction<MethodSymbol, EK9Parser.AggregatePartsContext, EK9Parser.OperationDetailsContext>
Locates the Operation details context for a parameterized method by matching sourceToken identity.

Unlike OperationDetailContextOrError which matches by symbol identity, this class matches by sourceToken identity. This is necessary because when TypeSubstitution clones methods from the generic type to the parameterized type, the sourceToken is preserved (same object reference). See Symbol.java:157 - setSourceToken(this.getSourceToken()).

This enables matching parameterized methods (which are clones with substituted types) back to their original AST context in the generic type's ParsedModule.

See Also: