Opened 15 years ago
Closed 15 years ago
#283 closed enhancement (fixed)
Default branch for conditional expressions
Reported by: | kilian | Owned by: | kilian |
---|---|---|---|
Priority: | P4 | Milestone: | v2.0.1 |
Component: | core | Version: | 2.0.0rc3 |
Severity: | minor | Keywords: | |
Cc: |
Description
In conditional expressions such as
foo = if (a > b) then 1 else 2 endif
the else-branch is mandatory, of course. However, if we make it optional, it is less clumsy to define conditional analysis such as
analysis = if (...) then record (foo, value) endif and ...
The optional branch should default to 0 for numerics, "" for strings, and true (!) for logicals.
Note: See
TracTickets for help on using
tickets.
Wit r2335, optional else as well as alsif have been implemented for conditional expression.