4,501
edits
m (Errors category) |
m (Text replacement - "</source>" to "</syntaxhighlight>") Tags: Mobile edit Mobile web edit |
||
Line 10: | Line 10: | ||
'Hello world | 'Hello world | ||
∧ | ∧ | ||
</ | </syntaxhighlight> | ||
However, a SYNTAX ERROR may also indicate a problem not with the sequence of tokens in a statement, but with their meaning. For example, below an error results when a [[function]] is called with invalid [[valence]]: here, a [[monadic function]] with two arguments. | However, a SYNTAX ERROR may also indicate a problem not with the sequence of tokens in a statement, but with their meaning. For example, below an error results when a [[function]] is called with invalid [[valence]]: here, a [[monadic function]] with two arguments. | ||
<source lang=apl> | <source lang=apl> | ||
Line 21: | Line 21: | ||
2 fn 3 | 2 fn 3 | ||
∧ | ∧ | ||
</ | </syntaxhighlight> | ||
Depending on the value of <source lang=apl inline>fn</ | Depending on the value of <source lang=apl inline>fn</syntaxhighlight>, the same statement may or may not be considered invalid syntax. This is to be expected, since APL does not have a [[wikipedia:context-free grammar|context-free grammar]] and needs to know the type of each variable to parse a statement. | ||
{{APL features}}[[Category:Errors]] | {{APL features}}[[Category:Errors]] |