From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <tarantool-patches-bounces@dev.tarantool.org>
Received: from [87.239.111.99] (localhost [127.0.0.1])
	by dev.tarantool.org (Postfix) with ESMTP id 1BFEC6B95A;
	Tue, 13 Apr 2021 16:39:06 +0300 (MSK)
DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 1BFEC6B95A
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev;
	t=1618321146; bh=/19LwbLbSeRTKqEZTCJ0kN1vFwmJJHesVXYEJpBF5XM=;
	h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:
	 List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:
	 From;
	b=xaiRddjNdkQPpj9LNugO+AZmtiIk/mPmHNTAqzFUhpURpDzUvm1YV8SvpDswDQ0yD
	 DzfOHt1ckBLJFMYku51xXR67akR3lAn+hWIkQRiuH8w49QSK8jObBEcpn8dC64nAs8
	 OiUXfdIVOJtbpzkuj/C/7OaaG/XSgKqREsgg1n0o=
Received: from smtp48.i.mail.ru (smtp48.i.mail.ru [94.100.177.108])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (No client certificate requested)
 by dev.tarantool.org (Postfix) with ESMTPS id 850BD6B968
 for <tarantool-patches@dev.tarantool.org>;
 Tue, 13 Apr 2021 16:29:01 +0300 (MSK)
DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 850BD6B968
Received: by smtp48.i.mail.ru with esmtpa (envelope-from
 <skaplun@tarantool.org>)
 id 1lWJ6C-0000dj-O1; Tue, 13 Apr 2021 16:29:01 +0300
To: Sergey Ostanevich <sergos@tarantool.org>, Igor Munkin <imun@tarantool.org>
Date: Tue, 13 Apr 2021 16:27:21 +0300
Message-Id: <6e4594915e09525ded9a73aa5d134993975a1850.1618320000.git.skaplun@tarantool.org>
X-Mailer: git-send-email 2.31.0
In-Reply-To: <cover.1618320000.git.skaplun@tarantool.org>
References: <cover.1618320000.git.skaplun@tarantool.org>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-7564579A: 646B95376F6C166E
X-77F55803: 4F1203BC0FB41BD92FFCB8E6708E7480257C85EA0BB7A95D0F00AE41BB9A5343182A05F5380850403BB6507E6AE199635B24DF8D37E09FE6773AE3F02535FA04CBDFA4F21A755E7B
X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE789805A6418246A1AEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F79006372E9841F416E2DCCD8638F802B75D45FF914D58D5BE9E6BC1A93B80C6DEB9DEE97C6FB206A91F05B28E95D931955B7A97850EC0D7D56408CFC26CFBAC0749D213D2E47CDBA5A96583C09775C1D3CA48CF4964A708C60C975A117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658378DA827A17800CE74A95F4E53E8DCE969FA2833FD35BB23DF004C906525384302BEBFE083D3B9BA73A03B725D353964B0B7D0EA88DDEDAC722CA9DD8327EE4930A3850AC1BE2E7350555CCFDA08FA3FAC4224003CC83647689D4C264860C145E
X-C1DE0DAB: C20DE7B7AB408E4181F030C43753B8186998911F362727C4C7A0BC55FA0FE5FC7F657775A4D63968AC6E28BC2BDA5324AE6FB2A25AFC7D49B1881A6453793CE9C32612AADDFBE061C61BE10805914D3804EBA3D8E7E5B87ABF8C51168CD8EBDB63AF70AF8205D7DCDC48ACC2A39D04F89CDFB48F4795C241BDAD6C7F3747799A
X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34AA8975497C7004E89A5D82D3EBF31DBADF52A0D9F568BB7736479ABCFA68738551B580FB524D74ED1D7E09C32AA3244CE007EBB872C59CBA3406B684C28E2C9633C9DC155518937F927AC6DF5659F194
X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojnA7/qPBUIXEHDCVJdjgEzw==
X-Mailru-Sender: 3B9A0136629DC91206CBC582EFEF4CB4539E65627C94F4080CB0C4669B49AB2CF87EFF7066E81F1FF2400F607609286E924004A7DEC283833C7120B22964430C52B393F8C72A41A89437F6177E88F7363CDA0F3B3F5B9367
X-Mras: Ok
Subject: [Tarantool-patches] [PATCH luajit v3 21/29] test: disable PUC-Rio
 test for variables in error
X-BeenThere: tarantool-patches@dev.tarantool.org
X-Mailman-Version: 2.1.34
Precedence: list
List-Id: Tarantool development patches <tarantool-patches.dev.tarantool.org>
List-Unsubscribe: <https://lists.tarantool.org/mailman/options/tarantool-patches>, 
 <mailto:tarantool-patches-request@dev.tarantool.org?subject=unsubscribe>
List-Archive: <https://lists.tarantool.org/pipermail/tarantool-patches/>
List-Post: <mailto:tarantool-patches@dev.tarantool.org>
List-Help: <mailto:tarantool-patches-request@dev.tarantool.org?subject=help>
List-Subscribe: <https://lists.tarantool.org/mailman/listinfo/tarantool-patches>, 
 <mailto:tarantool-patches-request@dev.tarantool.org?subject=subscribe>
From: Sergey Kaplun via Tarantool-patches <tarantool-patches@dev.tarantool.org>
Reply-To: Sergey Kaplun <skaplun@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org
Errors-To: tarantool-patches-bounces@dev.tarantool.org
Sender: "Tarantool-patches" <tarantool-patches-bounces@dev.tarantool.org>

LuaJIT includes the variable name to the error message, when try to
call non-function object without __call metamethod.
Also, LuaJIT includes the variable name to the error message, when try
to perform unacceptable arithmetic operation with the variable.
Lua 5.1 doesn't report the variable name in these errors.

The test checking, that variable name isn't reported, is disabled by
this patch.

Part of tarantool/tarantool#5845
Part of tarantool/tarantool#4473
---
 test/PUC-Rio-Lua-5.1-tests/errors.lua | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/test/PUC-Rio-Lua-5.1-tests/errors.lua b/test/PUC-Rio-Lua-5.1-tests/errors.lua
index e8812117..c9d79279 100644
--- a/test/PUC-Rio-Lua-5.1-tests/errors.lua
+++ b/test/PUC-Rio-Lua-5.1-tests/errors.lua
@@ -72,8 +72,13 @@ checkmessage("b=1; local aaa='a'; x=aaa+b", "local 'aaa'")
 checkmessage("aaa={}; x=3/aaa", "global 'aaa'")
 checkmessage("aaa='2'; b=nil;x=aaa*b", "global 'b'")
 checkmessage("aaa={}; x=-aaa", "global 'aaa'")
-assert(not string.find(doit"aaa={}; x=(aaa or aaa)+(aaa and aaa)", "'aaa'"))
-assert(not string.find(doit"aaa={}; (aaa or aaa)()", "'aaa'"))
+-- LuaJIT: LuaJIT includes variable name to the error message.
+-- It looks like:
+-- "attempt to perform arithmetic on global 'aaa' (a table value)"
+-- Lua 5.1 doesn't report the variable name here.
+-- Tests are disabled for LuaJIT.
+-- assert(not string.find(doit"aaa={}; x=(aaa or aaa)+(aaa and aaa)", "'aaa'"))
+-- assert(not string.find(doit"aaa={}; (aaa or aaa)()", "'aaa'"))
 
 checkmessage([[aaa=9
 repeat until 3==3
-- 
2.31.0