Appearance
Do
When used as a statement, do works just like it does in Lua.
yuescript
do
var = "hello"
print var
print var -- nil hereYueScript's do can also be used an expression . Allowing you to combine multiple lines into one. The result of the do expression is the last statement in its body.
yuescript
counter = do
i = 0
->
i += 1
i
print counter!
print counter!yuescript
tbl = {
key: do
print "assigning key!"
1234
}