aboutsummaryrefslogtreecommitdiff
path: root/testes/attrib.lua
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2022-12-21 12:04:59 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2022-12-21 12:04:59 -0300
commitb2f7b3b79f3117885b265575f6c5dbf934757797 (patch)
treead7ac30fb9a05e1e6635110f03c45b9cd41190c8 /testes/attrib.lua
parent540d8052265776451bb9f0ab4dee4ec860563cbe (diff)
downloadlua-b2f7b3b79f3117885b265575f6c5dbf934757797.tar.gz
lua-b2f7b3b79f3117885b265575f6c5dbf934757797.tar.bz2
lua-b2f7b3b79f3117885b265575f6c5dbf934757797.zip
Control variables in for loops are read only
Diffstat (limited to 'testes/attrib.lua')
-rw-r--r--testes/attrib.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/testes/attrib.lua b/testes/attrib.lua
index 83821c06..fc427080 100644
--- a/testes/attrib.lua
+++ b/testes/attrib.lua
@@ -236,7 +236,7 @@ package.path = oldpath
236local fname = "file_does_not_exist2" 236local fname = "file_does_not_exist2"
237local m, err = pcall(require, fname) 237local m, err = pcall(require, fname)
238for t in string.gmatch(package.path..";"..package.cpath, "[^;]+") do 238for t in string.gmatch(package.path..";"..package.cpath, "[^;]+") do
239 t = string.gsub(t, "?", fname) 239 local t = string.gsub(t, "?", fname)
240 assert(string.find(err, t, 1, true)) 240 assert(string.find(err, t, 1, true))
241end 241end
242 242