aboutsummaryrefslogtreecommitdiff
path: root/spec/inputs/export.mp
diff options
context:
space:
mode:
Diffstat (limited to 'spec/inputs/export.mp')
-rw-r--r--spec/inputs/export.mp76
1 files changed, 76 insertions, 0 deletions
diff --git a/spec/inputs/export.mp b/spec/inputs/export.mp
new file mode 100644
index 0000000..9a494d9
--- /dev/null
+++ b/spec/inputs/export.mp
@@ -0,0 +1,76 @@
1
2export a,b,c = 223, 343, 123
3export cool = "dad"
4
5d,e,f = 3, 2, 1
6export d, e, f
7
8export class Something
9 umm: "cool"
10
11export if this
12 232
13else
14 4343
15
16export What = if this
17 232
18else
19 4343
20
21export y = ->
22 hallo = 3434
23
24export with tmp
25 j = 2000
26
27export cbVal = do
28 h = 100
29 (x)<- f
30 return x h
31
32export y = ->
33 h = 100
34 k = 100
35
36export switch h
37 when 100, 150 then 200
38 when 200 then 300
39 else 0
40
41export Constant = switch value
42 when "good" then 1
43 when "better" then 2
44 when "best" then 3
45
46export x
47
48f if a then b
49f do 123
50f switch a
51 when b then c
52f [i for i = 1,10]
53f for i = 1,10 do i
54f {k,v for k,v in pairs tb}
55f for k,v in pairs tb do k,v
56f while a do true
57f with a
58 .b = 123
59f a?.b
60f a\b
61f class A
62
63_ = "#{if a then b}"
64_ = "#{do 123}"
65_ = "#{switch a
66 when b then c}"
67_ = "#{[i for i = 1,10]}"
68_ = "#{for i = 1,10 do i}"
69_ = "#{{k,v for k,v in pairs tb}}"
70_ = "#{for k,v in pairs tb do k,v}"
71_ = "#{while a do true}"
72_ = "#{with a
73 .b = 123}"
74_ = "#{a?.b}"
75_ = "#{a\b}"
76_ = "#{class A}"