Class CheckSuitableToExtend

java.lang.Object
org.ek9lang.compiler.common.RuleSupport
org.ek9lang.compiler.phase2.CheckSuitableToExtend
All Implemented Interfaces:
Function<org.antlr.v4.runtime.ParserRuleContext,Optional<ISymbol>>

final class CheckSuitableToExtend extends RuleSupport implements Function<org.antlr.v4.runtime.ParserRuleContext,Optional<ISymbol>>
Checks for a type is resolved and is suitable to be extended from (in basic terms). This does not include the 'allows only' graph that has to be done one the whole type hierarchy has been established.
  • Constructor Details

    • CheckSuitableToExtend

      CheckSuitableToExtend(SymbolsAndScopes symbolsAndScopes, ErrorListener errorListener, ISymbol.SymbolGenus genus, boolean issueErrorIfNotResolved)
      Checks that the typedef/identifierReference passed in (when resolved) is suitable to be extended from.
    • CheckSuitableToExtend

      public CheckSuitableToExtend(SymbolsAndScopes symbolsAndScopes, ErrorListener errorListener, List<ISymbol.SymbolGenus> genus, boolean issueErrorIfNotResolved)
      Checks that the typedef/identifierReference passed in (when resolved) is suitable to be extended from. Accepts multiple allowed genus. i.e. FUNCTION and FUNCTION_TRAIT.
  • Method Details