mirror of
https://github.com/KevinMidboe/linguist.git
synced 2026-01-08 18:35:32 +00:00
samples: add Terra samples
source: https://github.com/zdevito/terra/tree/master/tests
This commit is contained in:
21
samples/Terra/antiquote5.t
Normal file
21
samples/Terra/antiquote5.t
Normal file
@@ -0,0 +1,21 @@
|
||||
|
||||
|
||||
function makeloop(N,body)
|
||||
return quote
|
||||
for i = 0, N do
|
||||
body
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
terra stuff()
|
||||
var a = 0;
|
||||
[makeloop(10,quote
|
||||
a = a + 1
|
||||
end)]
|
||||
return a
|
||||
end
|
||||
|
||||
|
||||
print(stuff())
|
||||
Reference in New Issue
Block a user