Class SuitablePropertyInitialisationOrError

java.lang.Object
org.ek9lang.compiler.common.RuleSupport
org.ek9lang.compiler.common.TypedSymbolAccess
org.ek9lang.compiler.phase5.SuitablePropertyInitialisationOrError
All Implemented Interfaces:
Consumer<org.antlr.v4.runtime.tree.ParseTree>

class SuitablePropertyInitialisationOrError extends TypedSymbolAccess implements Consumer<org.antlr.v4.runtime.tree.ParseTree>
Used with aggregates to check that is they have any properties that are not initialised at declaration there are no default or implicit constructors being used. This is to make the use of uninitialised properties 'more painful' and to draw attention to the fact that there are sometimes (but not always) better ways. This should cause the EK9 developer to consider alternatives and if they still believe this to be the best solution to consider initialisation inside a Constructor. This is not mandatory, but is very likely to lead to defects, so this is an attempt at making this issue more obvious.
  • Constructor Details

  • Method Details

    • accept

      public void accept(org.antlr.v4.runtime.tree.ParseTree node)
      Specified by:
      accept in interface Consumer<org.antlr.v4.runtime.tree.ParseTree>