运算符 ~= 在 Lua 中是什么意思?
What does operator ~= mean in Lua?
~=
运算符在Lua中是什么意思?
例如,在下面的代码中:
if x ~= params then
The operator ~= is exactly the negation of equality (==).
参见docs。
~=
是 not equals
在其他语言中等同于!=
在编译期间它被翻译成 not a == b
。
~=
在 Lua 中就像在 C# 等其他语言中做 !=
。
~=
运算符在Lua中是什么意思?
例如,在下面的代码中:
if x ~= params then
The operator ~= is exactly the negation of equality (==).
参见docs。
~=
是 not equals
在其他语言中等同于!=
在编译期间它被翻译成 not a == b
。
~=
在 Lua 中就像在 C# 等其他语言中做 !=
。