ascot diagnostics

A7139

Error: Only $CASE’s last argument may omit the value before its colon

$CASE takes its :default as the last argument only; an arm after it is a syntax error IRIS refuses to compile. Move the :default to the end.

IRIS rejects the example.

Class Demo.CaseDefaultNotLast
{

ClassMethod Name(code As %Integer) As %String
{
    Quit $CASE(code, 1:"one", :"many", 2:"two") //! A7139
}

}

All diagnostics