Discarding the result of an operator
The complete source of operators_discarded_bad.ek9, which fails to compile exactly as captioned. Shown on operators.html.
Fails with E11050: operator returns a value but result is discarded - assign to variable or use in expression
#!ek9 defines module bad.site.operators.discarded defines function discardedAddition() price <- 100 tax <- 20 //BAD: Computation result goes nowhere - dead code (E11050) price.+(tax)
Download operators_discarded_bad.ek9 - it fails to compile on purpose, with the error its @Error line states.