From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 522E76EC60; Thu, 1 Apr 2021 02:00:04 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 522E76EC60 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1617231604; bh=/xguWU0qGBRMr0tTOJgczEsdwD5q5E3m6FoWypZxk0E=; h=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=zTnIdJPvRiLSe3QCIrnfZV/KIzKe4txVA2bFnds3HlAOJv+MUr9lmDLgTXlw9lHGY eWbaBKCbowKBO0kISRSDq19j6EFJXlbNtUdT3unokyCYxXO+xVQDa24xyz0zS3Xa+t PrJhs3sxhRuSDUAQe8HFmywA+GWsfyqsfxiAlrVM= Received: from smtpng1.m.smailru.net (smtpng1.m.smailru.net [94.100.181.251]) (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 BBF8D7030D for ; Thu, 1 Apr 2021 01:58:57 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org BBF8D7030D Received: by smtpng1.m.smailru.net with esmtpa (envelope-from ) id 1lRjnc-0008NC-Rt; Thu, 01 Apr 2021 01:58:57 +0300 Date: Thu, 1 Apr 2021 01:58:47 +0300 To: Sergey Kaplun Message-ID: <20210331225847.GW29703@tarantool.org> References: <4a8669339a59964c0b187263f864692946d51303.1616743343.git.skaplun@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <4a8669339a59964c0b187263f864692946d51303.1616743343.git.skaplun@tarantool.org> X-Clacks-Overhead: GNU Terry Pratchett User-Agent: Mutt/1.10.1 (2018-07-13) X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD9ED7173E37F4E32947A0146560F8BA709498CFB6209D8582A182A05F5380850409324BF080481F71491FA327932F180EE2D658E22BF77E8B41E9B5FD171A86D1B X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE712EB008F780777E9EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637EF59B520676799BC8638F802B75D45FF914D58D5BE9E6BC131B5C99E7648C95CE99938B3FD79E1DFDD1E43568F66F514FD3DAF5E3F8E5987A471835C12D1D9774AD6D5ED66289B5278DA827A17800CE77A825AB47F0FC8649FA2833FD35BB23D2EF20D2F80756B5F868A13BD56FB6657A471835C12D1D977725E5C173C3A84C327ED053E960B195E117882F4460429728AD0CFFFB425014E868A13BD56FB6657E2021AF6380DFAD1A18204E546F3947C0B7D0EA88DDEDAC722CA9DD8327EE4930A3850AC1BE2E735B58781B77DE60D36C4224003CC83647689D4C264860C145E X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2AD77751E876CB595E8F7B195E1C97831D2B5125A4351B82095489C0DEC852D72 X-C1DE0DAB: 0D63561A33F958A59E7895F32447D811E7EC764AF3654C2A10DCEAD82DAD07E8D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA7502E6951B79FF9A3F410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D346AD04FDA812EEFF135546E4EC5D8B7AFA992432056153D42EA7F87790CA582A5F2659B7890A8825A1D7E09C32AA3244C64B62E01E21F28625B1CF4AE8982C221BBA718C7E6A9E042927AC6DF5659F194 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojetunDCtJ20KHLTJB5HPiuA== X-Mailru-Sender: 689FA8AB762F73936BC43F508A0638225B692A2113B727E24014A760F9E37717A7C8D0F45F857DBFE9F1EFEE2F478337FB559BB5D741EB964C8C2C849690F8E70A04DAD6CC59E33667EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v2 luajit 05/30] test: adapt arg availability test from Lua suite X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Igor Munkin via Tarantool-patches Reply-To: Igor Munkin Cc: tarantool-patches@dev.tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Sergey, Thanks for the patch! Please consider the comments below. On 26.03.21, Sergey Kaplun wrote: > The argument table `arg` can be read (and modified) by `LUA_INIT` and > `-e` chunks since the commit 92d9ff211ae864777a8580b5a7326d5f408161ce > (Set arg table before evaluating LUA_INIT and -e chunks.). > > This behaviour is similar to Lua 5.3, so the test was adapted > considering PUC-Rio Lua 5.3 test suite taken from > https://www.lua.org/tests/lua-5.3.0-tests.tar.gz. > > Closes tarantool/tarantool#5686 As we discussed before: s/Closes/Resolves/. > Part of tarantool/tarantool#5845 > Part of tarantool/tarantool#4473 > --- > test/PUC-Lua-5.1-tests/main.lua | 14 ++++++++++++-- > 1 file changed, 12 insertions(+), 2 deletions(-) > > diff --git a/test/PUC-Lua-5.1-tests/main.lua b/test/PUC-Lua-5.1-tests/main.lua > index 4f8b8bf..c11a576 100644 > --- a/test/PUC-Lua-5.1-tests/main.lua > +++ b/test/PUC-Lua-5.1-tests/main.lua > @@ -69,9 +69,19 @@ a = string.format(a, progname) > prepfile(a) > RUN('lua "-e " -- %s a b c', prog) > > -prepfile"assert(arg==nil)" > +-- test 'arg' availability in libraries > +-- LuaJIT: LuaJIT v2.1.0-beta3 has extension from Lua 5.3: > +-- The argument table `arg` can be read (and modified) > +-- by `LUA_INIT` and `-e` chunks. > +-- See commit 92d9ff211ae864777a8580b5a7326d5f408161ce > +-- (Set arg table before evaluating LUA_INIT and -e chunks.). > +-- See also https://github.com/tarantool/tarantool/issues/5686. > +-- In Lua 5.3 this feature was introduced via commit > +-- 23f0ff95177eda2e0a80e3a48562cc6837705735. > +-- Test is adapted from PUC-Rio Lua 5.3 test suite. > +prepfile"assert(arg)" > prepfile("assert(arg)", otherprog) > -RUN("lua -l%s - < %s", prog, otherprog) > +RUN('env LUA_PATH="?;;" lua -l%s - < %s', prog, otherprog) Why LUA_PATH is tweaked here? > > prepfile"" > RUN("lua - < %s > %s", prog, out) > -- > 2.31.0 > -- Best regards, IM