Class ReturningParamUseOrError

java.lang.Object
org.ek9lang.compiler.phase3.ReturningParamUseOrError
All Implemented Interfaces:
BiConsumer<org.antlr.v4.runtime.ParserRuleContext, EK9Parser.ReturningParamContext>

final class ReturningParamUseOrError extends Object implements BiConsumer<org.antlr.v4.runtime.ParserRuleContext, EK9Parser.ReturningParamContext>
THE check that a for, while, switch or try is used correctly in or out of an expression: as a statement it must NOT have a returning section (it makes no sense), as an expression it MUST have one.

Called with the construct's context and its (possibly null) returningParam; one instance serves all four.