# -*- coding: utf-8 -*-
TITLE: min static-call only if. (no body)
IN:
world!
Hello
PARAM[
- 1
]
OUT:
world!
PARAM[
- 2
]
OUT:
Hello
world!
TITLE: min static-call only if. (with body)
IN:
world!
Hello
&yatt:body();
PARAM[
- 1
]
OUT:
PARAM[
- 2
]
OUT:
Hello
world!
TITLE: min static-call if else
IN:
world!<:yatt:else/>
s!
pace
Hello
&yatt:body();
BREAK: 1
PARAM[
- 1
]
OUT:
Hello
space!
PARAM[
- 2
]
OUT:
Hello
world!
TITLE: min static-call if elsif else
IN:
world!<:yatt:else if="&yatt:x; < 0"/>
Zearth!<:yatt:else/>
space!
Hello
&yatt:body();
PARAM[
- 1
]
OUT:
Hello
space!
PARAM[
- -1
]
OUT:
Hello
Zearth!
PARAM[
- 2
]
OUT:
Hello
world!
TITLE: dynamic-call if elsif else
IN:
<:yatt:world/>
Hello
&yatt:body();
world!<:yatt:else if="&yatt:x; < 0"/>
Zearth!<:yatt:else/>
space!
PARAM[
- 1
]
OUT:
Hello
space!
PARAM[
- -1
]
OUT:
Hello
Zearth!
PARAM[
- 2
]
OUT:
Hello
world!
TITLE: codevar in if else
IN:
&yatt:value; is under limit &yatt:limit;
<:yatt:else if=&yatt:cond();/>
cond is ok
<:yatt:else/>
otherwise
PARAM[
- 10
- 3
- 3
- 5
]
OUT:
8 is under limit 10
PARAM[
- 10
- 3
- 4
- 8
]
OUT:
cond is ok
PARAM[
- 10
- 3
- 3
- 8
]
OUT:
otherwise