aboutsummaryrefslogtreecommitdiff
path: root/testes/db.lua
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2024-11-19 14:09:18 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2024-11-19 14:09:18 -0300
commit50c7c915ee2fa239043d5456237f5145d064089b (patch)
tree386e17e4baa154bb60dc54c1a00c751e3adedde9 /testes/db.lua
parentb117bdb3448778d9e7f9a0302791e8ac3bb97ddd (diff)
downloadlua-50c7c915ee2fa239043d5456237f5145d064089b.tar.gz
lua-50c7c915ee2fa239043d5456237f5145d064089b.tar.bz2
lua-50c7c915ee2fa239043d5456237f5145d064089b.zip
Debug information about extra arguments from __call
'debug.getinfo' can return number of extra arguments added to a call by a chain of __call metavalues. That information is being used to improve error messages about errors in these extra arguments.
Diffstat (limited to 'testes/db.lua')
-rw-r--r--testes/db.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/testes/db.lua b/testes/db.lua
index 49ff8e3e..fc0db9ea 100644
--- a/testes/db.lua
+++ b/testes/db.lua
@@ -624,6 +624,9 @@ local function f (x)
624 end 624 end
625end 625end
626 626
627assert(debug.getinfo(print, 't').istailcall == false)
628assert(debug.getinfo(print, 't').extraargs == 0)
629
627function g(x) return f(x) end 630function g(x) return f(x) end
628 631
629function g1(x) g(x) end 632function g1(x) g(x) end