diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-05-09 12:10:31 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2019-05-09 12:10:31 -0300 |
commit | d881325c2fcbb6d2c434ec403b0bbe51ac200c7b (patch) | |
tree | 811c1a1ffa8f91693b8df64e040c509c2cec6ded /testes/api.lua | |
parent | 3f253f116e8e292977a1bded964544fb35b3d1e3 (diff) | |
download | lua-d881325c2fcbb6d2c434ec403b0bbe51ac200c7b.tar.gz lua-d881325c2fcbb6d2c434ec403b0bbe51ac200c7b.tar.bz2 lua-d881325c2fcbb6d2c434ec403b0bbe51ac200c7b.zip |
Flag for to-be-closed variables changed to '<toclose>'
The flag for to-be-closed variables was changed from '*toclose'
to '<toclose>'. Several people found confusing the old syntax and
the new one has a clear terminator, making it more flexible for
future changes.
Diffstat (limited to 'testes/api.lua')
-rw-r--r-- | testes/api.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/testes/api.lua b/testes/api.lua index 08672e8a..bcc04dac 100644 --- a/testes/api.lua +++ b/testes/api.lua | |||
@@ -1137,7 +1137,8 @@ end) | |||
1137 | testamem("to-be-closed variables", function() | 1137 | testamem("to-be-closed variables", function() |
1138 | local flag | 1138 | local flag |
1139 | do | 1139 | do |
1140 | local *toclose x = setmetatable({}, {__close = function () flag = true end}) | 1140 | local <toclose> x = |
1141 | setmetatable({}, {__close = function () flag = true end}) | ||
1141 | flag = false | 1142 | flag = false |
1142 | local x = {} | 1143 | local x = {} |
1143 | end | 1144 | end |