aboutsummaryrefslogtreecommitdiff
path: root/spec/outputs/codes_from_doc.lua
diff options
context:
space:
mode:
Diffstat (limited to 'spec/outputs/codes_from_doc.lua')
-rw-r--r--spec/outputs/codes_from_doc.lua26
1 files changed, 26 insertions, 0 deletions
diff --git a/spec/outputs/codes_from_doc.lua b/spec/outputs/codes_from_doc.lua
index f1e46d9..b7d1236 100644
--- a/spec/outputs/codes_from_doc.lua
+++ b/spec/outputs/codes_from_doc.lua
@@ -109,6 +109,12 @@ end
109print("yuescript") 109print("yuescript")
110print(3) 110print(3)
111print("Valid enum type:", "Static") 111print("Valid enum type:", "Static")
112do
113 print(123, "hello")
114end
115do
116 print(123, "hello")
117end
112if tb ~= nil then 118if tb ~= nil then
113 tb:func() 119 tb:func()
114end 120end
@@ -816,6 +822,13 @@ print("I am " .. tostring(math.random() * 100) .. "% sure.")
816local integer = 1000000 822local integer = 1000000
817local hex = 0xEFBBBF 823local hex = 0xEFBBBF
818local binary = 19 824local binary = 19
825local str = "key: value\nlist:\n - item1\n - " .. tostring(expr)
826local fn
827fn = function()
828 local str = "foo:\n bar: baz"
829 return str
830end
831local str = "path: \"C:\\Program Files\\App\"\nnote: 'He said: \"" .. tostring(Hello) .. "!\"'"
819local my_function 832local my_function
820my_function = function() end 833my_function = function() end
821my_function() 834my_function()
@@ -2505,6 +2518,12 @@ end
2505print("yuescript") 2518print("yuescript")
2506print(3) 2519print(3)
2507print("Valid enum type:", "Static") 2520print("Valid enum type:", "Static")
2521do
2522 print(123, "hello")
2523end
2524do
2525 print(123, "hello")
2526end
2508if tb ~= nil then 2527if tb ~= nil then
2509 tb:func() 2528 tb:func()
2510end 2529end
@@ -3212,6 +3231,13 @@ print("I am " .. tostring(math.random() * 100) .. "% sure.")
3212local integer = 1000000 3231local integer = 1000000
3213local hex = 0xEFBBBF 3232local hex = 0xEFBBBF
3214local binary = 19 3233local binary = 19
3234local str = "key: value\nlist:\n - item1\n - " .. tostring(expr)
3235local fn
3236fn = function()
3237 local str = "foo:\n bar: baz"
3238 return str
3239end
3240local str = "path: \"C:\\Program Files\\App\"\nnote: 'He said: \"" .. tostring(Hello) .. "!\"'"
3215local my_function 3241local my_function
3216my_function = function() end 3242my_function = function() end
3217my_function() 3243my_function()