Issue 6882: There is no simple way to invoke an "if then else" on a collection (ocl2-rtf) Source: France Telecom R&D (Mr. Mariano Belaunde, mariano.belaunde(at)orange.com) Nature: Uncategorized Issue Severity: Summary: Suggestion: Define an "alt" collection function, with a specific notation, as in: mylist->alt(iterator | condition? thenExp, elseExp) The expression elseExp is not evaluated if condition returns true Resolution: It is not true that there is no way: mylist->collect(iterator | if condition then thenExp else elseExp endif) which has two more tokens than the suggestion but avoids introducing a "?" syntax irregularity. Disposition: Closed, no change Revised Text: Actions taken: January 7, 2004: received issue December 23, 2013: closed issue Discussion: This is a request to improve the language. Better solved in a RTF. End of Annotations:===== SSUE: There is no simple way to invoke an "if then else" on a collection. Suggestion: Define an "alt" collection function, with a specific notation, as in: mylist->alt(iterator | condition? thenExp, elseExp) The expression elseExp is not evaluated if condition returns true :wq