mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 04:57:00 -04:00
Allow "or else" construct to be used for error recovery
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@1016 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -20,6 +20,10 @@ Otherwise it is converted to a [[type:double]].
|
||||
> to_number("1") == 1
|
||||
> to_number("1.5") == 1.5
|
||||
|
||||
Use @or else@ to recover from errors:
|
||||
> to_number("not a number") or else 0 == 0
|
||||
> to_number("123") or else 0 == 123
|
||||
|
||||
--See also--
|
||||
| [[fun:to_int]] Convert any value to a [[type:int]]
|
||||
| [[fun:to_real]] Convert any value to a [[type:double]]
|
||||
|
||||
Reference in New Issue
Block a user