Difference between revisions of "Template:LSL Function/negative index"
Jump to navigation
Jump to search
m |
|||
Line 51: | Line 51: | ||
{{#switch:{{#var:ni_c}} | {{#switch:{{#var:ni_c}} | ||
|0=This function | |0=This function | ||
|1='''{{{2}}}''' | |1='''{{LSL Param|{{{2}}}}}''' | ||
|2='''{{{2}}}''' & '''{{{3}}}''' | |2='''{{LSL Param|{{{2}}}}}''' & '''{{LSL Param|{{{3}}}}}''' | ||
|3='''{{{2}}}''', '''{{{3}}}''' & '''{{{4}}}''' | |3='''{{LSL Param|{{{2}}}}}''', '''{{LSL Param|{{{3}}}}}''' & '''{{LSL Param|{{{4}}}}}''' | ||
}} {{#if:{{#var:t}}| support{{#ifexpr:{{#var:ni_c}}>1||s}}| ''do{{#ifexpr:{{#var:ni_c}}>1||es}} not'' support }} {{LSLGC|Negative_Index{{#var:lang}}|negative indexes}}.{{PBR}} | }} {{#if:{{#var:t}}| support{{#ifexpr:{{#var:ni_c}}>1||s}}| ''do{{#ifexpr:{{#var:ni_c}}>1||es}} not'' support }} {{LSLGC|Negative_Index{{#var:lang}}|negative indexes}}.{{PBR}} | ||
}} | }} | ||
Line 63: | Line 63: | ||
{{#if:{{{nc|{{#var:ni_nc}}}}}|| | {{#if:{{{nc|{{#var:ni_nc}}}}}|| | ||
* If {{#switch:{{#var:ni_c}} | * If {{#switch:{{#var:ni_c}} | ||
|3=either '''{{{2}}}''', '''{{{3}}}''' or '''{{{4}}}''' are | |3=either '''{{LSL Param|{{{2}}}}}''', '''{{LSL Param|{{{3}}}}}''' or '''{{LSL Param|{{{4}}}}}''' are | ||
|2=either '''{{{2}}}''' or '''{{{3}}}''' are | |2=either '''{{LSL Param|{{{2}}}}}''' or '''{{LSL Param|{{{3}}}}}''' are | ||
|1='''{{{2}}}''' is}} out of bounds the script continues to execute without an error message{{#if:{{{returns|}}}| {{{returns|}}}|.}} | |1='''{{LSL Param|{{{2}}}}}''' is}} out of bounds the script continues to execute without an error message{{#if:{{{returns|}}}| {{{returns|}}}|.}} | ||
}}}} | }}}} | ||
Revision as of 12:30, 9 April 2010
Format:
{{LSL Function/negative index|boolean|p1|p2|p3}}
Exclude p1, p2, or p3 if not used.
Debugging
#var | value | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
header_footnote |
{{{2}}} supports negative indexes. | ||||||||||
spec |
Indexes
| ||||||||||
caveats |
| ||||||||||
notes | |||||||||||
constants_nb | |||||||||||
also_articles |
| ||||||||||
footer |