diff options
author | Li Jin <dragon-fly@qq.com> | 2023-08-17 10:36:15 +0800 |
---|---|---|
committer | Li Jin <dragon-fly@qq.com> | 2023-08-17 10:36:15 +0800 |
commit | e61cce21ef7def2c2e52dd6cb6a5b540ebcac29d (patch) | |
tree | 6e7c5e7e6f13157e9f8db26c38f6d8cba75683e5 /spec/outputs/unicode/with.lua | |
parent | 289faf45ac26f7e0ac1a1e4305e5c42fc1e5b866 (diff) | |
download | yuescript-e61cce21ef7def2c2e52dd6cb6a5b540ebcac29d.tar.gz yuescript-e61cce21ef7def2c2e52dd6cb6a5b540ebcac29d.tar.bz2 yuescript-e61cce21ef7def2c2e52dd6cb6a5b540ebcac29d.zip |
add unicode identifier support, fix more issue from #144
Diffstat (limited to 'spec/outputs/unicode/with.lua')
-rw-r--r-- | spec/outputs/unicode/with.lua | 222 |
1 files changed, 222 insertions, 0 deletions
diff --git a/spec/outputs/unicode/with.lua b/spec/outputs/unicode/with.lua new file mode 100644 index 0000000..0dcd4a7 --- /dev/null +++ b/spec/outputs/unicode/with.lua | |||
@@ -0,0 +1,222 @@ | |||
1 | do | ||
2 | local _u53d8_u91cfa | ||
3 | _u53d8_u91cfa = function() | ||
4 | local _with_0 = _u4e1c_u897f | ||
5 | _u6253_u5370(_with_0["你好"]) | ||
6 | _u6253_u5370(_u4f60_u597d) | ||
7 | _u6253_u5370("世界") | ||
8 | return _with_0 | ||
9 | end | ||
10 | end | ||
11 | do | ||
12 | do | ||
13 | local _with_0 = _u53f6_u5b50 | ||
14 | _with_0["世界"]() | ||
15 | _with_0["世界"](1, 2, 3) | ||
16 | local _u53d8_u91cfg = _with_0["什么"]["是"]["这"] | ||
17 | _with_0["你好"](1, 2, 3) | ||
18 | _with_0["你好"](_with_0, 1, 2)["世界"](2323) | ||
19 | _with_0["你好"](_with_0, "是的", "伙计") | ||
20 | _with_0["世界"] = 200 | ||
21 | end | ||
22 | end | ||
23 | do | ||
24 | local _u6ecb_u6ecb_u6ecb | ||
25 | do | ||
26 | local _with_0 = _u4e1c_u897f | ||
27 | _with_0["设置状态"]("你好 世界") | ||
28 | _u6ecb_u6ecb_u6ecb = _with_0 | ||
29 | end | ||
30 | end | ||
31 | do | ||
32 | local _u53d8_u91cfx = 5 + (function() | ||
33 | local _with_0 = _u67d0_u4e8b() | ||
34 | _with_0["写"](_with_0, "你好 世界") | ||
35 | return _with_0 | ||
36 | end)() | ||
37 | end | ||
38 | do | ||
39 | local _u53d8_u91cfx = { | ||
40 | ["你好"] = (function() | ||
41 | local _with_0 = _u597d_u7684 | ||
42 | _with_0["确定"](_with_0) | ||
43 | return _with_0 | ||
44 | end)() | ||
45 | } | ||
46 | end | ||
47 | do | ||
48 | do | ||
49 | local _with_0 = _u4e1c_u897f | ||
50 | local _ = _with_0["属性"](_with_0, "某物")["你好"] | ||
51 | local _call_0 = _with_0["属性"] | ||
52 | _call_0["发送"](_call_0, _u4e00_u4e2a) | ||
53 | local _call_1 = _with_0["属性"] | ||
54 | _call_1["发送"](_call_1, _u4e00_u4e2a) | ||
55 | end | ||
56 | end | ||
57 | do | ||
58 | do | ||
59 | local _with_0 = _u53d8_u91cfa | ||
60 | _u6253_u5370(_with_0["世界"]) | ||
61 | end | ||
62 | local _u6a21_u5757 | ||
63 | do | ||
64 | local __u6a21_u5757 = { } | ||
65 | __u6a21_u5757["事物"] = "你好" | ||
66 | _u6a21_u5757 = __u6a21_u5757 | ||
67 | end | ||
68 | do | ||
69 | local _u53d8_u91cfa, _u53d8_u91cfb = _u4e1c_u897f, _u5e03 | ||
70 | _u6253_u5370(_u53d8_u91cfa["世界"]) | ||
71 | end | ||
72 | local _u53d8_u91cfx | ||
73 | do | ||
74 | local _u53d8_u91cfa, _u53d8_u91cfb = 1, 2 | ||
75 | _u6253_u5370(_u53d8_u91cfa + _u53d8_u91cfb) | ||
76 | _u53d8_u91cfx = _u53d8_u91cfa | ||
77 | end | ||
78 | _u6253_u5370((function() | ||
79 | local _u53d8_u91cfa, _u53d8_u91cfb = 1, 2 | ||
80 | _u6253_u5370(_u53d8_u91cfa + _u53d8_u91cfb) | ||
81 | return _u53d8_u91cfa | ||
82 | end)()) | ||
83 | local p | ||
84 | do | ||
85 | local _with_0 = 1 | ||
86 | _u4f60_u597d()["字段x"], _u4e16_u754c()["字段y"] = _with_0, 2 | ||
87 | _u6253_u5370(_u53d8_u91cfa + _u53d8_u91cfb) | ||
88 | p = _with_0 | ||
89 | end | ||
90 | end | ||
91 | do | ||
92 | local _u53d8_u91cfx = "你好" | ||
93 | _u53d8_u91cfx["大写"](_u53d8_u91cfx) | ||
94 | end | ||
95 | do | ||
96 | do | ||
97 | local _u53d8_u91cfk = "乔" | ||
98 | _u6253_u5370(_u53d8_u91cfk["大写"](_u53d8_u91cfk)) | ||
99 | end | ||
100 | end | ||
101 | do | ||
102 | do | ||
103 | local _u53d8_u91cfa, _u53d8_u91cfb, _u53d8_u91cfc = "", "", "" | ||
104 | _u6253_u5370(_u53d8_u91cfa["大写"](_u53d8_u91cfa)) | ||
105 | end | ||
106 | end | ||
107 | do | ||
108 | local _u53d8_u91cfa = "床铺" | ||
109 | do | ||
110 | local _u53d8_u91cfb, _u53d8_u91cfc | ||
111 | _u53d8_u91cfa, _u53d8_u91cfb, _u53d8_u91cfc = "", "", "" | ||
112 | _u6253_u5370(_u53d8_u91cfa["大写"](_u53d8_u91cfa)) | ||
113 | end | ||
114 | end | ||
115 | do | ||
116 | do | ||
117 | local _with_0 = _u53d8_u91cfj | ||
118 | _u6253_u5370(_with_0["大写"](_with_0)) | ||
119 | end | ||
120 | end | ||
121 | do | ||
122 | do | ||
123 | local _with_0 = "乔" | ||
124 | _u53d8_u91cfk["变量j"] = _with_0 | ||
125 | _u6253_u5370(_with_0["大写"](_with_0)) | ||
126 | end | ||
127 | end | ||
128 | do | ||
129 | do | ||
130 | local _with_0 = _u53d8_u91cfa | ||
131 | _u6253_u5370(_with_0.b) | ||
132 | do | ||
133 | local _with_1 = _with_0.c | ||
134 | _u6253_u5370(_with_1.d) | ||
135 | end | ||
136 | end | ||
137 | end | ||
138 | do | ||
139 | do | ||
140 | local _with_0 = _u53d8_u91cfa | ||
141 | do | ||
142 | local _with_1 = 2 | ||
143 | _with_0.b = _with_1 | ||
144 | _u6253_u5370(_with_1.c) | ||
145 | end | ||
146 | end | ||
147 | end | ||
148 | do | ||
149 | local _ | ||
150 | _ = function() | ||
151 | local _with_0 = _u55e8 | ||
152 | return _with_0.a, _with_0.b | ||
153 | end | ||
154 | end | ||
155 | do | ||
156 | do | ||
157 | local _with_0 = _u8868_u683c | ||
158 | local _call_0 = _u9879_u76ee["字段"] | ||
159 | _with_0.x = _call_0["函数"](_call_0, 123) | ||
160 | end | ||
161 | end | ||
162 | do | ||
163 | do | ||
164 | local _with_0 = _u7238_u7238 | ||
165 | _with_0["如果"]("是的") | ||
166 | local _u53d8_u91cfy = _with_0["结束"]["函数"] | ||
167 | end | ||
168 | end | ||
169 | do | ||
170 | do | ||
171 | local _with_0 = _u8868_u683c | ||
172 | do | ||
173 | local _obj_0 = _with_0[2] | ||
174 | if _obj_0 ~= nil then | ||
175 | _with_0[1] = _obj_0["函数"](_obj_0) | ||
176 | end | ||
177 | end | ||
178 | _with_0["%a-b-c%"] = 123 | ||
179 | _with_0[ [[x y z]]] = _with_0[_u53d8_u91cf] | ||
180 | _u6253_u5370(_with_0[_with_0[3]]) | ||
181 | do | ||
182 | local _with_1 = _with_0[4] | ||
183 | _with_1[1] = 1 | ||
184 | end | ||
185 | _with_0[#_with_0 + 1] = "abc" | ||
186 | _with_0[#_with_0 + 1] = { | ||
187 | ["类型"] = "你好", | ||
188 | { | ||
189 | ["名字"] = "xyz", | ||
190 | ["值"] = 998 | ||
191 | } | ||
192 | } | ||
193 | end | ||
194 | end | ||
195 | do | ||
196 | do | ||
197 | local _with_0 = _u5b9e_u5fc3_u77e9_u5f62({ | ||
198 | ["宽"] = w, | ||
199 | ["高"] = h, | ||
200 | ["颜色"] = 0x66000000 | ||
201 | }) | ||
202 | _u63a9_u7801 = _with_0 | ||
203 | if _with_0 ~= nil then | ||
204 | _with_0["触摸启用"] = true | ||
205 | _with_0["吞噬触摸"] = true | ||
206 | end | ||
207 | end | ||
208 | end | ||
209 | do | ||
210 | do | ||
211 | local _u63a9_u7801 = _u5b9e_u5fc3_u77e9_u5f62({ | ||
212 | ["宽"] = w, | ||
213 | ["高"] = h, | ||
214 | ["颜色"] = 0x66000000 | ||
215 | }) | ||
216 | if _u63a9_u7801 ~= nil then | ||
217 | _u63a9_u7801["触摸启用"] = true | ||
218 | _u63a9_u7801["吞噬触摸"] = true | ||
219 | end | ||
220 | end | ||
221 | end | ||
222 | return nil | ||