Class RegisteredConstructionOrError

All Implemented Interfaces:
Predicate<EK9Parser.RegisterStatementContext>

final class RegisteredConstructionOrError extends TypedSymbolAccess implements Predicate<EK9Parser.RegisterStatementContext>
THE check of what a 'register' statement registers (decision 10, 2026-10-07). The application CONSTRUCTS each registered value in its '_prepare', so:
  • the registered expression is a constructor call - never a function, method, delegate or any other expression (E08271); a factory may reach an injection not registered yet and IR generation constructs it;
  • with 'as', the constructed type is a COMPONENT (E50020) assignable to the 'as' type (E50030) - phase 2 has already checked the 'as' type is a component;
  • without 'as', the constructed type is a SERVICE (E50020);
  • each aspect in 'with aspect of' is a constructor call (E08271) of an Aspect (E50030).
A call that did not resolve, or that is already in error (such as 'register this()'), is left to its own error. The test is true when the registration is valid, so its data can be recorded on the application.