From 314745ed8438d1276c6c928d5f9d4be018dfadb6 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Wed, 28 Dec 2022 18:34:11 -0300 Subject: Avoid excessive name pollution in test files Test files are more polite regarding the use of globals when locals would do, and when globals are necessary deleting them after use. --- testes/events.lua | 3 +++ 1 file changed, 3 insertions(+) (limited to 'testes/events.lua') diff --git a/testes/events.lua b/testes/events.lua index 17a73664..8d8563b9 100644 --- a/testes/events.lua +++ b/testes/events.lua @@ -420,6 +420,9 @@ assert(i == 3 and x[1] == 3 and x[3] == 5) assert(_G.X == 20) +_G.X, _G.B = nil + + print'+' local _g = _G -- cgit v1.2.3-55-g6feb