Skip to content

Commit ae8e078

Browse files
committed
spec/in/{class,functions}: Add compilation checks for new features
1 parent 69dd2aa commit ae8e078

File tree

4 files changed

+9
-1
lines changed

4 files changed

+9
-1
lines changed

spec/in/class.fuse

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,11 @@ class Example {
77
@a = a;
88
print()=>
99
print(@a);
10-
async test()=>
10+
async test()=> {
11+
@print();
1112
for (i in 1::10)
1213
yield i;
14+
}
1315
}
1416

1517
a = Example();

spec/in/functions.fuse

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ a_3()-> {
3333
return b;
3434
}
3535

36+
local a_4()-> b
37+
3638
-- asynchronous function definitions
3739

3840
async x()->

spec/out/source/class.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ Example = class({
1111
end);
1212
test = (function(self)
1313
return coroutine.wrap(function()
14+
self:print()
1415
for i in itr.range(1, 10) do
1516
coroutine.yield(i)
1617
end

spec/out/source/functions.lua

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ end
2424
function a_3()
2525
return b
2626
end
27+
local function a_4()
28+
return b
29+
end
2730
function x()
2831
return coroutine.wrap(function()
2932
coroutine.yield(a,b,c)

0 commit comments

Comments
 (0)