diff options
Diffstat (limited to 'spec/outputs/unicode/nil_coalescing.lua')
-rw-r--r-- | spec/outputs/unicode/nil_coalescing.lua | 182 |
1 files changed, 182 insertions, 0 deletions
diff --git a/spec/outputs/unicode/nil_coalescing.lua b/spec/outputs/unicode/nil_coalescing.lua new file mode 100644 index 0000000..90fd097 --- /dev/null +++ b/spec/outputs/unicode/nil_coalescing.lua | |||
@@ -0,0 +1,182 @@ | |||
1 | do | ||
2 | local _u53d8_u91cfa | ||
3 | do | ||
4 | local _exp_0 = _u53d8_u91cfb | ||
5 | if _exp_0 ~= nil then | ||
6 | _u53d8_u91cfa = _exp_0 | ||
7 | else | ||
8 | _u53d8_u91cfa = _u53d8_u91cfc | ||
9 | end | ||
10 | end | ||
11 | end | ||
12 | do | ||
13 | local _u5b57_u6bb5a | ||
14 | do | ||
15 | local _exp_0 = _u53d8_u91cfb | ||
16 | if _exp_0 ~= nil then | ||
17 | _u5b57_u6bb5a = _exp_0["字段a"] | ||
18 | else | ||
19 | _u5b57_u6bb5a = _u53d8_u91cfc["字段a"] | ||
20 | end | ||
21 | end | ||
22 | end | ||
23 | do | ||
24 | local _u53d8_u91cfa = _u51fd_u6570() | ||
25 | if _u53d8_u91cfa == nil then | ||
26 | _u53d8_u91cfa = false | ||
27 | end | ||
28 | end | ||
29 | do | ||
30 | local _u53d8_u91cfa | ||
31 | if _u53d8_u91cfa == nil then | ||
32 | _u53d8_u91cfa = _u51fd_u6570() | ||
33 | end | ||
34 | end | ||
35 | do | ||
36 | local _u53d8_u91cfa, _u53d8_u91cfb, _u53d8_u91cfc, _u53d8_u91cfd, _u53d8_u91cfe | ||
37 | if _u53d8_u91cfb ~= nil then | ||
38 | _u53d8_u91cfa = _u53d8_u91cfb | ||
39 | else | ||
40 | if _u53d8_u91cfc ~= nil then | ||
41 | _u53d8_u91cfa = _u53d8_u91cfc | ||
42 | else | ||
43 | if _u53d8_u91cfd ~= nil then | ||
44 | _u53d8_u91cfa = _u53d8_u91cfd | ||
45 | else | ||
46 | _u53d8_u91cfa = _u53d8_u91cfe | ||
47 | end | ||
48 | end | ||
49 | end | ||
50 | end | ||
51 | do | ||
52 | local _u53d8_u91cfa | ||
53 | do | ||
54 | local _exp_0 = _u53d8_u91cfb | ||
55 | if _exp_0 ~= nil then | ||
56 | _u53d8_u91cfa = _exp_0 | ||
57 | else | ||
58 | do | ||
59 | local _exp_1 = _u53d8_u91cfc | ||
60 | if _exp_1 ~= nil then | ||
61 | _u53d8_u91cfa = _exp_1 | ||
62 | else | ||
63 | do | ||
64 | local _exp_2 = _u53d8_u91cfd | ||
65 | if _exp_2 ~= nil then | ||
66 | _u53d8_u91cfa = _exp_2 | ||
67 | else | ||
68 | _u53d8_u91cfa = _u53d8_u91cfe | ||
69 | end | ||
70 | end | ||
71 | end | ||
72 | end | ||
73 | end | ||
74 | end | ||
75 | end | ||
76 | do | ||
77 | _u51fd_u6570((function() | ||
78 | local _exp_0 = _u53d8_u91cfx | ||
79 | if _exp_0 ~= nil then | ||
80 | return _exp_0 | ||
81 | else | ||
82 | return "你好" | ||
83 | end | ||
84 | end)()) | ||
85 | end | ||
86 | do | ||
87 | do | ||
88 | local _with_0 | ||
89 | do | ||
90 | local _exp_0 = _u51fd_u6570A() | ||
91 | if _exp_0 ~= nil then | ||
92 | _with_0 = _exp_0 | ||
93 | else | ||
94 | _with_0 = _u51fd_u6570B() | ||
95 | end | ||
96 | end | ||
97 | _u6253_u5370(_with_0["字段"]) | ||
98 | end | ||
99 | end | ||
100 | do | ||
101 | local _u53d8_u91cfa = 1 + 2 + (function() | ||
102 | local _exp_0 = _u53d8_u91cfb | ||
103 | if _exp_0 ~= nil then | ||
104 | return _exp_0 | ||
105 | else | ||
106 | return _u53d8_u91cfc + 3 + 4 | ||
107 | end | ||
108 | end)() | ||
109 | end | ||
110 | do | ||
111 | local _u53d8_u91cfa = 1 + 2 + ((function() | ||
112 | local _exp_0 = _u53d8_u91cfb | ||
113 | if _exp_0 ~= nil then | ||
114 | return _exp_0 | ||
115 | else | ||
116 | return _u53d8_u91cfc | ||
117 | end | ||
118 | end)()) + 3 + 4 | ||
119 | end | ||
120 | do | ||
121 | local _u5b57_u6bb5a, _u5b57_u6bb5b | ||
122 | do | ||
123 | local _obj_0 = _u51fd_u6570() | ||
124 | _u5b57_u6bb5a, _u5b57_u6bb5b = _obj_0["字段a"], _obj_0["字段b"] | ||
125 | end | ||
126 | local _u53d8_u91cfa = _u53d8_u91cfa or 1 | ||
127 | local _u53d8_u91cfb | ||
128 | if _u53d8_u91cfb == nil then | ||
129 | do | ||
130 | local _exp_0 = _u53d8_u91cfc | ||
131 | if _exp_0 ~= nil then | ||
132 | _u53d8_u91cfb = _exp_0 | ||
133 | else | ||
134 | _u53d8_u91cfb = 2 | ||
135 | end | ||
136 | end | ||
137 | end | ||
138 | end | ||
139 | do | ||
140 | local _u53d8_u91cfa | ||
141 | do | ||
142 | local _exp_0 = 1 | ||
143 | if _exp_0 ~= nil then | ||
144 | _u53d8_u91cfa = _exp_0 | ||
145 | else | ||
146 | do | ||
147 | local _exp_1 = 2 | ||
148 | if _exp_1 ~= nil then | ||
149 | _u53d8_u91cfa = _exp_1 | ||
150 | else | ||
151 | _u53d8_u91cfa = 3 | ||
152 | end | ||
153 | end | ||
154 | end | ||
155 | end | ||
156 | end | ||
157 | do | ||
158 | local _obj_0 = _u53d8_u91cfa["字段"] | ||
159 | if _obj_0["字段"] == nil then | ||
160 | _obj_0["字段"] = 1 | ||
161 | end | ||
162 | local _u53d8_u91cfa | ||
163 | do | ||
164 | local _exp_0 = _u53d8_u91cfb["字段"] | ||
165 | if _exp_0 ~= nil then | ||
166 | _u53d8_u91cfa = _exp_0 | ||
167 | else | ||
168 | do | ||
169 | local _exp_1 = _u53d8_u91cfc["字段"] | ||
170 | if _exp_1 ~= nil then | ||
171 | _u53d8_u91cfa = _exp_1 | ||
172 | else | ||
173 | _u53d8_u91cfa = _u53d8_u91cfd["字段"] | ||
174 | end | ||
175 | end | ||
176 | end | ||
177 | end | ||
178 | if _u53d8_u91cfa["字段"] == nil then | ||
179 | _u53d8_u91cfa["字段"] = 1 | ||
180 | end | ||
181 | end | ||
182 | return nil | ||