KScript 文档
ZH

错误代码

KS2001

某个值的写法不正确。错误信息会说明期望的内容。常见原因包括:行尾带有运算符、括号未闭合,以及在 KScript 需要 and 或 or 的地方使用了 && 或 ||。

<let>$total = 5 +</let> <!-- wrong: nothing after the + -->
<set name="total" value="5 + 1" /> <!-- right -->
$total = 5 +          // wrong: nothing after the +
$total = 5 + 1        // right

Edit this page on GitHub