aboutsummaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/outputs/codes_from_doc.lua29
-rw-r--r--spec/outputs/codes_from_doc_zh.lua29
2 files changed, 34 insertions, 24 deletions
diff --git a/spec/outputs/codes_from_doc.lua b/spec/outputs/codes_from_doc.lua
index 085179c..f1e46d9 100644
--- a/spec/outputs/codes_from_doc.lua
+++ b/spec/outputs/codes_from_doc.lua
@@ -209,14 +209,16 @@ for _key_0, _value_0 in pairs(b) do
209 end 209 end
210end 210end
211merge = _tab_0 211merge = _tab_0
212print((function() 212local last
213do
213 local _item_0 = data.items 214 local _item_0 = data.items
214 return _item_0[#_item_0] 215 last = _item_0[#_item_0]
215end)()) 216end
216print((function() 217local second_last
218do
217 local _item_0 = data.items 219 local _item_0 = data.items
218 return _item_0[#_item_0 - 1] 220 second_last = _item_0[#_item_0 - 1]
219end)()) 221end
220local mt = { } 222local mt = { }
221local add 223local add
222add = function(self, right) 224add = function(self, right)
@@ -2603,14 +2605,16 @@ for _key_0, _value_0 in pairs(b) do
2603 end 2605 end
2604end 2606end
2605merge = _tab_0 2607merge = _tab_0
2606print((function() 2608local last
2609do
2607 local _item_0 = data.items 2610 local _item_0 = data.items
2608 return _item_0[#_item_0] 2611 last = _item_0[#_item_0]
2609end)()) 2612end
2610print((function() 2613local second_last
2614do
2611 local _item_0 = data.items 2615 local _item_0 = data.items
2612 return _item_0[#_item_0 - 1] 2616 second_last = _item_0[#_item_0 - 1]
2613end)()) 2617end
2614local mt = { } 2618local mt = { }
2615local add 2619local add
2616add = function(self, right) 2620add = function(self, right)
@@ -3207,6 +3211,7 @@ local some_string = "Here is a string\n that has a line break in it."
3207print("I am " .. tostring(math.random() * 100) .. "% sure.") 3211print("I am " .. tostring(math.random() * 100) .. "% sure.")
3208local integer = 1000000 3212local integer = 1000000
3209local hex = 0xEFBBBF 3213local hex = 0xEFBBBF
3214local binary = 19
3210local my_function 3215local my_function
3211my_function = function() end 3216my_function = function() end
3212my_function() 3217my_function()
diff --git a/spec/outputs/codes_from_doc_zh.lua b/spec/outputs/codes_from_doc_zh.lua
index bb9af58..4689232 100644
--- a/spec/outputs/codes_from_doc_zh.lua
+++ b/spec/outputs/codes_from_doc_zh.lua
@@ -209,14 +209,16 @@ for _key_0, _value_0 in pairs(b) do
209 end 209 end
210end 210end
211merge = _tab_0 211merge = _tab_0
212print((function() 212local last
213do
213 local _item_0 = data.items 214 local _item_0 = data.items
214 return _item_0[#_item_0] 215 last = _item_0[#_item_0]
215end)()) 216end
216print((function() 217local second_last
218do
217 local _item_0 = data.items 219 local _item_0 = data.items
218 return _item_0[#_item_0 - 1] 220 second_last = _item_0[#_item_0 - 1]
219end)()) 221end
220local mt = { } 222local mt = { }
221local add 223local add
222add = function(self, right) 224add = function(self, right)
@@ -2597,14 +2599,16 @@ for _key_0, _value_0 in pairs(b) do
2597 end 2599 end
2598end 2600end
2599merge = _tab_0 2601merge = _tab_0
2600print((function() 2602local last
2603do
2601 local _item_0 = data.items 2604 local _item_0 = data.items
2602 return _item_0[#_item_0] 2605 last = _item_0[#_item_0]
2603end)()) 2606end
2604print((function() 2607local second_last
2608do
2605 local _item_0 = data.items 2609 local _item_0 = data.items
2606 return _item_0[#_item_0 - 1] 2610 second_last = _item_0[#_item_0 - 1]
2607end)()) 2611end
2608local mt = { } 2612local mt = { }
2609local add 2613local add
2610add = function(self, right) 2614add = function(self, right)
@@ -3201,6 +3205,7 @@ local some_string = "这是一个字符串\n 并包括一个换行。"
3201print("我有" .. tostring(math.random() * 100) .. "%的把握。") 3205print("我有" .. tostring(math.random() * 100) .. "%的把握。")
3202local integer = 1000000 3206local integer = 1000000
3203local hex = 0xEFBBBF 3207local hex = 0xEFBBBF
3208local binary = 19
3204local my_function 3209local my_function
3205my_function = function() end 3210my_function = function() end
3206my_function() 3211my_function()