New failing test case involving do/end blocks and upvalues.
This commit is contained in:
@@ -163,6 +163,11 @@ public class LuaJTest extends TestCase {
|
||||
public void testUpvalues2() throws IOException, InterruptedException {
|
||||
runTest( "upvalues2" );
|
||||
}
|
||||
|
||||
public void testUpvalues3() throws IOException, InterruptedException {
|
||||
runTest( "upvalues3" );
|
||||
}
|
||||
|
||||
//*/
|
||||
private void runTest( String testName ) throws IOException, InterruptedException {
|
||||
|
||||
|
||||
14
src/test/res/upvalues3.lua
Normal file
14
src/test/res/upvalues3.lua
Normal file
@@ -0,0 +1,14 @@
|
||||
local f
|
||||
|
||||
do
|
||||
local x = 10
|
||||
function g()
|
||||
print(x, f())
|
||||
end
|
||||
end
|
||||
|
||||
function f()
|
||||
return 20
|
||||
end
|
||||
|
||||
g()
|
||||
Reference in New Issue
Block a user