private boolean validOperationExpression ( Node expr ) { String name = getCallName ( expr ) ; Keywords keyword = nameToKeyword ( name ) ; switch ( keyword ) { case COND : return validConditionalExpression ( expr ) ; case MAPUNION : return validMapunionExpression ( expr ) ; case MAPRECORD : return validMaprecordExpression ( expr ) ; case TYPEOFVAR : return validTypeOfVarExpression ( expr ) ; case INSTANCEOF : return validInstanceOfExpression ( expr ) ; case PRINTTYPE : return validPrintTypeExpression ( expr ) ; case PROPTYPE : return validPropTypeExpression ( expr ) ; default : throw new IllegalStateException ( "Invalid type transformation operation" ) ; } }
An operation expression is a cond or a mapunion