Replies: 2 comments 1 reply
-
单独写mut允许对绑定有更精细的可变性控制。MoonBit未来会有类似的东西:
这样一来let的语法是 更多的例子:
|
Beta Was this translation helpful? Give feedback.
0 replies
-
所以不用 var 是要考虑以后结构语法里面有 mut 的语义一致性吗? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
`
//定义可变变量
let a = 100
//定义可变变量
mut b = 200
`
Beta Was this translation helpful? Give feedback.
All reactions