on master help sign in
finished ints/floats
e8a619diko
zod/luau/TODO.md+2−1
@@ -2,5 +2,6 @@
2
2
3- [x] functioncall
3- [x] functioncall
4- [x] any string apart from the basic string with no escapes
4- [x] any string apart from the basic string with no escapes
5−- [ ] check if int fits in int or make it a float
5+- [x] check if int fits in int or make it a float
6- [x] should `print-blok` have `do`-`end`? This is fucked.
6- [x] should `print-blok` have `do`-`end`? This is fucked.
7+- [ ] binary operator priority
zod/luau/lib/lua/parser.hoon+7−2
@@ -1,4 +1,5 @@
1/- *lua
1/- *lua
2+/+ st
2/+ *interlist
3/+ *interlist
3=<
4=<
4apex
5apex
@@ -248,7 +249,7 @@ apex
248 parse-hex-float
249 parse-hex-float
249 ::
250 ::
250 %+ cook
251 %+ cook
251− |= x=@u [%int x]
252+ |= x=@u [%int (new:st x)]
252 ;~ pfix
253 ;~ pfix
253 (just '0')
254 (just '0')
254 (mask "xX")
255 (mask "xX")
@@ -260,7 +261,10 @@ apex
260 parse-float
261 parse-float
261 ::
262 ::
262 %+ cook
263 %+ cook
264+ |= x=@u
265+ ?: (gth x max-int)
266+ [%float (sun:rd x)]
263− |= x=@u [%int x]
267+ [%int (new:st x)]
264 (bass 10 (plus dit))
268 (bass 10 (plus dit))
265 ==
269 ==
266++ parse-exprlist
270++ parse-exprlist
@@ -888,4 +892,5 @@ apex
888 |= =blok
892 |= =blok
889 ^- ?
893 ^- ?
890 &(?=(~ body.blok) ?=(~ ret.blok))
894 &(?=(~ body.blok) ?=(~ ret.blok))
895+++ max-int 9.223.372.036.854.775.807
891--
896--
zod/luau/lib/lua/printer.hoon+3−2
@@ -1,4 +1,5 @@
1/- *lua
1/- *lua
2+/+ st
2=<
3=<
3print
4print
4|%
5|%
@@ -143,7 +144,7 @@ print
143 |= [num=numeral]
144 |= [num=numeral]
144 ^- tape
145 ^- tape
145 ?- -.num
146 ?- -.num
146− %int (show-u +.num)
147+ %int (z-co:co +.num)
147 %float (show-float +.num)
148 %float (show-float +.num)
148 ==
149 ==
149:: exprlist
150:: exprlist
@@ -503,7 +504,7 @@ print
503 %- zing
504 %- zing
504 %+ join "." l
505 %+ join "." l
505++ show-s
506++ show-s
506− |=(s=@s `tape`[?:((syn:si s) %$ '-') (slag 2 (scow %ui (abs:si s)))])
507+ |=(s=@s `tape`(zing [?:((syn:si s) "" "-") ~[(slag 2 (scow %ui (abs:si s)))]]))
507++ show-u
508++ show-u
508 |=(u=@u `tape`(slag 2 (scow %ui u)))
509 |=(u=@u `tape`(slag 2 (scow %ui u)))
509++ show-float
510++ show-float
zod/luau/lib/st.hoonnew file+35
@@ -0,0 +1,35 @@
1+:: Two's complement encoded 64-bit signed integer
2+=<
3+|%
4+:: coerce an unsigned int to a signed int
5+::
6+++ new
7+ |= x=@u
8+ ^- @st
9+ (dis mask x)
10+++ to-s
11+ |= x=@st
12+ ^- @s
13+ (new:si ?!((sig x)) (abs x))
14+++ sig
15+ |= x=@st
16+ ^- ?
17+ ?! =(0 (dis sign-mask x))
18+++ abs
19+ |= x=@st
20+ ^- @u
21+ ?. (sig x) `@u`x
22+ (dis mask +((mix mask x)))
23+++ inc
24+ |= x=@st
25+ ^- @st
26+ (dis mask +(x))
27+++ add
28+ |= [x=@st y=@st]
29+ ^- @st
30+ (dis mask (^add x y))
31+--
32+|%
33+++ mask 0xffff.ffff.ffff.ffff
34+++ sign-mask 0x8000.0000.0000.0000
35+--
zod/luau/res/lua/cycled/all.lua+16−16
@@ -34,7 +34,7 @@ local msgs = {}
34function Message(m)
34function Message(m)
35if not _nomsg then
35if not _nomsg then
36print(m)
36print(m)
37−msgs[# msgs + 1]=string.sub(m,3,- 3)
37+msgs[# msgs + 0x1]=string.sub(m,0x3,- 0x3)
38end
38end
39end
39end
40assert(os.setlocale("\u{43}"))
40assert(os.setlocale("\u{43}"))
@@ -46,28 +46,28 @@ local function round
46m=m + 0.04999
46m=m + 0.04999
47return format("\u{25}\u{2e}\u{31}\u{66}",m)
47return format("\u{25}\u{2e}\u{31}\u{66}",m)
48end
48end
49−if m < 1000 then
49+if m < 0x3e8 then
50return m
50return m
51else
51else
52−m=m / 1000
52+m=m / 0x3e8
53−if m < 1000 then
53+if m < 0x3e8 then
54return round(m) .. "\u{4b}"
54return round(m) .. "\u{4b}"
55else
55else
56−return round(m / 1000) .. "\u{4d}"
56+return round(m / 0x3e8) .. "\u{4d}"
57end
57end
58end
58end
59end
59end
60local Cstacklevel
60local Cstacklevel
61local showmem
61local showmem
62if not T then
62if not T then
63−local max = 0
63+local max = 0x0
64showmem=function ()
64showmem=function ()
65−local m = collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 1024
65+local m = collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 0x400
66max=(m > max) and m or max
66max=(m > max) and m or max
67print(format("\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{2d}\u{2d}\u{20}\u{74}\u{6f}\u{74}\u{61}\u{6c}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}\u{25}\u{73}\u{2c}\u{20}\u{6d}\u{61}\u{78}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}\u{25}\u{73}\u{20}\u{2d}\u{2d}\u{2d}\u{2d}\u{a}",F(m),F(max)))
67print(format("\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{2d}\u{2d}\u{20}\u{74}\u{6f}\u{74}\u{61}\u{6c}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}\u{25}\u{73}\u{2c}\u{20}\u{6d}\u{61}\u{78}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}\u{25}\u{73}\u{20}\u{2d}\u{2d}\u{2d}\u{2d}\u{a}",F(m),F(max)))
68end
68end
69Cstacklevel=function ()
69Cstacklevel=function ()
70−return 0
70+return 0x0
71end
71end
72else
72else
73showmem=function ()
73showmem=function ()
@@ -110,9 +110,9 @@ _G.deep=nil
110olddofile("\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
110olddofile("\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
111olddofile("\u{6c}\u{69}\u{74}\u{65}\u{72}\u{61}\u{6c}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
111olddofile("\u{6c}\u{69}\u{74}\u{65}\u{72}\u{61}\u{6c}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
112dofile("\u{74}\u{70}\u{61}\u{63}\u{6b}\u{2e}\u{6c}\u{75}\u{61}")
112dofile("\u{74}\u{70}\u{61}\u{63}\u{6b}\u{2e}\u{6c}\u{75}\u{61}")
113−assert(dofile("\u{61}\u{74}\u{74}\u{72}\u{69}\u{62}\u{2e}\u{6c}\u{75}\u{61}") == 27)
113+assert(dofile("\u{61}\u{74}\u{74}\u{72}\u{69}\u{62}\u{2e}\u{6c}\u{75}\u{61}") == 0x1b)
114dofile("\u{67}\u{65}\u{6e}\u{67}\u{63}\u{2e}\u{6c}\u{75}\u{61}")
114dofile("\u{67}\u{65}\u{6e}\u{67}\u{63}\u{2e}\u{6c}\u{75}\u{61}")
115−assert(dofile("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{73}\u{2e}\u{6c}\u{75}\u{61}") == 5)
115+assert(dofile("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{73}\u{2e}\u{6c}\u{75}\u{61}") == 0x5)
116dofile("\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
116dofile("\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
117dofile("\u{63}\u{6f}\u{64}\u{65}\u{2e}\u{6c}\u{75}\u{61}",true)
117dofile("\u{63}\u{6f}\u{64}\u{65}\u{2e}\u{6c}\u{75}\u{61}",true)
118if not _G._soft then
118if not _G._soft then
@@ -126,7 +126,7 @@ dofile("\u{6e}\u{65}\u{78}\u{74}\u{76}\u{61}\u{72}\u{2e}\u{6c}\u{75}\u{61}")
126dofile("\u{70}\u{6d}\u{2e}\u{6c}\u{75}\u{61}")
126dofile("\u{70}\u{6d}\u{2e}\u{6c}\u{75}\u{61}")
127dofile("\u{75}\u{74}\u{66}\u{38}\u{2e}\u{6c}\u{75}\u{61}")
127dofile("\u{75}\u{74}\u{66}\u{38}\u{2e}\u{6c}\u{75}\u{61}")
128dofile("\u{61}\u{70}\u{69}\u{2e}\u{6c}\u{75}\u{61}")
128dofile("\u{61}\u{70}\u{69}\u{2e}\u{6c}\u{75}\u{61}")
129−assert(dofile("\u{65}\u{76}\u{65}\u{6e}\u{74}\u{73}\u{2e}\u{6c}\u{75}\u{61}") == 12)
129+assert(dofile("\u{65}\u{76}\u{65}\u{6e}\u{74}\u{73}\u{2e}\u{6c}\u{75}\u{61}") == 0xc)
130dofile("\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{2e}\u{6c}\u{75}\u{61}")
130dofile("\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{2e}\u{6c}\u{75}\u{61}")
131dofile("\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{2e}\u{6c}\u{75}\u{61}")
131dofile("\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{2e}\u{6c}\u{75}\u{61}")
132dofile("\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{6c}\u{75}\u{61}")
132dofile("\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{6c}\u{75}\u{61}")
@@ -135,11 +135,11 @@ dofile("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
135dofile("\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{6c}\u{75}\u{61}")
135dofile("\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{6c}\u{75}\u{61}")
136dofile("\u{73}\u{6f}\u{72}\u{74}\u{2e}\u{6c}\u{75}\u{61}",true)
136dofile("\u{73}\u{6f}\u{72}\u{74}\u{2e}\u{6c}\u{75}\u{61}",true)
137dofile("\u{62}\u{69}\u{74}\u{77}\u{69}\u{73}\u{65}\u{2e}\u{6c}\u{75}\u{61}")
137dofile("\u{62}\u{69}\u{74}\u{77}\u{69}\u{73}\u{65}\u{2e}\u{6c}\u{75}\u{61}")
138−assert(dofile("\u{76}\u{65}\u{72}\u{79}\u{62}\u{69}\u{67}\u{2e}\u{6c}\u{75}\u{61}",true) == 10)
138+assert(dofile("\u{76}\u{65}\u{72}\u{79}\u{62}\u{69}\u{67}\u{2e}\u{6c}\u{75}\u{61}",true) == 0xa)
139;
139;
140collectgarbage()
140collectgarbage()
141dofile("\u{66}\u{69}\u{6c}\u{65}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
141dofile("\u{66}\u{69}\u{6c}\u{65}\u{73}\u{2e}\u{6c}\u{75}\u{61}")
142−if # msgs > 0 then
142+if # msgs > 0x0 then
143local m = table.concat(msgs,"\u{a}\u{20}\u{20}")
143local m = table.concat(msgs,"\u{a}\u{20}\u{20}")
144warn("\u{23}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{70}\u{65}\u{72}\u{66}\u{6f}\u{72}\u{6d}\u{65}\u{64}\u{3a}\u{a}\u{20}\u{20}",m,"\u{a}")
144warn("\u{23}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{70}\u{65}\u{72}\u{66}\u{6f}\u{72}\u{6d}\u{65}\u{64}\u{3a}\u{a}\u{20}\u{20}",m,"\u{a}")
145end
145end
@@ -153,7 +153,7 @@ warn("\u{40}\u{6f}\u{6e}")
153warn("\u{23}\u{54}\u{68}\u{69}\u{73}\u{20}\u{69}\u{73}","\u{20}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6f}\u{6e}\u{65}")
153warn("\u{23}\u{54}\u{68}\u{69}\u{73}\u{20}\u{69}\u{73}","\u{20}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6f}\u{6e}\u{65}")
154assert(debug == nil)
154assert(debug == nil)
155local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
155local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
156−print(string.format("\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{2c}\u{20}\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}",string.packsize("\u{6a}") * 8,string.packsize("\u{6e}") * 8))
156+print(string.format("\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{2c}\u{20}\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}",string.packsize("\u{6a}") * 0x8,string.packsize("\u{6e}") * 0x8))
157debug.sethook(function (a)
157debug.sethook(function (a)
158assert(type(a) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
158assert(type(a) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
159end,"\u{63}\u{72}")
159end,"\u{63}\u{72}")
@@ -176,7 +176,7 @@ end
176print("\u{63}\u{6c}\u{65}\u{61}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{6c}\u{6c}\u{21}\u{21}\u{21}\u{21}")
176print("\u{63}\u{6c}\u{65}\u{61}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{6c}\u{6c}\u{21}\u{21}\u{21}\u{21}")
177for n in pairs(_G)
177for n in pairs(_G)
178do
178do
179−if not ({["\u{5f}\u{5f}\u{5f}\u{47}\u{6c}\u{6f}\u{62}"] = 1,["\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}"] = 1})[n] then
179+if not ({["\u{5f}\u{5f}\u{5f}\u{47}\u{6c}\u{6f}\u{62}"] = 0x1,["\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}"] = 0x1})[n] then
180_G[n]=undef
180_G[n]=undef
181end
181end
182end
182end
@@ -196,7 +196,7 @@ lasttime=lasttime or clocktime
196local diff = (clocktime - lasttime) / lasttime
196local diff = (clocktime - lasttime) / lasttime
197local tolerance = 0.05
197local tolerance = 0.05
198if (diff >= tolerance or diff <= - tolerance) then
198if (diff >= tolerance or diff <= - tolerance) then
199−warn(format("\u{23}\u{74}\u{69}\u{6d}\u{65}\u{20}\u{64}\u{69}\u{66}\u{66}\u{65}\u{72}\u{65}\u{6e}\u{63}\u{65}\u{20}\u{66}\u{72}\u{6f}\u{6d}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{74}\u{65}\u{73}\u{74}\u{3a}\u{20}\u{25}\u{2b}\u{2e}\u{31}\u{66}\u{25}\u{25}",diff * 100))
199+warn(format("\u{23}\u{74}\u{69}\u{6d}\u{65}\u{20}\u{64}\u{69}\u{66}\u{66}\u{65}\u{72}\u{65}\u{6e}\u{63}\u{65}\u{20}\u{66}\u{72}\u{6f}\u{6d}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{74}\u{65}\u{73}\u{74}\u{3a}\u{20}\u{25}\u{2b}\u{2e}\u{31}\u{66}\u{25}\u{25}",diff * 0x64))
200end
200end
201assert(open(fname,"\u{77}")):write(clocktime):close()
201assert(open(fname,"\u{77}")):write(clocktime):close()
202end
202end
zod/luau/res/lua/cycled/api.lua+375−375
@@ -7,10 +7,10 @@ local pack = table.pack
7local MEMERRMSG = "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}"
7local MEMERRMSG = "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}"
8local function tcheck
8local function tcheck
9(t1,t2)
9(t1,t2)
10−assert(t1.n == (t2.n or # t2) + 1)
10+assert(t1.n == (t2.n or # t2) + 0x1)
11−for i = 2, t1.n
11+for i = 0x2, t1.n
12do
12do
13−assert(t1[i] == t2[i - 1])
13+assert(t1[i] == t2[i - 0x1])
14end
14end
15end
15end
16local function checkerr
16local function checkerr
@@ -21,63 +21,63 @@ end
21print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{43}\u{20}\u{41}\u{50}\u{49}")
21print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{43}\u{20}\u{41}\u{50}\u{49}")
22local a = T.testC("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{52}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
22local a = T.testC("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{52}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
23assert(a == debug.getregistry())
23assert(a == debug.getregistry())
24−assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 10)
24+assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0xa)
25−assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{35}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{2d}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 1)
25+assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{35}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{2d}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0x1)
26−assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 1)
26+assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0x1)
27−assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{52}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") < - 10)
27+assert(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{62}\u{73}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{52}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") < - 0xa)
28a=T.d2s(12458954321123.0)
28a=T.d2s(12458954321123.0)
29assert(a == string.pack("\u{64}",12458954321123.0))
29assert(a == string.pack("\u{64}",12458954321123.0))
30assert(T.s2d(a) == 12458954321123.0)
30assert(T.s2d(a) == 12458954321123.0)
31local a,b,c = T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
31local a,b,c = T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
32−assert(a == 2 and b == 3 and not c)
32+assert(a == 0x2 and b == 0x3 and not c)
33local f = T.makeCfunc("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
33local f = T.makeCfunc("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
34a,b,c=f()
34a,b,c=f()
35−assert(a == 2 and b == 3 and not c)
35+assert(a == 0x2 and b == 0x3 and not c)
36a,b,c=T.testC("\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
36a,b,c=T.testC("\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
37assert(a == b and a == true and c == false)
37assert(a == b and a == true and c == false)
38a,b,c=T.testC("\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{69}\u{6c}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{74}\u{6f}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{74}\u{6f}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
38a,b,c=T.testC("\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{69}\u{6c}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{74}\u{6f}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{74}\u{6f}\u{62}\u{6f}\u{6f}\u{6c}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
39assert(a == false and b == true and c == false)
39assert(a == false and b == true and c == false)
40−a,b,c=T.testC("\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",10,20,30,40)
40+a,b,c=T.testC("\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",0xa,0x14,0x1e,0x28)
41−assert(a == 40 and b == 5 and not c)
41+assert(a == 0x28 and b == 0x5 and not c)
42−local t = pack(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3))
42+local t = pack(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3))
43−tcheck(t,{["\u{6e}"] = 4,2,3})
43+tcheck(t,{["\u{6e}"] = 0x4,0x2,0x3})
44−t=pack(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{30}\u{3b}\u{20}\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{30}",3,1,23))
44+t=pack(T.testC("\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{30}\u{3b}\u{20}\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{30}",0x3,0x1,0x17))
45−assert(t.n == 10 and t[1] == nil and t[10] == nil)
45+assert(t.n == 0xa and t[0x1] == nil and t[0xa] == nil)
46−t=pack(T.testC("\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4))
46+t=pack(T.testC("\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4))
47−tcheck(t,{["\u{6e}"] = 2,2,4})
47+tcheck(t,{["\u{6e}"] = 0x2,0x2,0x4})
48−t=pack(T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3))
48+t=pack(T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3))
49−tcheck(t,{["\u{6e}"] = 2,2,3})
49+tcheck(t,{["\u{6e}"] = 0x2,0x2,0x3})
50−t=pack(T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5))
50+t=pack(T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5))
51−tcheck(t,{["\u{6e}"] = 4,2,5,3,4})
51+tcheck(t,{["\u{6e}"] = 0x4,0x2,0x5,0x3,0x4})
52−t=pack(T.testC("\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5))
52+t=pack(T.testC("\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5))
53−tcheck(t,{["\u{6e}"] = 3,5,3,4})
53+tcheck(t,{["\u{6e}"] = 0x3,0x5,0x3,0x4})
54−t=pack(T.testC("\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5))
54+t=pack(T.testC("\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5))
55−tcheck(t,{["\u{6e}"] = 3,2,3,5})
55+tcheck(t,{["\u{6e}"] = 0x3,0x2,0x3,0x5})
56−t=pack(T.testC("\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5))
56+t=pack(T.testC("\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5))
57−tcheck(t,{["\u{6e}"] = 3,2,4,5})
57+tcheck(t,{["\u{6e}"] = 0x3,0x2,0x4,0x5})
58−t=pack(T.testC("\u{63}\u{6f}\u{70}\u{79}\u{20}\u{33}\u{20}\u{34}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5))
58+t=pack(T.testC("\u{63}\u{6f}\u{70}\u{79}\u{20}\u{33}\u{20}\u{34}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5))
59−tcheck(t,{["\u{6e}"] = 4,2,3,3,5})
59+tcheck(t,{["\u{6e}"] = 0x4,0x2,0x3,0x3,0x5})
60−t=pack(T.testC("\u{63}\u{6f}\u{70}\u{79}\u{20}\u{2d}\u{33}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5))
60+t=pack(T.testC("\u{63}\u{6f}\u{70}\u{79}\u{20}\u{2d}\u{33}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5))
61−tcheck(t,{["\u{6e}"] = 4,2,3,4,3})
61+tcheck(t,{["\u{6e}"] = 0x4,0x2,0x3,0x4,0x3})
62do
62do
63−local t = {10,20,30,40,50,60}
63+local t = {0xa,0x14,0x1e,0x28,0x32,0x3c}
64−for i = - 6, 6
64+for i = - 0x6, 0x6
65do
65do
66local s = string.format("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{32}\u{20}\u{25}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{37}",i)
66local s = string.format("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{32}\u{20}\u{25}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{37}",i)
67−local t1 = pack(T.testC(s,10,20,30,40,50,60))
67+local t1 = pack(T.testC(s,0xa,0x14,0x1e,0x28,0x32,0x3c))
68tcheck(t1,t)
68tcheck(t1,t)
69−table.insert(t,1,table.remove(t))
69+table.insert(t,0x1,table.remove(t))
70−end
70+end
71−t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{32}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",10,20,30,40))
71+t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{32}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0xa,0x14,0x1e,0x28))
72−tcheck(t,{10,20,40,30})
72+tcheck(t,{0xa,0x14,0x28,0x1e})
73−t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{32}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",10,20,30,40))
73+t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{32}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0xa,0x14,0x1e,0x28))
74−tcheck(t,{10,20,40,30})
74+tcheck(t,{0xa,0x14,0x28,0x1e})
75−t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",10,20,30,40))
75+t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0xa,0x14,0x1e,0x28))
76−tcheck(t,{10,20,30,40})
76+tcheck(t,{0xa,0x14,0x1e,0x28})
77−t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",10,20,30,40))
77+t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0xa,0x14,0x1e,0x28))
78−tcheck(t,{10,20,30,40})
78+tcheck(t,{0xa,0x14,0x1e,0x28})
79−t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{35}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",10,20,30,40))
79+t=pack(T.testC("\u{72}\u{6f}\u{74}\u{61}\u{74}\u{65}\u{20}\u{35}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0xa,0x14,0x1e,0x28))
80−tcheck(t,{10,20,30,40})
80+tcheck(t,{0xa,0x14,0x1e,0x28})
81end
81end
82T.testC("\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{43}\u{20}\u{22}\u{23}\u{54}\u{68}\u{69}\u{73}\u{20}\u{73}\u{68}\u{6f}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{61}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{43}\u{20}\u{22}\u{20}\u{73}\u{69}\u{6e}\u{67}\u{6c}\u{65}\u{20}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{43}\u{20}\u{22}\u{23}\u{54}\u{68}\u{69}\u{73}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6f}\u{6e}\u{65}\u{22}\u{a}")
82T.testC("\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{43}\u{20}\u{22}\u{23}\u{54}\u{68}\u{69}\u{73}\u{20}\u{73}\u{68}\u{6f}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{61}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{43}\u{20}\u{22}\u{20}\u{73}\u{69}\u{6e}\u{67}\u{6c}\u{65}\u{20}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{43}\u{20}\u{22}\u{23}\u{54}\u{68}\u{69}\u{73}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{22}\u{a}\u{20}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6f}\u{6e}\u{65}\u{22}\u{a}")
83do
83do
@@ -85,207 +85,207 @@ local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{
85local msg,st = f(string.upper)
85local msg,st = f(string.upper)
86assert(st == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and msg == "\u{42}\u{4f}\u{4c}\u{41}")
86assert(st == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and msg == "\u{42}\u{4f}\u{4c}\u{41}")
87local msg,st = f(string.len)
87local msg,st = f(string.len)
88−assert(st == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and msg == 4)
88+assert(st == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and msg == 0x4)
89end
89end
90−t=pack(T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{31}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",2,3,4,5,10,40,90))
90+t=pack(T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{31}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",0x2,0x3,0x4,0x5,0xa,0x28,0x5a))
91−tcheck(t,{["\u{6e}"] = 7,2,3,4,5,10,40,90})
91+tcheck(t,{["\u{6e}"] = 0x7,0x2,0x3,0x4,0x5,0xa,0x28,0x5a})
92−t=pack(T.testC("\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{61}\u{6c}\u{6f}",2,3,"\u{6a}\u{6f}\u{61}\u{6f}",12))
92+t=pack(T.testC("\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{61}\u{6c}\u{6f}",0x2,0x3,"\u{6a}\u{6f}\u{61}\u{6f}",0xc))
93−tcheck(t,{["\u{6e}"] = 1,"\u{61}\u{6c}\u{6f}\u{32}\u{33}\u{6a}\u{6f}\u{61}\u{6f}\u{31}\u{32}"})
93+tcheck(t,{["\u{6e}"] = 0x1,"\u{61}\u{6c}\u{6f}\u{32}\u{33}\u{6a}\u{6f}\u{61}\u{6f}\u{31}\u{32}"})
94t=pack(T.testC("\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{32}\u{2c}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",function (a,b)
94t=pack(T.testC("\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{32}\u{2c}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",function (a,b)
95−return 1,2,3,4,a,b
95+return 0x1,0x2,0x3,0x4,a,b
96end,"\u{61}\u{6c}\u{6f}","\u{6a}\u{6f}\u{61}\u{6f}"))
96end,"\u{61}\u{6c}\u{6f}","\u{6a}\u{6f}\u{61}\u{6f}"))
97−tcheck(t,{["\u{6e}"] = 6,1,2,3,4,"\u{61}\u{6c}\u{6f}","\u{6a}\u{6f}\u{61}\u{6f}"})
97+tcheck(t,{["\u{6e}"] = 0x6,0x1,0x2,0x3,0x4,"\u{61}\u{6c}\u{6f}","\u{6a}\u{6f}\u{61}\u{6f}"})
98do
98do
99local a = {}
99local a = {}
100−for i = 1, 1000
100+for i = 0x1, 0x3e8
101do
101do
102a[i]=true
102a[i]=true
103end
103end
104;
104;
105−a[999]=10
105+a[0x3e7]=0xa
106local b = T.testC("\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{2d}\u{31}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{3b}\u{20}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",table.unpack,a)
106local b = T.testC("\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{2d}\u{31}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{3b}\u{20}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",table.unpack,a)
107assert(b == "\u{31}\u{30}")
107assert(b == "\u{31}\u{30}")
108end
108end
109−_G.AA=14
109+_G.AA=0xe
110;
110;
111_G.BB="\u{61}\u{33}\u{31}"
111_G.BB="\u{61}\u{33}\u{31}"
112local a = {T.testC("\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{41}\u{41}\u{3b}\u{a}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{42}\u{42}\u{3b}\u{a}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{42}\u{42}\u{3b}\u{a}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{41}\u{41}\u{3b}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}")}
112local a = {T.testC("\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{41}\u{41}\u{3b}\u{a}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{42}\u{42}\u{3b}\u{a}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{42}\u{42}\u{3b}\u{a}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{41}\u{41}\u{3b}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}")}
113−assert(a[2] == 14 and a[3] == "\u{61}\u{33}\u{31}" and a[4] == nil and _G.AA == "\u{61}\u{33}\u{31}")
113+assert(a[0x2] == 0xe and a[0x3] == "\u{61}\u{33}\u{31}" and a[0x4] == nil and _G.AA == "\u{61}\u{33}\u{31}")
114_G.AA,_G.BB=nil
114_G.AA,_G.BB=nil
115assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2f}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0.5)
115assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2f}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0.5)
116−assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2d}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 10)
116+assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2d}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 0xa)
117−assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{2d}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2a}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 200)
117+assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{2d}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2a}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 0xc8)
118−assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5e}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 1000)
118+assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5e}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0x3e8)
119assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2f}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0.5)
119assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2f}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0.5)
120−assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2d}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 10)
120+assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2d}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 0xa)
121−assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2a}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 200)
121+assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{32}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2a}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == - 0xc8)
122−assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5e}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 1000)
122+assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5e}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == 0x3e8)
123−assert(T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2f}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",2,0) == 10.0 / 0)
123+assert(T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2f}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x2,0x0) == 10.0 / 0x0)
124a=T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5c}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
124a=T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5c}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
125assert(a == 3.0 and math.type(a) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
125assert(a == 3.0 and math.type(a) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
126a=T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5c}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
126a=T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5c}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
127−assert(a == 3 and math.type(a) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}")
127+assert(a == 0x3 and math.type(a) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}")
128a=assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
128a=assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
129−assert(a == 13 and math.type(a) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}")
129+assert(a == 0xd and math.type(a) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}")
130a=assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
130a=assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
131−assert(a == 13 and math.type(a) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
131+assert(a == 0xd and math.type(a) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
132a,b,c=T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5f}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
132a,b,c=T.testC("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5f}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
133−assert(a == 1 and b == - 10 and c == "\u{35}")
133+assert(a == 0x1 and b == - 0xa and c == "\u{35}")
134local mt = {["\u{5f}\u{5f}\u{61}\u{64}\u{64}"] = function (a,b)
134local mt = {["\u{5f}\u{5f}\u{61}\u{64}\u{64}"] = function (a,b)
135−return setmetatable({a[1] + b[1]},mt)
135+return setmetatable({a[0x1] + b[0x1]},mt)
136end,["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}"] = function (a,b)
136end,["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}"] = function (a,b)
137−return setmetatable({a[1] % b[1]},mt)
137+return setmetatable({a[0x1] % b[0x1]},mt)
138end,["\u{5f}\u{5f}\u{75}\u{6e}\u{6d}"] = function (a)
138end,["\u{5f}\u{5f}\u{75}\u{6e}\u{6d}"] = function (a)
139−return setmetatable({a[1] * 2},mt)
139+return setmetatable({a[0x1] * 0x2},mt)
140end}
140end}
141−a,b,c=setmetatable({4},mt),setmetatable({8},mt),setmetatable({- 3},mt)
141+a,b,c=setmetatable({0x4},mt),setmetatable({0x8},mt),setmetatable({- 0x3},mt)
142−local x,y,z = T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",10,a,b)
142+local x,y,z = T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",0xa,a,b)
143−assert(x == 10 and y[1] == 12 and z == nil)
143+assert(x == 0xa and y[0x1] == 0xc and z == nil)
144−assert(T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{25}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a,c)[1] == 4 % - 3)
144+assert(T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{25}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a,c)[0x1] == 0x4 % - 0x3)
145−assert(T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5f}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{25}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b,a,c)[1] == 8 % (4 + (- 3) * 2))
145+assert(T.testC("\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5f}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{2b}\u{3b}\u{20}\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{25}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b,a,c)[0x1] == 0x8 % (0x4 + (- 0x3) * 0x2))
146−checkerr("\u{64}\u{69}\u{76}\u{69}\u{64}\u{65}\u{20}\u{62}\u{79}\u{20}\u{7a}\u{65}\u{72}\u{6f}",T.testC,"\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5c}",10,0)
146+checkerr("\u{64}\u{69}\u{76}\u{69}\u{64}\u{65}\u{20}\u{62}\u{79}\u{20}\u{7a}\u{65}\u{72}\u{6f}",T.testC,"\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{5c}",0xa,0x0)
147−checkerr("\u{25}\u{25}\u{30}",T.testC,"\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{25}",10,0)
147+checkerr("\u{25}\u{25}\u{30}",T.testC,"\u{61}\u{72}\u{69}\u{74}\u{68}\u{20}\u{25}",0xa,0x0)
148−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",3,2,2,4,2,2))
148+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x3,0x2,0x2,0x4,0x2,0x2))
149−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",3,2,2,4,2,2))
149+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x3,0x2,0x2,0x4,0x2,0x2))
150−assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{33}\u{20}\u{34}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",3,2,2,4,2,2))
150+assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{33}\u{20}\u{34}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x3,0x2,0x2,0x4,0x2,0x2))
151−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{33}\u{20}\u{34}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",3,2,2,4,2,2))
151+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{33}\u{20}\u{34}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x3,0x2,0x2,0x4,0x2,0x2))
152−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{35}\u{20}\u{32}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",4,2,2,3,2,2))
152+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{35}\u{20}\u{32}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x4,0x2,0x2,0x3,0x2,0x2))
153assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{2d}\u{33}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{34}","\u{32}","\u{32}","\u{33}","\u{32}","\u{32}"))
153assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{2d}\u{33}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{34}","\u{32}","\u{32}","\u{33}","\u{32}","\u{32}"))
154assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{2d}\u{33}\u{20}\u{32}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{33}","\u{32}","\u{32}","\u{34}","\u{32}","\u{32}"))
154assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{2d}\u{33}\u{20}\u{32}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{33}","\u{32}","\u{32}","\u{34}","\u{32}","\u{32}"))
155assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{31}\u{20}\u{34}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
155assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{31}\u{20}\u{34}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
156assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{39}\u{20}\u{31}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
156assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{39}\u{20}\u{31}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
157assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{39}\u{20}\u{39}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
157assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{39}\u{20}\u{39}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
158local b = {["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
158local b = {["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
159−return a[1] < b[1]
159+return a[0x1] < b[0x1]
160end}
160end}
161−local a1,a3,a4 = setmetatable({1},b),setmetatable({3},b),setmetatable({4},b)
161+local a1,a3,a4 = setmetatable({0x1},b),setmetatable({0x3},b),setmetatable({0x4},b)
162−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a3,2,2,a4,2,2))
162+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a3,0x2,0x2,a4,0x2,0x2))
163−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a3,2,2,a4,2,2))
163+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{32}\u{20}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a3,0x2,0x2,a4,0x2,0x2))
164−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a4,2,2,a3,2,2))
164+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a4,0x2,0x2,a3,0x2,0x2))
165−a,b=T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a1,2,2,a3,2,20)
165+a,b=T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a1,0x2,0x2,a3,0x2,0x14)
166−assert(a == 20 and b == false)
166+assert(a == 0x14 and b == false)
167−a,b=T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a1,2,2,a3,2,20)
167+a,b=T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a1,0x2,0x2,a3,0x2,0x14)
168−assert(a == 20 and b == false)
168+assert(a == 0x14 and b == false)
169−a,b=T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a1,2,2,a1,2,20)
169+a,b=T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{35}\u{20}\u{2d}\u{36}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a1,0x2,0x2,a1,0x2,0x14)
170−assert(a == 20 and b == true)
170+assert(a == 0x14 and b == true)
171do
171do
172local mt = {["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
172local mt = {["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
173−return a[1] < b[1]
173+return a[0x1] < b[0x1]
174end,["\u{5f}\u{5f}\u{6c}\u{65}"] = function (a,b)
174end,["\u{5f}\u{5f}\u{6c}\u{65}"] = function (a,b)
175−return a[1] <= b[1]
175+return a[0x1] <= b[0x1]
176end,["\u{5f}\u{5f}\u{65}\u{71}"] = function (a,b)
176end,["\u{5f}\u{5f}\u{65}\u{71}"] = function (a,b)
177−return a[1] == b[1]
177+return a[0x1] == b[0x1]
178end}
178end}
179local function O
179local function O
180(x)
180(x)
181return setmetatable({x},mt)
181return setmetatable({x},mt)
182end
182end
183−local a,b = T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",O(1),O(2))
183+local a,b = T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{54}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",O(0x1),O(0x2))
184−assert(a == true and b == 10)
184+assert(a == true and b == 0xa)
185−local a,b = T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",O(3),O(2))
185+local a,b = T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{4c}\u{45}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",O(0x3),O(0x2))
186−assert(a == false and b == 10)
186+assert(a == false and b == 0xa)
187−local a,b = T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",O(3),O(3))
187+local a,b = T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",O(0x3),O(0x3))
188−assert(a == true and b == 10)
188+assert(a == true and b == 0xa)
189end
189end
190−local t = setmetatable({["\u{78}"] = 20},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function (t)
190+local t = setmetatable({["\u{78}"] = 0x14},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function (t)
191return t.x
191return t.x
192end})
192end})
193a,b,c=T.testC("\u{20}\u{20}\u{20}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{4c}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}\u{a}",t)
193a,b,c=T.testC("\u{20}\u{20}\u{20}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{4c}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}\u{a}",t)
194−assert(a == 20 and b == 20 and c == 0)
194+assert(a == 0x14 and b == 0x14 and c == 0x0)
195t.x="\u{32}\u{33}\u{34}"
195t.x="\u{32}\u{33}\u{34}"
196;
196;
197−t[1]=20
197+t[0x1]=0x14
198a,b,c=T.testC("\u{20}\u{20}\u{20}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{4c}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}\u{a}",t)
198a,b,c=T.testC("\u{20}\u{20}\u{20}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{4c}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}\u{a}",t)
199−assert(a == "\u{32}\u{33}\u{34}" and b == 234 and c == 1)
199+assert(a == "\u{32}\u{33}\u{34}" and b == 0xea and c == 0x1)
200t.x=print
200t.x=print
201;
201;
202−t[1]=20
202+t[0x1]=0x14
203a,c=T.testC("\u{20}\u{20}\u{20}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}",t)
203a,c=T.testC("\u{20}\u{20}\u{20}\u{6c}\u{65}\u{6e}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}",t)
204−assert(a == print and c == 1)
204+assert(a == print and c == 0x1)
205a=setmetatable({["\u{78}"] = "\u{75}"},{["\u{5f}\u{5f}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"] = function (a,b)
205a=setmetatable({["\u{78}"] = "\u{75}"},{["\u{5f}\u{5f}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"] = function (a,b)
206return a.x .. "\u{2e}" .. b.x
206return a.x .. "\u{2e}" .. b.x
207end})
207end})
208x,y=T.testC("\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{35}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{3b}\u{a}",a,a)
208x,y=T.testC("\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{35}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{3b}\u{a}",a,a)
209−assert(x == a .. a and y == 5)
209+assert(x == a .. a and y == 0x5)
210assert(T.testC("\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == "")
210assert(T.testC("\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == "")
211assert(T.testC("\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{78}\u{75}\u{78}\u{75}") == "\u{78}\u{75}\u{78}\u{75}")
211assert(T.testC("\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{78}\u{75}\u{78}\u{75}") == "\u{78}\u{75}\u{78}\u{75}")
212local function B
212local function B
213(x)
213(x)
214−return x and 1 or 0
214+return x and 0x1 or 0x0
215end
215end
216local function count
216local function count
217(x,n)
217(x,n)
218−n=n or 2
218+n=n or 0x2
219local prog = "\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{63}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{6e}\u{69}\u{6c}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{38}\u{a}\u{20}\u{20}"
219local prog = "\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{63}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{6e}\u{69}\u{6c}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{25}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{38}\u{a}\u{20}\u{20}"
220prog=string.format(prog,n,n,n,n,n,n,n,n)
220prog=string.format(prog,n,n,n,n,n,n,n,n)
221local a,b,c,d,e,f,g,h = T.testC(prog,x)
221local a,b,c,d,e,f,g,h = T.testC(prog,x)
222−return B(a) + B(b) + B(c) + B(d) + B(e) + B(f) + B(g) + (100 * B(h))
222+return B(a) + B(b) + B(c) + B(d) + B(e) + B(f) + B(g) + (0x64 * B(h))
223end
223end
224−assert(count(3) == 2)
224+assert(count(0x3) == 0x2)
225−assert(count("\u{61}\u{6c}\u{6f}") == 1)
225+assert(count("\u{61}\u{6c}\u{6f}") == 0x1)
226−assert(count("\u{33}\u{32}") == 2)
226+assert(count("\u{33}\u{32}") == 0x2)
227−assert(count({}) == 1)
227+assert(count({}) == 0x1)
228−assert(count(print) == 2)
228+assert(count(print) == 0x2)
229assert(count(function ()
229assert(count(function ()
230
230
231−end) == 1)
231+end) == 0x1)
232−assert(count(nil) == 1)
232+assert(count(nil) == 0x1)
233−assert(count(io.stdin) == 1)
233+assert(count(io.stdin) == 0x1)
234−assert(count(nil,15) == 100)
234+assert(count(nil,0xf) == 0x64)
235local function to
235local function to
236(s,x,n)
236(s,x,n)
237−n=n or 2
237+n=n or 0x2
238return T.testC(string.format("\u{25}\u{73}\u{20}\u{25}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",s,n),x)
238return T.testC(string.format("\u{25}\u{73}\u{20}\u{25}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",s,n),x)
239end
239end
240−local null = T.pushuserdata(0)
240+local null = T.pushuserdata(0x0)
241local hfunc = string.gmatch("","")
241local hfunc = string.gmatch("","")
242−assert(debug.getupvalue(hfunc,1))
242+assert(debug.getupvalue(hfunc,0x1))
243assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",{}) == nil)
243assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",{}) == nil)
244assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}","\u{61}\u{6c}\u{6f}") == "\u{61}\u{6c}\u{6f}")
244assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}","\u{61}\u{6c}\u{6f}") == "\u{61}\u{6c}\u{6f}")
245−assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",12) == "\u{31}\u{32}")
245+assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",0xc) == "\u{31}\u{32}")
246−assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",12,3) == nil)
246+assert(to("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",0xc,0x3) == nil)
247−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",{}) == 0)
247+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",{}) == 0x0)
248−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",{1,2,3}) == 3)
248+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",{0x1,0x2,0x3}) == 0x3)
249−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}","\u{61}\u{6c}\u{6f}\u{0}\u{0}\u{61}") == 6)
249+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}","\u{61}\u{6c}\u{6f}\u{0}\u{0}\u{61}") == 0x6)
250−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",T.newuserdata(0)) == 0)
250+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",T.newuserdata(0x0)) == 0x0)
251−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",T.newuserdata(101)) == 101)
251+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",T.newuserdata(0x65)) == 0x65)
252−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",124) == 0)
252+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",0x7c) == 0x0)
253−assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",true) == 0)
253+assert(to("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}",true) == 0x0)
254−assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}",{}) == 0)
254+assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}",{}) == 0x0)
255−assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}","\u{31}\u{32}") == 12)
255+assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}","\u{31}\u{32}") == 0xc)
256−assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}","\u{73}\u{32}") == 0)
256+assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}","\u{73}\u{32}") == 0x0)
257−assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}",1,20) == 0)
257+assert(to("\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}",0x1,0x14) == 0x0)
258−assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",10) == null)
258+assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",0xa) == null)
259assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",true) == null)
259assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",true) == null)
260assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",nil) == null)
260assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",nil) == null)
261assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}","\u{61}\u{62}\u{63}") ~= null)
261assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}","\u{61}\u{62}\u{63}") ~= null)
262−assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",string.rep("\u{78}",10)) == to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",string.rep("\u{78}",10)))
262+assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",string.rep("\u{78}",0xa)) == to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",string.rep("\u{78}",0xa)))
263do
263do
264−local s1 = string.rep("\u{78}",300)
264+local s1 = string.rep("\u{78}",0x12c)
265−local s2 = string.rep("\u{78}",300)
265+local s2 = string.rep("\u{78}",0x12c)
266assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",s1) ~= to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",s2))
266assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",s1) ~= to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",s2))
267end
267end
268−assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",T.pushuserdata(20)) ~= null)
268+assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",T.pushuserdata(0x14)) ~= null)
269assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",io.read) ~= null)
269assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",io.read) ~= null)
270assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",hfunc) ~= null)
270assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",hfunc) ~= null)
271assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",function ()
271assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",function ()
272
272
273end) ~= null)
273end) ~= null)
274assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",io.stdin) ~= null)
274assert(to("\u{74}\u{6f}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{65}\u{72}",io.stdin) ~= null)
275−assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",20) == 0)
275+assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",0x14) == 0x0)
276−assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",T.pushuserdata(10)) == 0)
276+assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",T.pushuserdata(0xa)) == 0x0)
277−assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",io.read) ~= 0)
277+assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",io.read) ~= 0x0)
278−assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",hfunc) ~= 0)
278+assert(to("\u{66}\u{75}\u{6e}\u{63}\u{32}\u{6e}\u{75}\u{6d}",hfunc) ~= 0x0)
279a=to("\u{74}\u{6f}\u{63}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}",math.deg)
279a=to("\u{74}\u{6f}\u{63}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}",math.deg)
280−assert(a(3) == math.deg(3) and a == math.deg)
280+assert(a(0x3) == math.deg(0x3) and a == math.deg)
281print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{6e}\u{69}\u{63}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
281print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{6e}\u{69}\u{63}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
282do
282do
283assert(T.checkpanic("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{68}\u{69}\u{3b}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}") == "\u{68}\u{69}")
283assert(T.checkpanic("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{68}\u{69}\u{3b}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}") == "\u{68}\u{69}")
284assert(T.checkpanic("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{68}\u{69}\u{3b}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3b}","\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{35}\u{20}\u{58}\u{58}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{20}\u{61}\u{6c}\u{6f}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{20}\u{6d}\u{75}\u{6e}\u{64}\u{6f}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{33}") == "\u{68}\u{69}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{6d}\u{75}\u{6e}\u{64}\u{6f}")
284assert(T.checkpanic("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{68}\u{69}\u{3b}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3b}","\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{35}\u{20}\u{58}\u{58}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{20}\u{61}\u{6c}\u{6f}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{20}\u{6d}\u{75}\u{6e}\u{64}\u{6f}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}\u{20}\u{33}") == "\u{68}\u{69}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{6d}\u{75}\u{6e}\u{64}\u{6f}")
285assert(T.checkpanic("\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{34}") == "\u{62}\u{61}\u{64}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{23}\u{34}\u{20}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{2c}\u{20}\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{6f}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{29}")
285assert(T.checkpanic("\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{34}") == "\u{62}\u{61}\u{64}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{23}\u{34}\u{20}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{2c}\u{20}\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{6f}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{29}")
286−T.totalmem(T.totalmem() + 10000)
286+T.totalmem(T.totalmem() + 0x2710)
287assert(T.checkpanic("\u{6e}\u{65}\u{77}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{30}\u{30}\u{30}\u{30}") == MEMERRMSG)
287assert(T.checkpanic("\u{6e}\u{65}\u{77}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{30}\u{30}\u{30}\u{30}") == MEMERRMSG)
288−T.totalmem(0)
288+T.totalmem(0x0)
289if not _soft then
289if not _soft then
290local msg = T.checkpanic("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{28}\u{29}\u{20}\u{66}\u{28}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{22}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{66}\u{3b}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}")
290local msg = T.checkpanic("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{28}\u{29}\u{20}\u{66}\u{28}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{22}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{66}\u{3b}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}")
291assert(string.find(msg,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
291assert(string.find(msg,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
@@ -297,31 +297,31 @@ print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\
297collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
297collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
298checkerr("\u{58}\u{58}\u{58}\u{58}",T.testC,"\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{31}\u{30}\u{30}\u{30}\u{30}\u{32}\u{33}\u{20}\u{58}\u{58}\u{58}\u{58}")
298checkerr("\u{58}\u{58}\u{58}\u{58}",T.testC,"\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{31}\u{30}\u{30}\u{30}\u{30}\u{32}\u{33}\u{20}\u{58}\u{58}\u{58}\u{58}")
299checkerr("\u{5e}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{24}",T.testC,"\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{31}\u{30}\u{30}\u{30}\u{30}\u{32}\u{33}\u{20}\u{27}\u{27}")
299checkerr("\u{5e}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{24}",T.testC,"\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{31}\u{30}\u{30}\u{30}\u{30}\u{32}\u{33}\u{20}\u{27}\u{27}")
300−local s = string.rep("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{69}\u{6c}\u{3b}\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{31}\u{20}\u{58}\u{58}\u{3b}",1000000)
300+local s = string.rep("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{69}\u{6c}\u{3b}\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{31}\u{20}\u{58}\u{58}\u{3b}",0xf4240)
301checkerr("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",T.testC,s)
301checkerr("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",T.testC,s)
302collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
302collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
303print("\u{2b}")
303print("\u{2b}")
304end
304end
305−local lim = _soft and 500 or 12000
305+local lim = _soft and 0x1f4 or 0x2ee0
306−local prog = {"\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}" .. (lim * 2 + 100) .. "\u{6d}\u{73}\u{67}","\u{6e}\u{65}\u{77}\u{74}\u{61}\u{62}\u{6c}\u{65}"}
306+local prog = {"\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}" .. (lim * 0x2 + 0x64) .. "\u{6d}\u{73}\u{67}","\u{6e}\u{65}\u{77}\u{74}\u{61}\u{62}\u{6c}\u{65}"}
307−for i = 1, lim
307+for i = 0x1, lim
308do
308do
309−prog[# prog + 1]="\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}" .. i
309+prog[# prog + 0x1]="\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}" .. i
310−prog[# prog + 1]="\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}" .. i * 10
310+prog[# prog + 0x1]="\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}" .. i * 0xa
311end
311end
312−prog[# prog + 1]="\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{32}"
312+prog[# prog + 0x1]="\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{32}"
313−prog[# prog + 1]="\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}" .. - (2 * lim + 2)
313+prog[# prog + 0x1]="\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}" .. - (0x2 * lim + 0x2)
314−for i = 1, lim
314+for i = 0x1, lim
315do
315do
316−prog[# prog + 1]="\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}" .. - (2 * (lim - i + 1) + 1)
316+prog[# prog + 0x1]="\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}" .. - (0x2 * (lim - i + 0x1) + 0x1)
317end
317end
318−prog[# prog + 1]="\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}"
318+prog[# prog + 0x1]="\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}"
319prog=table.concat(prog,"\u{3b}")
319prog=table.concat(prog,"\u{3b}")
320local g,t = T.testC(prog)
320local g,t = T.testC(prog)
321assert(g == _G)
321assert(g == _G)
322−for i = 1, lim
322+for i = 0x1, lim
323do
323do
324−assert(t[i] == i * 10)
324+assert(t[i] == i * 0xa)
325;
325;
326t[i]=undef
326t[i]=undef
327end
327end
@@ -330,15 +330,15 @@ prog,g,t=nil
330a=T.testC("\u{20}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{31}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{30}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}","\u{58}\u{58}\u{3d}\u{31}\u{35}\u{30}",function (a)
330a=T.testC("\u{20}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{3b}\u{20}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{31}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{30}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}","\u{58}\u{58}\u{3d}\u{31}\u{35}\u{30}",function (a)
331assert(a == nil)
331assert(a == nil)
332;
332;
333−return 3
333+return 0x3
334end)
334end)
335−assert(type(a) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and XX == 150)
335+assert(type(a) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and XX == 0x96)
336_G.XX=nil
336_G.XX=nil
337local function check3
337local function check3
338(p, ...)
338(p, ...)
339local arg = {...}
339local arg = {...}
340−assert(# arg == 3)
340+assert(# arg == 0x3)
341−assert(string.find(arg[3],p))
341+assert(string.find(arg[0x3],p))
342end
342end
343check3("\u{3a}\u{31}\u{3a}",T.testC("\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{78}\u{3d}"))
343check3("\u{3a}\u{31}\u{3a}",T.testC("\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{78}\u{3d}"))
344check3("\u{25}\u{2e}",T.testC("\u{6c}\u{6f}\u{61}\u{64}\u{66}\u{69}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{2e}"))
344check3("\u{25}\u{2e}",T.testC("\u{6c}\u{6f}\u{61}\u{64}\u{66}\u{69}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{2e}"))
@@ -365,52 +365,52 @@ end
365print("\u{2b}")
365print("\u{2b}")
366do
366do
367local a = {}
367local a = {}
368−local a1 = T.testC("\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{70}\u{20}\u{32}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a,20)
368+local a1 = T.testC("\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{70}\u{20}\u{32}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a,0x14)
369assert(a == a1)
369assert(a == a1)
370−assert(a[T.pushuserdata(1)] == 20)
370+assert(a[T.pushuserdata(0x1)] == 0x14)
371local a1,res = T.testC("\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{70}\u{20}\u{2d}\u{31}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a)
371local a1,res = T.testC("\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{70}\u{20}\u{2d}\u{31}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a)
372−assert(a == a1 and res == 20)
372+assert(a == a1 and res == 0x14)
373end
373end
374do
374do
375local a = {}
375local a = {}
376−a[a]=10
376+a[a]=0xa
377local prog = "\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
377local prog = "\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
378local res = {T.testC(prog,a)}
378local res = {T.testC(prog,a)}
379−assert(# res == 2 and res[1] == prog and res[2] == 10)
379+assert(# res == 0x2 and res[0x1] == prog and res[0x2] == 0xa)
380local prog = "\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
380local prog = "\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
381−local res = {T.testC(prog,a,20)}
381+local res = {T.testC(prog,a,0x14)}
382−assert(a[a] == 20)
382+assert(a[a] == 0x14)
383−assert(# res == 1 and res[1] == prog)
383+assert(# res == 0x1 and res[0x1] == prog)
384−a[a]=10
384+a[a]=0xa
385local prog = "\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
385local prog = "\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
386local res = {T.testC(prog,a)}
386local res = {T.testC(prog,a)}
387−assert(# res == 2 and res[1] == prog and res[2] == 10)
387+assert(# res == 0x2 and res[0x1] == prog and res[0x2] == 0xa)
388local prog = "\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
388local prog = "\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
389−local res = {T.testC(prog,a,20)}
389+local res = {T.testC(prog,a,0x14)}
390−assert(a[a] == 20)
390+assert(a[a] == 0x14)
391−assert(# res == 1 and res[1] == prog)
391+assert(# res == 0x1 and res[0x1] == prog)
392local prog = "\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
392local prog = "\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
393−local res = {T.testC(prog,30,a)}
393+local res = {T.testC(prog,0x1e,a)}
394−assert(a[30] == a)
394+assert(a[0x1e] == a)
395−assert(# res == 1 and res[1] == prog)
395+assert(# res == 0x1 and res[0x1] == prog)
396local prog = "\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
396local prog = "\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
397−local res = {T.testC(prog,40,a)}
397+local res = {T.testC(prog,0x28,a)}
398−assert(a[40] == a)
398+assert(a[0x28] == a)
399−assert(# res == 1 and res[1] == prog)
399+assert(# res == 0x1 and res[0x1] == prog)
400local prog = "\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{69}\u{20}\u{2d}\u{31}\u{20}\u{31}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
400local prog = "\u{72}\u{61}\u{77}\u{73}\u{65}\u{74}\u{69}\u{20}\u{2d}\u{31}\u{20}\u{31}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
401local res = {T.testC(prog,a)}
401local res = {T.testC(prog,a)}
402−assert(a[100] == a)
402+assert(a[0x64] == a)
403−assert(# res == 1 and res[1] == prog)
403+assert(# res == 0x1 and res[0x1] == prog)
404local prog = "\u{73}\u{65}\u{74}\u{69}\u{20}\u{2d}\u{31}\u{20}\u{32}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
404local prog = "\u{73}\u{65}\u{74}\u{69}\u{20}\u{2d}\u{31}\u{20}\u{32}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}"
405local res = {T.testC(prog,a)}
405local res = {T.testC(prog,a)}
406−assert(a[200] == a)
406+assert(a[0xc8] == a)
407−assert(# res == 1 and res[1] == prog)
407+assert(# res == 0x1 and res[0x1] == prog)
408−end
408+end
409−a={["\u{78}"] = 0,["\u{79}"] = 12}
409+a={["\u{78}"] = 0x0,["\u{79}"] = 0xc}
410−x,y=T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{34}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a,3,"\u{79}",4,"\u{78}")
410+x,y=T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{34}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a,0x3,"\u{79}",0x4,"\u{78}")
411−assert(x == 0 and y == 12)
411+assert(x == 0x0 and y == 0xc)
412−T.testC("\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{35}",a,3,4,"\u{78}",15)
412+T.testC("\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{35}",a,0x3,0x4,"\u{78}",0xf)
413−assert(a.x == 15)
413+assert(a.x == 0xf)
414a[a]=print
414a[a]=print
415x=T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a)
415x=T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a)
416assert(x == print)
416assert(x == print)
@@ -420,85 +420,85 @@ b=setmetatable({["\u{70}"] = a},{})
420getmetatable(b).__index=function (t,i)
420getmetatable(b).__index=function (t,i)
421return t.p[i]
421return t.p[i]
422end
422end
423−local k,x = T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{33}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",4,b,20,35,"\u{78}")
423+local k,x = T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{33}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",0x4,b,0x14,0x23,"\u{78}")
424−assert(x == 15 and k == 35)
424+assert(x == 0xf and k == 0x23)
425k=T.testC("\u{67}\u{65}\u{74}\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{32}\u{20}\u{79}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b)
425k=T.testC("\u{67}\u{65}\u{74}\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{32}\u{20}\u{79}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b)
426−assert(k == 12)
426+assert(k == 0xc)
427getmetatable(b).__index=function (t,i)
427getmetatable(b).__index=function (t,i)
428return a[i]
428return a[i]
429end
429end
430getmetatable(b).__newindex=function (t,i,v)
430getmetatable(b).__newindex=function (t,i,v)
431a[i]=v
431a[i]=v
432end
432end
433−y=T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{32}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",2,3,4,"\u{79}",b)
433+y=T.testC("\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{20}\u{32}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x2,0x3,0x4,"\u{79}",b)
434−assert(y == 12)
434+assert(y == 0xc)
435−k=T.testC("\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b,3,4,"\u{78}",16)
435+k=T.testC("\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{35}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b,0x3,0x4,"\u{78}",0x10)
436−assert(a.x == 16 and k == 4)
436+assert(a.x == 0x10 and k == 0x4)
437a[b]="\u{78}\u{75}\u{78}\u{75}"
437a[b]="\u{78}\u{75}\u{78}\u{75}"
438y=T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b)
438y=T.testC("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}\u{2c}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",b)
439assert(y == "\u{78}\u{75}\u{78}\u{75}")
439assert(y == "\u{78}\u{75}\u{78}\u{75}")
440−T.testC("\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}",b,19)
440+T.testC("\u{73}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}",b,0x13)
441−assert(a[b] == 19)
441+assert(a[b] == 0x13)
442do
442do
443−local t = {["\u{5f}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"] = 32}
443+local t = {["\u{5f}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"] = 0x20}
444local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{32}\u{20}\u{5f}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}\u{20}\u{20}",t)
444local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{32}\u{20}\u{5f}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}\u{20}\u{20}",t)
445−assert(a == 32)
445+assert(a == 0x20)
446local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{33}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{5f}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{20}\u{20}")
446local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{33}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{5f}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{20}\u{20}")
447−assert(_012345678901234567890123456789012345678901234567890123456789 == 33)
447+assert(_012345678901234567890123456789012345678901234567890123456789 == 0x21)
448_012345678901234567890123456789012345678901234567890123456789=nil
448_012345678901234567890123456789012345678901234567890123456789=nil
449end
449end
450a={}
450a={}
451t=pack(T.testC("\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",a,nil))
451t=pack(T.testC("\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",a,nil))
452−tcheck(t,{["\u{6e}"] = 1,a})
452+tcheck(t,{["\u{6e}"] = 0x1,a})
453−a={["\u{61}"] = 3}
453+a={["\u{61}"] = 0x3}
454t=pack(T.testC("\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",a,nil))
454t=pack(T.testC("\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",a,nil))
455−tcheck(t,{["\u{6e}"] = 3,a,"\u{61}",3})
455+tcheck(t,{["\u{6e}"] = 0x3,a,"\u{61}",0x3})
456t=pack(T.testC("\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{3b}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",a,nil))
456t=pack(T.testC("\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{3b}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",a,nil))
457−tcheck(t,{["\u{6e}"] = 1,a})
457+tcheck(t,{["\u{6e}"] = 0x1,a})
458do
458do
459local A = T.testC("\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{63}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
459local A = T.testC("\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{63}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
460t,b,c=A("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
460t,b,c=A("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
461−assert(b == 10 and c == 20 and type(t) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
461+assert(b == 0xa and c == 0x14 and type(t) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
462a,b=A("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{55}\u{33}\u{3b}\u{20}\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{55}\u{34}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
462a,b=A("\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{55}\u{33}\u{3b}\u{20}\u{74}\u{6f}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{55}\u{34}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
463−assert(a == nil and b == 0)
463+assert(a == nil and b == 0x0)
464A("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{31}")
464A("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{31}")
465b,c=A("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
465b,c=A("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
466−assert(b == 100 and c == 200)
466+assert(b == 0x64 and c == 0xc8)
467−A("\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{31}",{["\u{78}"] = 1},{["\u{78}"] = 2})
467+A("\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{20}\u{55}\u{31}",{["\u{78}"] = 0x1},{["\u{78}"] = 0x2})
468b,c=A("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
468b,c=A("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}")
469−assert(b.x == 1 and c.x == 2)
469+assert(b.x == 0x1 and c.x == 0x2)
470T.checkmemory()
470T.checkmemory()
471end
471end
472assert(T.testC("\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == true)
472assert(T.testC("\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == true)
473assert(T.testC("\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{55}\u{31}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == true)
473assert(T.testC("\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{55}\u{31}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == true)
474assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == nil)
474assert(T.testC("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}") == nil)
475local f = T.testC("\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{63}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
475local f = T.testC("\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{63}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
476−assert(T.upvalue(f,1) == 10 and T.upvalue(f,2) == 20 and T.upvalue(f,3) == nil)
476+assert(T.upvalue(f,0x1) == 0xa and T.upvalue(f,0x2) == 0x14 and T.upvalue(f,0x3) == nil)
477−T.upvalue(f,2,"\u{78}\u{75}\u{78}\u{75}")
477+T.upvalue(f,0x2,"\u{78}\u{75}\u{78}\u{75}")
478−assert(T.upvalue(f,2) == "\u{78}\u{75}\u{78}\u{75}")
478+assert(T.upvalue(f,0x2) == "\u{78}\u{75}\u{78}\u{75}")
479do
479do
480−local A = "\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{33}\u{30}\u{30}\u{20}\u{6d}\u{73}\u{67}\u{3b}" .. string.rep("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}",255) .. "\u{70}\u{75}\u{73}\u{68}\u{63}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{32}\u{35}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"
480+local A = "\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{33}\u{30}\u{30}\u{20}\u{6d}\u{73}\u{67}\u{3b}" .. string.rep("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}",0xff) .. "\u{70}\u{75}\u{73}\u{68}\u{63}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{32}\u{35}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"
481A=T.testC(A)
481A=T.testC(A)
482−for i = 1, 255
482+for i = 0x1, 0xff
483do
483do
484−assert(A(("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{25}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"):format(i)) == 10)
484+assert(A(("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{25}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"):format(i)) == 0xa)
485end
485end
486assert(A("\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{55}\u{32}\u{35}\u{36}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
486assert(A("\u{69}\u{73}\u{6e}\u{75}\u{6c}\u{6c}\u{20}\u{55}\u{32}\u{35}\u{36}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
487assert(not A("\u{69}\u{73}\u{6e}\u{69}\u{6c}\u{20}\u{55}\u{32}\u{35}\u{36}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
487assert(not A("\u{69}\u{73}\u{6e}\u{69}\u{6c}\u{20}\u{55}\u{32}\u{35}\u{36}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
488end
488end
489−checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}",debug.setuservalue,3,{})
489+checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}",debug.setuservalue,0x3,{})
490checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{69}\u{6c}",debug.setuservalue,nil,{})
490checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{69}\u{6c}",debug.setuservalue,nil,{})
491−checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6c}\u{69}\u{67}\u{68}\u{74}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}",debug.setuservalue,T.pushuserdata(1),{})
491+checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6c}\u{69}\u{67}\u{68}\u{74}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}",debug.setuservalue,T.pushuserdata(0x1),{})
492−local b = T.newuserdata(0,10)
492+local b = T.newuserdata(0x0,0xa)
493−for i = 1, 10
493+for i = 0x1, 0xa
494do
494do
495local v,p = debug.getuservalue(b,i)
495local v,p = debug.getuservalue(b,i)
496assert(v == nil and p)
496assert(v == nil and p)
497end
497end
498do
498do
499−local v,p = debug.getuservalue(b,- 2)
499+local v,p = debug.getuservalue(b,- 0x2)
500assert(v == nil and not p)
500assert(v == nil and not p)
501−local v,p = debug.getuservalue(b,11)
501+local v,p = debug.getuservalue(b,0xb)
502assert(v == nil and not p)
502assert(v == nil and not p)
503end
503end
504local t = {true,false,4.56,print,{},b,"\u{58}\u{59}\u{5a}"}
504local t = {true,false,4.56,print,{},b,"\u{58}\u{59}\u{5a}"}
@@ -511,51 +511,51 @@ do
511local v1,p = debug.getuservalue(b,k)
511local v1,p = debug.getuservalue(b,k)
512assert(v1 == v and p)
512assert(v1 == v and p)
513end
513end
514−assert(not debug.getuservalue(4))
514+assert(not debug.getuservalue(0x4))
515debug.setuservalue(b,function ()
515debug.setuservalue(b,function ()
516−return 10
516+return 0xa
517−end,10)
517+end,0xa)
518collectgarbage()
518collectgarbage()
519−assert(debug.getuservalue(b,10)() == 10)
519+assert(debug.getuservalue(b,0xa)() == 0xa)
520−debug.setuservalue(b,134)
520+debug.setuservalue(b,0x86)
521collectgarbage()
521collectgarbage()
522−assert(debug.getuservalue(b) == 134)
522+assert(debug.getuservalue(b) == 0x86)
523do
523do
524local oldmode = collectgarbage("\u{69}\u{6e}\u{63}\u{72}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{61}\u{6c}")
524local oldmode = collectgarbage("\u{69}\u{6e}\u{63}\u{72}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{61}\u{6c}")
525T.gcstate("\u{61}\u{74}\u{6f}\u{6d}\u{69}\u{63}")
525T.gcstate("\u{61}\u{74}\u{6f}\u{6d}\u{69}\u{63}")
526assert(T.gccolor(b) == "\u{62}\u{6c}\u{61}\u{63}\u{6b}")
526assert(T.gccolor(b) == "\u{62}\u{6c}\u{61}\u{63}\u{6b}")
527−debug.setuservalue(b,{["\u{78}"] = 100})
527+debug.setuservalue(b,{["\u{78}"] = 0x64})
528T.gcstate("\u{70}\u{61}\u{75}\u{73}\u{65}")
528T.gcstate("\u{70}\u{61}\u{75}\u{73}\u{65}")
529−assert(debug.getuservalue(b).x == 100)
529+assert(debug.getuservalue(b).x == 0x64)
530collectgarbage(oldmode)
530collectgarbage(oldmode)
531end
531end
532−for i = 1, 1000
532+for i = 0x1, 0x3e8
533do
533do
534−local bb = T.newuserdata(0,1)
534+local bb = T.newuserdata(0x0,0x1)
535debug.setuservalue(bb,b)
535debug.setuservalue(bb,b)
536b=bb
536b=bb
537end
537end
538collectgarbage()
538collectgarbage()
539−for i = 1, 1000
539+for i = 0x1, 0x3e8
540do
540do
541b=debug.getuservalue(b)
541b=debug.getuservalue(b)
542end
542end
543−assert(debug.getuservalue(b).x == 100)
543+assert(debug.getuservalue(b).x == 0x64)
544b=nil
544b=nil
545local i = T.ref({})
545local i = T.ref({})
546T.unref(i)
546T.unref(i)
547assert(T.ref({}) == i)
547assert(T.ref({}) == i)
548local Arr = {}
548local Arr = {}
549−local Lim = 100
549+local Lim = 0x64
550−for i = 1, Lim
550+for i = 0x1, Lim
551do
551do
552Arr[i]=T.ref({})
552Arr[i]=T.ref({})
553end
553end
554−assert(T.ref(nil) == - 1 and T.getref(- 1) == nil)
554+assert(T.ref(nil) == - 0x1 and T.getref(- 0x1) == nil)
555−T.unref(- 1)
555+T.unref(- 0x1)
556;
556;
557−T.unref(- 1)
557+T.unref(- 0x1)
558−for i = 1, Lim
558+for i = 0x1, Lim
559do
559do
560T.unref(Arr[i])
560T.unref(Arr[i])
561end
561end
@@ -564,26 +564,26 @@ local function printlocks
564local f = T.makeCfunc("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{52}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
564local f = T.makeCfunc("\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{52}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
565local n = f("\u{6e}")
565local n = f("\u{6e}")
566print("\u{6e}",n)
566print("\u{6e}",n)
567−for i = 0, n
567+for i = 0x0, n
568do
568do
569print(i,f(i))
569print(i,f(i))
570end
570end
571end
571end
572−for i = 1, Lim
572+for i = 0x1, Lim
573do
573do
574Arr[i]=T.ref({})
574Arr[i]=T.ref({})
575end
575end
576−for i = 1, Lim, 2
576+for i = 0x1, Lim, 0x2
577do
577do
578T.unref(Arr[i])
578T.unref(Arr[i])
579end
579end
580−assert(type(T.getref(Arr[2])) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
580+assert(type(T.getref(Arr[0x2])) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
581−assert(T.getref(- 1) == nil)
581+assert(T.getref(- 0x1) == nil)
582a=T.ref({})
582a=T.ref({})
583collectgarbage()
583collectgarbage()
584assert(type(T.getref(a)) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
584assert(type(T.getref(a)) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
585local tt = {}
585local tt = {}
586−local cl = {["\u{6e}"] = 0}
586+local cl = {["\u{6e}"] = 0x0}
587A=nil
587A=nil
588;
588;
589B=nil
589B=nil
@@ -591,7 +591,7 @@ local F
591F=function (x)
591F=function (x)
592local udval = T.udataval(x)
592local udval = T.udataval(x)
593table.insert(cl,udval)
593table.insert(cl,udval)
594−local d = T.newuserdata(100)
594+local d = T.newuserdata(0x64)
595d=nil
595d=nil
596assert(debug.getmetatable(x).__gc == F)
596assert(debug.getmetatable(x).__gc == F)
597assert(load("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{2e}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{28}\u{7b}\u{7d}\u{2c}\u{20}\u{7b}\u{7d}\u{29}"))()
597assert(load("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{2e}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{28}\u{7b}\u{7d}\u{2c}\u{20}\u{7b}\u{7d}\u{29}"))()
@@ -604,7 +604,7 @@ debug.getmetatable(A)
604end
604end
605A=x
605A=x
606B=udval
606B=udval
607−return 1,2,3
607+return 0x1,0x2,0x3
608end
608end
609tt.__gc=F
609tt.__gc=F
610do
610do
@@ -614,57 +614,57 @@ collectgarbage()
614;
614;
615local x = collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
615local x = collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
616;
616;
617−local a = T.newuserdata(5001)
617+local a = T.newuserdata(0x1389)
618−assert(T.testC("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a) == 5001)
618+assert(T.testC("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",a) == 0x1389)
619−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= x + 4)
619+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= x + 0x4)
620a=nil
620a=nil
621collectgarbage()
621collectgarbage()
622;
622;
623−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= x + 1)
623+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= x + 0x1)
624x=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
624x=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
625collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
625collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
626−for i = 1, 1000
626+for i = 0x1, 0x3e8
627do
627do
628−T.newuserdata(0)
628+T.newuserdata(0x0)
629end
629end
630−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") > x + 10)
630+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") > x + 0xa)
631collectgarbage()
631collectgarbage()
632−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= x + 1)
632+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= x + 0x1)
633collectgarbage()
633collectgarbage()
634x=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
634x=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
635collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
635collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
636a={["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
636a={["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
637
637
638end}
638end}
639−for i = 1, 1000
639+for i = 0x1, 0x3e8
640do
640do
641−debug.setmetatable(T.newuserdata(0),a)
641+debug.setmetatable(T.newuserdata(0x0),a)
642end
642end
643−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= x + 10)
643+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= x + 0xa)
644collectgarbage()
644collectgarbage()
645−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= x + 10)
645+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= x + 0xa)
646collectgarbage()
646collectgarbage()
647−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= x + 1)
647+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= x + 0x1)
648collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
648collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
649end
649end
650collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
650collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
651−a=T.newuserdata(0)
651+a=T.newuserdata(0x0)
652;
652;
653debug.setmetatable(a,tt)
653debug.setmetatable(a,tt)
654;
654;
655local na = T.udataval(a)
655local na = T.udataval(a)
656−b=T.newuserdata(0)
656+b=T.newuserdata(0x0)
657;
657;
658debug.setmetatable(b,tt)
658debug.setmetatable(b,tt)
659;
659;
660local nb = T.udataval(b)
660local nb = T.udataval(b)
661−c=T.newuserdata(0)
661+c=T.newuserdata(0x0)
662;
662;
663debug.setmetatable(c,tt)
663debug.setmetatable(c,tt)
664;
664;
665local nc = T.udataval(c)
665local nc = T.udataval(c)
666−x=T.newuserdata(4)
666+x=T.newuserdata(0x4)
667−y=T.newuserdata(0)
667+y=T.newuserdata(0x0)
668checkerr("\u{46}\u{49}\u{4c}\u{45}\u{25}\u{2a}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{2c}\u{20}\u{67}\u{6f}\u{74}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}",io.input,a)
668checkerr("\u{46}\u{49}\u{4c}\u{45}\u{25}\u{2a}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{2c}\u{20}\u{67}\u{6f}\u{74}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}",io.input,a)
669checkerr("\u{46}\u{49}\u{4c}\u{45}\u{25}\u{2a}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{2c}\u{20}\u{67}\u{6f}\u{74}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}",io.input,x)
669checkerr("\u{46}\u{49}\u{4c}\u{45}\u{25}\u{2a}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{2c}\u{20}\u{67}\u{6f}\u{74}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}",io.input,x)
670assert(debug.getmetatable(x) == nil and debug.getmetatable(y) == nil)
670assert(debug.getmetatable(x) == nil and debug.getmetatable(y) == nil)
@@ -675,7 +675,7 @@ local e = T.ref(b)
675local f = T.ref(c)
675local f = T.ref(c)
676;
676;
677t={T.getref(d),T.getref(e),T.getref(f)}
677t={T.getref(d),T.getref(e),T.getref(f)}
678−assert(t[1] == a and t[2] == b and t[3] == c)
678+assert(t[0x1] == a and t[0x2] == b and t[0x3] == c)
679t=nil
679t=nil
680;
680;
681a=nil
681a=nil
@@ -686,7 +686,7 @@ T.unref(e)
686;
686;
687T.unref(f)
687T.unref(f)
688collectgarbage()
688collectgarbage()
689−assert(# cl == 1 and cl[1] == nc)
689+assert(# cl == 0x1 and cl[0x1] == nc)
690x=T.getref(d)
690x=T.getref(d)
691assert(type(x) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}" and debug.getmetatable(x) == tt)
691assert(type(x) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}" and debug.getmetatable(x) == tt)
692x=nil
692x=nil
@@ -696,17 +696,17 @@ A=nil
696b=nil
696b=nil
697T.unref(d)
697T.unref(d)
698;
698;
699−local n5 = T.newuserdata(0)
699+local n5 = T.newuserdata(0x0)
700debug.setmetatable(n5,{["\u{5f}\u{5f}\u{67}\u{63}"] = F})
700debug.setmetatable(n5,{["\u{5f}\u{5f}\u{67}\u{63}"] = F})
701n5=T.udataval(n5)
701n5=T.udataval(n5)
702collectgarbage()
702collectgarbage()
703−assert(# cl == 4)
703+assert(# cl == 0x4)
704−assert(cl[2] == n5 and cl[3] == nb and cl[4] == na)
704+assert(cl[0x2] == n5 and cl[0x3] == nb and cl[0x4] == na)
705collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
705collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
706a,na={},{}
706a,na={},{}
707−for i = 30, 1, - 1
707+for i = 0x1e, 0x1, - 0x1
708do
708do
709−a[i]=T.newuserdata(0)
709+a[i]=T.newuserdata(0x0)
710debug.setmetatable(a[i],{["\u{5f}\u{5f}\u{67}\u{63}"] = F})
710debug.setmetatable(a[i],{["\u{5f}\u{5f}\u{67}\u{63}"] = F})
711na[i]=T.udataval(a[i])
711na[i]=T.udataval(a[i])
712end
712end
@@ -714,37 +714,37 @@ cl={}
714a=nil
714a=nil
715;
715;
716collectgarbage()
716collectgarbage()
717−assert(# cl == 30)
717+assert(# cl == 0x1e)
718−for i = 1, 30
718+for i = 0x1, 0x1e
719do
719do
720assert(cl[i] == na[i])
720assert(cl[i] == na[i])
721end
721end
722na=nil
722na=nil
723−for i = 2, Lim, 2
723+for i = 0x2, Lim, 0x2
724do
724do
725T.unref(Arr[i])
725T.unref(Arr[i])
726end
726end
727−x=T.newuserdata(41)
727+x=T.newuserdata(0x29)
728;
728;
729debug.setmetatable(x,{["\u{5f}\u{5f}\u{67}\u{63}"] = F})
729debug.setmetatable(x,{["\u{5f}\u{5f}\u{67}\u{63}"] = F})
730−assert(T.testC("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",x) == 41)
730+assert(T.testC("\u{6f}\u{62}\u{6a}\u{73}\u{69}\u{7a}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",x) == 0x29)
731cl={}
731cl={}
732−a={[x] = 1}
732+a={[x] = 0x1}
733x=T.udataval(x)
733x=T.udataval(x)
734collectgarbage()
734collectgarbage()
735−assert(# cl == 0)
735+assert(# cl == 0x0)
736for n in pairs(a)
736for n in pairs(a)
737do
737do
738a[n]=undef
738a[n]=undef
739end
739end
740collectgarbage()
740collectgarbage()
741−assert(# cl == 1 and cl[1] == x)
741+assert(# cl == 0x1 and cl[0x1] == x)
742−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{34}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",print,1,print,20))
742+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{34}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",print,0x1,print,0x14))
743assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{33}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{61}\u{6c}\u{6f}","\u{61}\u{6c}\u{6f}"))
743assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{33}\u{20}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}","\u{61}\u{6c}\u{6f}","\u{61}\u{6c}\u{6f}"))
744assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",nil,nil))
744assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",nil,nil))
745assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",{},{}))
745assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",{},{}))
746assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
746assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
747−assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",3))
747+assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",0x3))
748do
748do
749local map = {}
749local map = {}
750local t = {["\u{5f}\u{5f}\u{65}\u{71}"] = function (a,b)
750local t = {["\u{5f}\u{5f}\u{65}\u{71}"] = function (a,b)
@@ -752,58 +752,58 @@ return map[a] == map[b]
752end}
752end}
753local function f
753local function f
754(x)
754(x)
755−local u = T.newuserdata(0)
755+local u = T.newuserdata(0x0)
756debug.setmetatable(u,t)
756debug.setmetatable(u,t)
757map[u]=x
757map[u]=x
758return u
758return u
759end
759end
760−assert(f(10) == f(10))
760+assert(f(0xa) == f(0xa))
761−assert(f(10) ~= f(11))
761+assert(f(0xa) ~= f(0xb))
762−assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",f(10),f(10)))
762+assert(T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",f(0xa),f(0xa)))
763−assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",f(10),f(20)))
763+assert(not T.testC("\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{65}\u{20}\u{45}\u{51}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",f(0xa),f(0x14)))
764t.__eq=nil
764t.__eq=nil
765−assert(f(10) ~= f(10))
765+assert(f(0xa) ~= f(0xa))
766end
766end
767print("\u{2b}")
767print("\u{2b}")
768_G.TT={}
768_G.TT={}
769−T.sethook("\u{20}\u{20}\u{23}\u{20}\u{73}\u{65}\u{74}\u{20}\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{68}\u{6f}\u{6f}\u{6b}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}\u{33}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{20}\u{68}\u{6f}\u{6f}\u{6b}\u{73}\u{a}\u{20}\u{20}\u{73}\u{65}\u{74}\u{68}\u{6f}\u{6f}\u{6b}\u{20}\u{34}\u{20}\u{30}\u{20}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{54}\u{54}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{61}\u{70}\u{70}\u{65}\u{6e}\u{64}\u{20}\u{2d}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{61}\u{70}\u{70}\u{65}\u{6e}\u{64}\u{20}\u{2d}\u{32}\u{a}\u{20}\u{20}\u{27}","\u{63}",3)
769+T.sethook("\u{20}\u{20}\u{23}\u{20}\u{73}\u{65}\u{74}\u{20}\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{68}\u{6f}\u{6f}\u{6b}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}\u{33}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{20}\u{68}\u{6f}\u{6f}\u{6b}\u{73}\u{a}\u{20}\u{20}\u{73}\u{65}\u{74}\u{68}\u{6f}\u{6f}\u{6b}\u{20}\u{34}\u{20}\u{30}\u{20}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{54}\u{54}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{33}\u{3b}\u{20}\u{61}\u{70}\u{70}\u{65}\u{6e}\u{64}\u{20}\u{2d}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{61}\u{70}\u{70}\u{65}\u{6e}\u{64}\u{20}\u{2d}\u{32}\u{a}\u{20}\u{20}\u{27}","\u{63}",0x3)
770−local a = 1
770+local a = 0x1
771−a=1
771+a=0x1
772−a=1
772+a=0x1
773−a=1
773+a=0x1
774−a=1
774+a=0x1
775debug.sethook()
775debug.sethook()
776local t = _G.TT
776local t = _G.TT
777−assert(t[1] == "\u{6c}\u{69}\u{6e}\u{65}")
777+assert(t[0x1] == "\u{6c}\u{69}\u{6e}\u{65}")
778−local line = t[2]
778+local line = t[0x2]
779−assert(t[3] == "\u{6c}\u{69}\u{6e}\u{65}" and t[4] == line + 1)
779+assert(t[0x3] == "\u{6c}\u{69}\u{6e}\u{65}" and t[0x4] == line + 0x1)
780−assert(t[5] == "\u{6c}\u{69}\u{6e}\u{65}" and t[6] == line + 2)
780+assert(t[0x5] == "\u{6c}\u{69}\u{6e}\u{65}" and t[0x6] == line + 0x2)
781−assert(t[7] == nil)
781+assert(t[0x7] == nil)
782_G.TT=nil
782_G.TT=nil
783do
783do
784warn("\u{40}\u{6f}\u{66}\u{66}")
784warn("\u{40}\u{6f}\u{66}\u{66}")
785collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
785collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
786local a = {}
786local a = {}
787−for i = 1, 20
787+for i = 0x1, 0x14
788do
788do
789a[i]=T.newuserdata(i)
789a[i]=T.newuserdata(i)
790end
790end
791−for i = 1, 20, 2
791+for i = 0x1, 0x14, 0x2
792do
792do
793debug.setmetatable(a[i],{["\u{5f}\u{5f}\u{67}\u{63}"] = function (x)
793debug.setmetatable(a[i],{["\u{5f}\u{5f}\u{67}\u{63}"] = function (x)
794error("\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{69}\u{6e}\u{20}\u{67}\u{63}")
794error("\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{69}\u{6e}\u{20}\u{67}\u{63}")
795end})
795end})
796end
796end
797−for i = 2, 20, 2
797+for i = 0x2, 0x14, 0x2
798do
798do
799debug.setmetatable(a[i],{["\u{5f}\u{5f}\u{67}\u{63}"] = function (x)
799debug.setmetatable(a[i],{["\u{5f}\u{5f}\u{67}\u{63}"] = function (x)
800load("\u{41}\u{3d}\u{41}\u{2b}\u{31}")()
800load("\u{41}\u{3d}\u{41}\u{2b}\u{31}")()
801end})
801end})
802end
802end
803a=nil
803a=nil
804−_G.A=0
804+_G.A=0x0
805collectgarbage()
805collectgarbage()
806−assert(A == 10)
806+assert(A == 0xa)
807collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
807collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
808warn("\u{40}\u{6f}\u{6e}")
808warn("\u{40}\u{6f}\u{6e}")
809end
809end
@@ -811,42 +811,42 @@ _G.A=nil
811do
811do
812local a = {}
812local a = {}
813;
813;
814−local lim = 30
814+local lim = 0x1e
815−for i = 0, lim
815+for i = 0x0, lim
816do
816do
817a[i]=T.pushuserdata(i)
817a[i]=T.pushuserdata(i)
818end
818end
819−for i = 0, lim
819+for i = 0x0, lim
820do
820do
821assert(T.udataval(a[i]) == i)
821assert(T.udataval(a[i]) == i)
822end
822end
823−for i = 0, lim
823+for i = 0x0, lim
824do
824do
825assert(T.pushuserdata(i) == a[i])
825assert(T.pushuserdata(i) == a[i])
826end
826end
827−for i = 0, lim
827+for i = 0x0, lim
828do
828do
829a[a[i]]=i
829a[a[i]]=i
830end
830end
831−for i = 0, lim
831+for i = 0x0, lim
832do
832do
833a[T.pushuserdata(i)]=i
833a[T.pushuserdata(i)]=i
834end
834end
835−assert(type(tostring(a[1])) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
835+assert(type(tostring(a[0x1])) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
836end
836end
837T.closestate(T.newstate())
837T.closestate(T.newstate())
838;
838;
839L1=T.newstate()
839L1=T.newstate()
840assert(L1)
840assert(L1)
841assert(T.doremote(L1,"\u{58}\u{3d}\u{27}\u{61}\u{27}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{61}\u{27}") == "\u{61}")
841assert(T.doremote(L1,"\u{58}\u{3d}\u{27}\u{61}\u{27}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{61}\u{27}") == "\u{61}")
842−assert(# pack(T.doremote(L1,"\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{61}\u{6c}\u{6f}\u{27}\u{2c}\u{20}\u{33}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{20}\u{66}\u{28}\u{29}")) == 0)
842+assert(# pack(T.doremote(L1,"\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{61}\u{6c}\u{6f}\u{27}\u{2c}\u{20}\u{33}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{20}\u{66}\u{28}\u{29}")) == 0x0)
843a,b=T.doremote(L1,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{28}\u{29}")
843a,b=T.doremote(L1,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{28}\u{29}")
844assert(a == "\u{61}\u{6c}\u{6f}" and b == "\u{33}")
844assert(a == "\u{61}\u{6c}\u{6f}" and b == "\u{33}")
845T.doremote(L1,"\u{5f}\u{45}\u{52}\u{52}\u{4f}\u{52}\u{4d}\u{45}\u{53}\u{53}\u{41}\u{47}\u{45}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}")
845T.doremote(L1,"\u{5f}\u{45}\u{52}\u{52}\u{4f}\u{52}\u{4d}\u{45}\u{53}\u{53}\u{41}\u{47}\u{45}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}")
846a,b,c=T.doremote(L1,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}")
846a,b,c=T.doremote(L1,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}")
847−assert(a == nil and c == 2)
847+assert(a == nil and c == 0x2)
848a,b,c=T.doremote(L1,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{2b}")
848a,b,c=T.doremote(L1,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{2b}")
849−assert(a == nil and c == 3 and type(b) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
849+assert(a == nil and c == 0x3 and type(b) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
850T.loadlib(L1)
850T.loadlib(L1)
851a,b,c=T.doremote(L1,"\u{20}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{5f}\u{47}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{20}\u{3d}\u{3d}\u{20}\u{5f}\u{47}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{28}\u{22}\u{5f}\u{47}\u{22}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{61}\u{29}\u{a}\u{20}\u{20}\u{69}\u{6f}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{69}\u{6f}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{69}\u{6f}\u{2e}\u{72}\u{65}\u{61}\u{64}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{28}\u{22}\u{69}\u{6f}\u{22}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{69}\u{6f}\u{29}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{61}\u{2e}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{61}\u{2e}\u{67}\u{65}\u{74}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{6d}\u{61}\u{74}\u{68}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{61}\u{2e}\u{73}\u{69}\u{6e}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{73}\u{75}\u{62}\u{28}\u{27}\u{6f}\u{6b}\u{69}\u{6e}\u{61}\u{6d}\u{61}\u{27}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{32}\u{29}\u{a}")
851a,b,c=T.doremote(L1,"\u{20}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{5f}\u{47}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{20}\u{3d}\u{3d}\u{20}\u{5f}\u{47}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{28}\u{22}\u{5f}\u{47}\u{22}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{61}\u{29}\u{a}\u{20}\u{20}\u{69}\u{6f}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{69}\u{6f}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{69}\u{6f}\u{2e}\u{72}\u{65}\u{61}\u{64}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{28}\u{22}\u{69}\u{6f}\u{22}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{69}\u{6f}\u{29}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{61}\u{2e}\u{69}\u{6e}\u{73}\u{65}\u{72}\u{74}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{61}\u{2e}\u{67}\u{65}\u{74}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{6d}\u{61}\u{74}\u{68}\u{27}\u{3b}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{79}\u{70}\u{65}\u{28}\u{61}\u{2e}\u{73}\u{69}\u{6e}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{22}\u{29}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{73}\u{75}\u{62}\u{28}\u{27}\u{6f}\u{6b}\u{69}\u{6e}\u{61}\u{6d}\u{61}\u{27}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{32}\u{29}\u{a}")
852assert(a == "\u{6f}\u{6b}")
852assert(a == "\u{6f}\u{6b}")
@@ -865,23 +865,23 @@ do
865local openresource = {}
865local openresource = {}
866local function newresource
866local function newresource
867()
867()
868−local x = setmetatable({10},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function (y)
868+local x = setmetatable({0xa},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function (y)
869assert(openresource[# openresource] == y)
869assert(openresource[# openresource] == y)
870openresource[# openresource]=nil
870openresource[# openresource]=nil
871−y[1]=y[1] + 1
871+y[0x1]=y[0x1] + 0x1
872end})
872end})
873−openresource[# openresource + 1]=x
873+openresource[# openresource + 0x1]=x
874return x
874return x
875end
875end
876local a,b = T.testC("\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{69}\u{6c}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{32}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{28}\u{77}\u{69}\u{6c}\u{6c}\u{20}\u{62}\u{65}\u{20}\u{69}\u{67}\u{6e}\u{6f}\u{72}\u{65}\u{64}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}\u{20}\u{20}",newresource)
876local a,b = T.testC("\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{69}\u{6c}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{32}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{28}\u{77}\u{69}\u{6c}\u{6c}\u{20}\u{62}\u{65}\u{20}\u{69}\u{67}\u{6e}\u{6f}\u{72}\u{65}\u{64}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}\u{20}\u{20}",newresource)
877−assert(a[1] == 11 and b == nil)
877+assert(a[0x1] == 0xb and b == nil)
878−assert(# openresource == 0)
878+assert(# openresource == 0x0)
879local a = {T.testC("\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}\u{20}\u{20}",newresource)}
879local a = {T.testC("\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}\u{20}\u{20}",newresource)}
880−assert(type(a[1]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and a[2][1] == 11)
880+assert(type(a[0x1]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and a[0x2][0x1] == 0xb)
881−assert(# openresource == 0)
881+assert(# openresource == 0x0)
882local a,b = pcall(T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{20}\u{69}\u{73}\u{20}\u{74}\u{68}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{a}\u{20}\u{20}"),newresource)
882local a,b = pcall(T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{20}\u{69}\u{73}\u{20}\u{74}\u{68}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{a}\u{20}\u{20}"),newresource)
883−assert(a == false and b[1] == 11)
883+assert(a == false and b[0x1] == 0xb)
884−assert(# openresource == 0)
884+assert(# openresource == 0x0)
885local a,b = pcall(T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{6e}\u{65}\u{77}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{28}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{72}\u{61}\u{69}\u{73}\u{65}\u{20}\u{61}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{61}\u{62}\u{6f}\u{72}\u{74}\u{20}\u{20}\u{23}\u{20}\u{77}\u{69}\u{6c}\u{6c}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{65}\u{78}\u{65}\u{63}\u{75}\u{74}\u{65}\u{64}\u{a}\u{20}\u{20}"))
885local a,b = pcall(T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{6e}\u{65}\u{77}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{28}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{72}\u{61}\u{69}\u{73}\u{65}\u{20}\u{61}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{61}\u{62}\u{6f}\u{72}\u{74}\u{20}\u{20}\u{23}\u{20}\u{77}\u{69}\u{6c}\u{6c}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{65}\u{78}\u{65}\u{63}\u{75}\u{74}\u{65}\u{64}\u{a}\u{20}\u{20}"))
886assert(a == false and string.find(b,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}"))
886assert(a == false and string.find(b,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}"))
887local function check
887local function check
@@ -890,9 +890,9 @@ assert(# openresource == n)
890end
890end
891_ENV.xxx=true
891_ENV.xxx=true
892local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{32}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{74}\u{77}\u{6f}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{73}\u{6c}\u{6f}\u{74}\u{20}\u{2d}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{6f}\u{6e}\u{65}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{73}\u{6c}\u{6f}\u{74}\u{20}\u{34}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{22}\u{78}\u{78}\u{78}\u{22}\u{20}\u{20}\u{23}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{6f}\u{70}\u{2e}\u{20}\u{65}\u{72}\u{61}\u{73}\u{65}\u{64}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{6c}\u{6f}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{20}\u{66}\u{72}\u{6f}\u{6d}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{2a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{a}\u{20}\u{20}",newresource,check)
892local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{32}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{74}\u{77}\u{6f}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{73}\u{6c}\u{6f}\u{74}\u{20}\u{2d}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{6f}\u{6e}\u{65}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{73}\u{6c}\u{6f}\u{74}\u{20}\u{34}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{22}\u{78}\u{78}\u{78}\u{22}\u{20}\u{20}\u{23}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{6f}\u{70}\u{2e}\u{20}\u{65}\u{72}\u{61}\u{73}\u{65}\u{64}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{6c}\u{6f}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{20}\u{66}\u{72}\u{6f}\u{6d}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{2a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{a}\u{20}\u{20}",newresource,check)
893−assert(a == 3 and _ENV.xxx == nil)
893+assert(a == 0x3 and _ENV.xxx == nil)
894local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{32}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{74}\u{77}\u{6f}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{6f}\u{6e}\u{65}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{20}\u{66}\u{72}\u{6f}\u{6d}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{30}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{6e}\u{6f}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{2a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{a}\u{20}\u{20}",newresource,check)
894local a = T.testC("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{4e}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{3b}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{20}\u{23}\u{20}\u{6d}\u{61}\u{72}\u{6b}\u{20}\u{69}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{32}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{74}\u{77}\u{6f}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{6f}\u{6e}\u{65}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{52}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{20}\u{66}\u{72}\u{6f}\u{6d}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{33}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{30}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{68}\u{65}\u{72}\u{65}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{65}\u{20}\u{6e}\u{6f}\u{20}\u{6f}\u{70}\u{65}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{6f}\u{75}\u{72}\u{63}\u{65}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{31}\u{20}\u{30}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{3a}\u{20}\u{53}\u{2c}\u{20}\u{4e}\u{52}\u{2c}\u{20}\u{43}\u{48}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{2a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{a}\u{20}\u{20}",newresource,check)
895−assert(a == 3)
895+assert(a == 0x3)
896local a,b = pcall(T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{a}\u{20}\u{20}"))
896local a,b = pcall(T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{33}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{2d}\u{31}\u{a}\u{20}\u{20}"))
897assert(not a and string.find(b,"\u{28}\u{43}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}"))
897assert(not a and string.find(b,"\u{28}\u{43}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}"))
898end
898end
@@ -900,7 +900,7 @@ print("\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{2d}\u{61}\u{6c}\u{6c}\u{6f}\u{63}\
900checkerr("\u{62}\u{6c}\u{6f}\u{63}\u{6b}\u{20}\u{74}\u{6f}\u{6f}\u{20}\u{62}\u{69}\u{67}",T.newuserdata,math.maxinteger)
900checkerr("\u{62}\u{6c}\u{6f}\u{63}\u{6b}\u{20}\u{74}\u{6f}\u{6f}\u{20}\u{62}\u{69}\u{67}",T.newuserdata,math.maxinteger)
901collectgarbage()
901collectgarbage()
902local f = load("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3d}\u{7b}\u{7d}\u{3b}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{20}\u{64}\u{6f}\u{20}\u{61}\u{5b}\u{69}\u{5d}\u{3d}\u{69}\u{20}\u{65}\u{6e}\u{64}")
902local f = load("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3d}\u{7b}\u{7d}\u{3b}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{20}\u{64}\u{6f}\u{20}\u{61}\u{5b}\u{69}\u{5d}\u{3d}\u{69}\u{20}\u{65}\u{6e}\u{64}")
903−T.alloccount(10)
903+T.alloccount(0xa)
904checkerr(MEMERRMSG,f)
904checkerr(MEMERRMSG,f)
905T.alloccount()
905T.alloccount()
906local function testbytes
906local function testbytes
@@ -915,14 +915,14 @@ collectgarbage()
915collectgarbage()
915collectgarbage()
916T.totalmem(M)
916T.totalmem(M)
917a,b=T.testC("\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",f)
917a,b=T.testC("\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",f)
918−T.totalmem(0)
918+T.totalmem(0x0)
919if a and b == "\u{4f}\u{4b}" then
919if a and b == "\u{4f}\u{4b}" then
920break
920break
921end
921end
922if b ~= "\u{4f}\u{4b}" and b ~= MEMERRMSG then
922if b ~= "\u{4f}\u{4b}" and b ~= MEMERRMSG then
923−error(a,0)
923+error(a,0x0)
924end
924end
925−M=M + 7
925+M=M + 0x7
926end
926end
927print(string.format("\u{6d}\u{69}\u{6e}\u{69}\u{6d}\u{75}\u{6d}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{25}\u{73}\u{3a}\u{20}\u{25}\u{64}\u{20}\u{62}\u{79}\u{74}\u{65}\u{73}",s,M - oldM))
927print(string.format("\u{6d}\u{69}\u{6e}\u{69}\u{6d}\u{75}\u{6d}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{25}\u{73}\u{3a}\u{20}\u{25}\u{64}\u{20}\u{62}\u{79}\u{74}\u{65}\u{73}",s,M - oldM))
928return a
928return a
@@ -930,7 +930,7 @@ end
930local function testalloc
930local function testalloc
931(s,f)
931(s,f)
932collectgarbage()
932collectgarbage()
933−local M = 0
933+local M = 0x0
934local a,b = nil
934local a,b = nil
935while true do
935while true do
936collectgarbage()
936collectgarbage()
@@ -943,9 +943,9 @@ if a and b == "\u{4f}\u{4b}" then
943break
943break
944end
944end
945if b ~= "\u{4f}\u{4b}" and b ~= MEMERRMSG then
945if b ~= "\u{4f}\u{4b}" and b ~= MEMERRMSG then
946−error(a,0)
946+error(a,0x0)
947end
947end
948−M=M + 1
948+M=M + 0x1
949end
949end
950print(string.format("\u{6d}\u{69}\u{6e}\u{69}\u{6d}\u{75}\u{6d}\u{20}\u{61}\u{6c}\u{6c}\u{6f}\u{63}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{25}\u{73}\u{3a}\u{20}\u{25}\u{64}\u{20}\u{61}\u{6c}\u{6c}\u{6f}\u{63}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}",s,M))
950print(string.format("\u{6d}\u{69}\u{6e}\u{69}\u{6d}\u{75}\u{6d}\u{20}\u{61}\u{6c}\u{6c}\u{6f}\u{63}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{25}\u{73}\u{3a}\u{20}\u{25}\u{64}\u{20}\u{61}\u{6c}\u{6c}\u{6f}\u{63}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}",s,M))
951return a
951return a
@@ -956,9 +956,9 @@ testalloc(s,f)
956return testbytes(s,f)
956return testbytes(s,f)
957end
957end
958b=testamem("\u{64}\u{6f}\u{69}\u{6e}\u{67}\u{20}\u{6e}\u{6f}\u{74}\u{68}\u{69}\u{6e}\u{67}",function ()
958b=testamem("\u{64}\u{6f}\u{69}\u{6e}\u{67}\u{20}\u{6e}\u{6f}\u{74}\u{68}\u{69}\u{6e}\u{67}",function ()
959−return 10
959+return 0xa
960end)
960end)
961−assert(b == 10)
961+assert(b == 0xa)
962testamem("\u{73}\u{74}\u{61}\u{74}\u{65}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6f}\u{6e}",function ()
962testamem("\u{73}\u{74}\u{61}\u{74}\u{65}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6f}\u{6e}",function ()
963local st = T.newstate()
963local st = T.newstate()
964if st then
964if st then
@@ -990,25 +990,25 @@ local mt = T.testC("\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}
990assert(type(mt) == "\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}" and coroutine.running() == mt)
990assert(type(mt) == "\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}" and coroutine.running() == mt)
991local function expand
991local function expand
992(n,s)
992(n,s)
993−if n == 0 then
993+if n == 0x0 then
994return ""
994return ""
995end
995end
996local e = string.rep("\u{3d}",n)
996local e = string.rep("\u{3d}",n)
997−return string.format("\u{54}\u{2e}\u{64}\u{6f}\u{6f}\u{6e}\u{6e}\u{65}\u{77}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{28}\u{5b}\u{25}\u{73}\u{5b}\u{20}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{67}\u{61}\u{72}\u{62}\u{61}\u{67}\u{65}\u{28}\u{29}\u{3b}\u{20}\u{25}\u{73}\u{5d}\u{25}\u{73}\u{5d}\u{29}\u{a}",e,s,expand(n - 1,s),e)
997+return string.format("\u{54}\u{2e}\u{64}\u{6f}\u{6f}\u{6e}\u{6e}\u{65}\u{77}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{28}\u{5b}\u{25}\u{73}\u{5b}\u{20}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{67}\u{61}\u{72}\u{62}\u{61}\u{67}\u{65}\u{28}\u{29}\u{3b}\u{20}\u{25}\u{73}\u{5d}\u{25}\u{73}\u{5d}\u{29}\u{a}",e,s,expand(n - 0x1,s),e)
998end
998end
999−G=0
999+G=0x0
1000;
1000;
1001collectgarbage()
1001collectgarbage()
1002;
1002;
1003a=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
1003a=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
1004−load(expand(20,"\u{47}\u{3d}\u{47}\u{2b}\u{31}"))()
1004+load(expand(0x14,"\u{47}\u{3d}\u{47}\u{2b}\u{31}"))()
1005−assert(G == 20)
1005+assert(G == 0x14)
1006;
1006;
1007collectgarbage()
1007collectgarbage()
1008;
1008;
1009G=nil
1009G=nil
1010testamem("\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{64}\u{65}\u{20}\u{6f}\u{6e}\u{20}\u{6e}\u{65}\u{77}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}",function ()
1010testamem("\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{64}\u{65}\u{20}\u{6f}\u{6e}\u{20}\u{6e}\u{65}\u{77}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}",function ()
1011−return T.doonnewstack("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{3d}\u{31}") == 0
1011+return T.doonnewstack("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{3d}\u{31}") == 0x0
1012end)
1012end)
1013testamem("\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",function ()
1013testamem("\u{6c}\u{6f}\u{61}\u{64}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",function ()
1014return load("\u{78}\u{3d}\u{31}")
1014return load("\u{78}\u{3d}\u{31}")
@@ -1048,8 +1048,8 @@ return not loadfile("\u{6e}\u{6f}\u{6d}\u{65}\u{6e}\u{61}\u{6f}\u{65}\u{78}\u{69
1048end)
1048end)
1049assert(os.remove(t))
1049assert(os.remove(t))
1050testamem("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6f}\u{6e}",function ()
1050testamem("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6f}\u{6e}",function ()
1051−local a,lim = {},10
1051+local a,lim = {},0xa
1052−for i = 1, lim
1052+for i = 0x1, lim
1053do
1053do
1054a[i]=i
1054a[i]=i
1055;
1055;
@@ -1058,10 +1058,10 @@ end
1058return (type(a[lim .. "\u{61}"]) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and a[lim] == lim)
1058return (type(a[lim .. "\u{61}"]) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and a[lim] == lim)
1059end)
1059end)
1060testamem("\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{6f}\u{72}\u{73}",function ()
1060testamem("\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{6f}\u{72}\u{73}",function ()
1061−local a = {10,20,30,40,50,["\u{61}"] = 1,["\u{62}"] = 2,["\u{63}"] = 3,["\u{64}"] = 4,["\u{65}"] = 5}
1061+local a = {0xa,0x14,0x1e,0x28,0x32,["\u{61}"] = 0x1,["\u{62}"] = 0x2,["\u{63}"] = 0x3,["\u{64}"] = 0x4,["\u{65}"] = 0x5}
1062−return (type(a) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and a.e == 5)
1062+return (type(a) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and a.e == 0x5)
1063end)
1063end)
1064−local a = 1
1064+local a = 0x1
1065local close = nil
1065local close = nil
1066testamem("\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6f}\u{6e}",function ()
1066testamem("\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6f}\u{6e}",function ()
1067function close(b)
1067function close(b)
@@ -1069,44 +1069,44 @@ return function (x)
1069return b + x
1069return b + x
1070end
1070end
1071end
1071end
1072−return (close(2)(4) == 6)
1072+return (close(0x2)(0x4) == 0x6)
1073end)
1073end)
1074testamem("\u{75}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}",function ()
1074testamem("\u{75}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}",function ()
1075local a = coroutine.wrap(function ()
1075local a = coroutine.wrap(function ()
1076−coroutine.yield(string.rep("\u{61}",10))
1076+coroutine.yield(string.rep("\u{61}",0xa))
1077return {}
1077return {}
1078end)
1078end)
1079−assert(string.len(a()) == 10)
1079+assert(string.len(a()) == 0xa)
1080return a()
1080return a()
1081end)
1081end)
1082do
1082do
1083−local lim = 100
1083+local lim = 0x64
1084local a = {}
1084local a = {}
1085;
1085;
1086−for i = 1, lim
1086+for i = 0x1, lim
1087do
1087do
1088a[i]="\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
1088a[i]="\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
1089end
1089end
1090testamem("\u{61}\u{75}\u{78}\u{69}\u{6c}\u{69}\u{61}\u{72}\u{79}\u{20}\u{62}\u{75}\u{66}\u{66}\u{65}\u{72}",function ()
1090testamem("\u{61}\u{75}\u{78}\u{69}\u{6c}\u{69}\u{61}\u{72}\u{79}\u{20}\u{62}\u{75}\u{66}\u{66}\u{65}\u{72}",function ()
1091−return (# table.concat(a,"\u{2c}") == 20 * lim + lim - 1)
1091+return (# table.concat(a,"\u{2c}") == 0x14 * lim + lim - 0x1)
1092end)
1092end)
1093end
1093end
1094testamem("\u{67}\u{72}\u{6f}\u{77}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}",function ()
1094testamem("\u{67}\u{72}\u{6f}\u{77}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}",function ()
1095local function foo
1095local function foo
1096(n)
1096(n)
1097−if n == 0 then
1097+if n == 0x0 then
1098−return 1
1098+return 0x1
1099else
1099else
1100−return 1 + foo(n - 1)
1100+return 0x1 + foo(n - 0x1)
1101end
1101end
1102end
1102end
1103−return foo(100)
1103+return foo(0x64)
1104end)
1104end)
1105do
1105do
1106local res = T.testC("\u{72}\u{61}\u{77}\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{35}\u{30}\u{30}\u{30}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
1106local res = T.testC("\u{72}\u{61}\u{77}\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{35}\u{30}\u{30}\u{30}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
1107assert(res == false)
1107assert(res == false)
1108local L = T.newstate()
1108local L = T.newstate()
1109−T.alloccount(0)
1109+T.alloccount(0x0)
1110res=T.testC(L,"\u{72}\u{61}\u{77}\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{35}\u{30}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
1110res=T.testC(L,"\u{72}\u{61}\u{77}\u{63}\u{68}\u{65}\u{63}\u{6b}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{35}\u{30}\u{30}\u{30}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}")
1111T.alloccount()
1111T.alloccount()
1112T.closestate(L)
1112T.closestate(L)
@@ -1114,7 +1114,7 @@ assert(res == false)
1114end
1114end
1115do
1115do
1116local L = T.newstate()
1116local L = T.newstate()
1117−T.alloccount(0)
1117+T.alloccount(0x0)
1118T.closestate(L)
1118T.closestate(L)
1119T.alloccount()
1119T.alloccount()
1120end
1120end
@@ -1129,7 +1129,7 @@ print("\u{2b}")
1129local function gsub
1129local function gsub
1130(a,b,c)
1130(a,b,c)
1131a,b=T.testC("\u{67}\u{73}\u{75}\u{62}\u{20}\u{32}\u{20}\u{33}\u{20}\u{34}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a,b,c)
1131a,b=T.testC("\u{67}\u{73}\u{75}\u{62}\u{20}\u{32}\u{20}\u{33}\u{20}\u{34}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",a,b,c)
1132−assert(b == 5)
1132+assert(b == 0x5)
1133return a
1133return a
1134end
1134end
1135assert(gsub("\u{61}\u{6c}\u{6f}\u{2e}\u{61}\u{6c}\u{6f}\u{2e}\u{75}\u{68}\u{75}\u{68}\u{2e}","\u{2e}","\u{2f}\u{2f}") == "\u{61}\u{6c}\u{6f}\u{2f}\u{2f}\u{61}\u{6c}\u{6f}\u{2f}\u{2f}\u{75}\u{68}\u{75}\u{68}\u{2f}\u{2f}")
1135assert(gsub("\u{61}\u{6c}\u{6f}\u{2e}\u{61}\u{6c}\u{6f}\u{2e}\u{75}\u{68}\u{75}\u{68}\u{2e}","\u{2e}","\u{2f}\u{2f}") == "\u{61}\u{6c}\u{6f}\u{2f}\u{2f}\u{61}\u{6c}\u{6f}\u{2f}\u{2f}\u{75}\u{68}\u{75}\u{68}\u{2f}\u{2f}")
@@ -1138,25 +1138,25 @@ assert(gsub("","\u{61}\u{6c}\u{6f}","\u{2f}\u{2f}") == "")
1138assert(gsub("\u{2e}\u{2e}\u{2e}","\u{2e}","\u{2f}\u{2e}") == "\u{2f}\u{2e}\u{2f}\u{2e}\u{2f}\u{2e}")
1138assert(gsub("\u{2e}\u{2e}\u{2e}","\u{2e}","\u{2f}\u{2e}") == "\u{2f}\u{2e}\u{2f}\u{2e}\u{2f}\u{2e}")
1139assert(gsub("\u{2e}\u{2e}\u{2e}","\u{2e}\u{2e}\u{2e}","") == "")
1139assert(gsub("\u{2e}\u{2e}\u{2e}","\u{2e}\u{2e}\u{2e}","") == "")
1140local mt_xuxu,res,top = T.testC("\u{6e}\u{65}\u{77}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{78}\u{75}\u{78}\u{75}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
1140local mt_xuxu,res,top = T.testC("\u{6e}\u{65}\u{77}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{78}\u{75}\u{78}\u{75}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
1141−assert(type(mt_xuxu) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and res and top == 3)
1141+assert(type(mt_xuxu) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and res and top == 0x3)
1142local d,res,top = T.testC("\u{6e}\u{65}\u{77}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{78}\u{75}\u{78}\u{75}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
1142local d,res,top = T.testC("\u{6e}\u{65}\u{77}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{78}\u{75}\u{78}\u{75}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
1143−assert(mt_xuxu == d and not res and top == 3)
1143+assert(mt_xuxu == d and not res and top == 0x3)
1144d,res,top=T.testC("\u{6e}\u{65}\u{77}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{78}\u{75}\u{78}\u{75}\u{31}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
1144d,res,top=T.testC("\u{6e}\u{65}\u{77}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{78}\u{75}\u{78}\u{75}\u{31}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}")
1145−assert(mt_xuxu ~= d and res and top == 3)
1145+assert(mt_xuxu ~= d and res and top == 0x3)
1146−x=T.newuserdata(0)
1146+x=T.newuserdata(0x0)
1147;
1147;
1148−y=T.newuserdata(0)
1148+y=T.newuserdata(0x0)
1149;
1149;
1150T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{78}\u{75}\u{78}\u{75}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{52}\u{3b}\u{20}\u{73}\u{65}\u{74}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}",x)
1150T.testC("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{78}\u{75}\u{78}\u{75}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{52}\u{3b}\u{20}\u{73}\u{65}\u{74}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{32}",x)
1151assert(getmetatable(x) == mt_xuxu)
1151assert(getmetatable(x) == mt_xuxu)
1152local res1,res2,top = T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{20}\u{20}\u{20}\u{9}\u{20}\u{9}\u{9}\u{9}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{9}\u{9}\u{9}\u{9}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{9}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
1152local res1,res2,top = T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{20}\u{20}\u{20}\u{9}\u{20}\u{9}\u{9}\u{9}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{9}\u{9}\u{9}\u{9}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{9}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
1153−assert(res1 and res2 and top == 4)
1153+assert(res1 and res2 and top == 0x4)
1154res1,res2,top=T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{31}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{31}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
1154res1,res2,top=T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{31}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{31}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
1155−assert(not res1 and not res2 and top == 4)
1155+assert(not res1 and not res2 and top == 0x4)
1156res1,res2,top=T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{32}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{32}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
1156res1,res2,top=T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{32}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{32}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
1157−assert(not res1 and not res2 and top == 4)
1157+assert(not res1 and not res2 and top == 0x4)
1158res1,res2,top=T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",y)
1158res1,res2,top=T.testC("\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{2d}\u{31}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{74}\u{65}\u{73}\u{74}\u{75}\u{64}\u{61}\u{74}\u{61}\u{20}\u{32}\u{20}\u{78}\u{75}\u{78}\u{75}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{9}\u{9}\u{9}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",y)
1159−assert(not res1 and not res2 and top == 4)
1159+assert(not res1 and not res2 and top == 0x4)
1160do
1160do
1161local r = debug.getregistry()
1161local r = debug.getregistry()
1162assert(r.xuxu == mt_xuxu and r.xuxu1 == d)
1162assert(r.xuxu == mt_xuxu and r.xuxu1 == d)
zod/luau/res/lua/cycled/attrib.lua+103−103
@@ -12,16 +12,16 @@ assert(type(package.preload) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
12assert(type(package.config) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
12assert(type(package.config) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
13print("\u{70}\u{61}\u{63}\u{6b}\u{61}\u{67}\u{65}\u{20}\u{63}\u{6f}\u{6e}\u{66}\u{69}\u{67}\u{3a}\u{20}" .. string.gsub(package.config,"\u{a}","\u{7c}"))
13print("\u{70}\u{61}\u{63}\u{6b}\u{61}\u{67}\u{65}\u{20}\u{63}\u{6f}\u{6e}\u{66}\u{69}\u{67}\u{3a}\u{20}" .. string.gsub(package.config,"\u{a}","\u{7c}"))
14do
14do
15−local max = _soft and 100 or 2000
15+local max = _soft and 0x64 or 0x7d0
16local t = {}
16local t = {}
17−for i = 1, max
17+for i = 0x1, max
18do
18do
19−t[i]=string.rep("\u{3f}",i % 10 + 1)
19+t[i]=string.rep("\u{3f}",i % 0xa + 0x1)
20end
20end
21−t[# t + 1]="\u{3b}"
21+t[# t + 0x1]="\u{3b}"
22local path = table.concat(t,"\u{3b}")
22local path = table.concat(t,"\u{3b}")
23local s,err = package.searchpath("\u{78}\u{75}\u{78}\u{75}",path)
23local s,err = package.searchpath("\u{78}\u{75}\u{78}\u{75}",path)
24−assert(not s and string.find(err,string.rep("\u{78}\u{75}\u{78}\u{75}",10)) and # string.gsub(err,"\u{5b}\u{5e}\u{a}\u{5d}","") >= max)
24+assert(not s and string.find(err,string.rep("\u{78}\u{75}\u{78}\u{75}",0xa)) and # string.gsub(err,"\u{5b}\u{5e}\u{a}\u{5d}","") >= max)
25local path = string.rep("\u{3f}",max)
25local path = string.rep("\u{3f}",max)
26local s,err = package.searchpath("\u{78}\u{75}\u{78}\u{75}",path)
26local s,err = package.searchpath("\u{78}\u{75}\u{78}\u{75}",path)
27assert(not s and string.find(err,string.rep("\u{78}\u{75}\u{78}\u{75}",max)))
27assert(not s and string.find(err,string.rep("\u{78}\u{75}\u{78}\u{75}",max)))
@@ -98,20 +98,20 @@ assert(rr == r)
98assert(ext == x)
98assert(ext == x)
99end
99end
100local a = require("\u{6e}\u{61}\u{6d}\u{65}\u{73}")
100local a = require("\u{6e}\u{61}\u{6d}\u{65}\u{73}")
101−assert(a[1] == "\u{6e}\u{61}\u{6d}\u{65}\u{73}" and a[2] == D("\u{6e}\u{61}\u{6d}\u{65}\u{73}\u{2e}\u{6c}\u{75}\u{61}"))
101+assert(a[0x1] == "\u{6e}\u{61}\u{6d}\u{65}\u{73}" and a[0x2] == D("\u{6e}\u{61}\u{6d}\u{65}\u{73}\u{2e}\u{6c}\u{75}\u{61}"))
102local st,msg = pcall(require,"\u{65}\u{72}\u{72}")
102local st,msg = pcall(require,"\u{65}\u{72}\u{72}")
103−assert(not st and string.find(msg,"\u{61}\u{72}\u{69}\u{74}\u{68}\u{6d}\u{65}\u{74}\u{69}\u{63}") and B == 15)
103+assert(not st and string.find(msg,"\u{61}\u{72}\u{69}\u{74}\u{68}\u{6d}\u{65}\u{74}\u{69}\u{63}") and B == 0xf)
104st,msg=pcall(require,"\u{73}\u{79}\u{6e}\u{65}\u{72}\u{72}")
104st,msg=pcall(require,"\u{73}\u{79}\u{6e}\u{65}\u{72}\u{72}")
105assert(not st and string.find(msg,"\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{6f}\u{64}\u{75}\u{6c}\u{65}"))
105assert(not st and string.find(msg,"\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{6f}\u{64}\u{75}\u{6c}\u{65}"))
106assert(package.searchpath("\u{43}",package.path) == D("\u{43}\u{2e}\u{6c}\u{75}\u{61}"))
106assert(package.searchpath("\u{43}",package.path) == D("\u{43}\u{2e}\u{6c}\u{75}\u{61}"))
107−assert(require("\u{43}") == 25)
107+assert(require("\u{43}") == 0x19)
108−assert(require("\u{43}") == 25)
108+assert(require("\u{43}") == 0x19)
109AA=nil
109AA=nil
110try("\u{42}","\u{42}\u{2e}\u{6c}\u{75}\u{61}",true,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{42}\u{2e}\u{6c}\u{75}\u{61}")
110try("\u{42}","\u{42}\u{2e}\u{6c}\u{75}\u{61}",true,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{42}\u{2e}\u{6c}\u{75}\u{61}")
111assert(package.loaded.B)
111assert(package.loaded.B)
112assert(require("\u{42}") == true)
112assert(require("\u{42}") == true)
113assert(package.loaded.A)
113assert(package.loaded.A)
114−assert(require("\u{43}") == 25)
114+assert(require("\u{43}") == 0x19)
115package.loaded.A=nil
115package.loaded.A=nil
116try("\u{42}",nil,true,nil)
116try("\u{42}",nil,true,nil)
117try("\u{41}","\u{41}\u{2e}\u{6c}\u{75}\u{61}",true,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{41}\u{2e}\u{6c}\u{75}\u{61}")
117try("\u{41}","\u{41}\u{2e}\u{6c}\u{75}\u{61}",true,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{41}\u{2e}\u{6c}\u{75}\u{61}")
@@ -133,19 +133,19 @@ local _G = _G
133package.path=string.gsub("\u{44}\u{2f}\u{3f}\u{2e}\u{6c}\u{75}\u{61}\u{3b}\u{44}\u{2f}\u{3f}\u{2f}\u{69}\u{6e}\u{69}\u{74}\u{2e}\u{6c}\u{75}\u{61}","\u{44}\u{2f}",DIR)
133package.path=string.gsub("\u{44}\u{2f}\u{3f}\u{2e}\u{6c}\u{75}\u{61}\u{3b}\u{44}\u{2f}\u{3f}\u{2f}\u{69}\u{6e}\u{69}\u{74}\u{2e}\u{6c}\u{75}\u{61}","\u{44}\u{2f}",DIR)
134files={["\u{50}\u{31}\u{2f}\u{69}\u{6e}\u{69}\u{74}\u{2e}\u{6c}\u{75}\u{61}"] = "\u{41}\u{41}\u{20}\u{3d}\u{20}\u{31}\u{30}",["\u{50}\u{31}\u{2f}\u{78}\u{75}\u{78}\u{75}\u{2e}\u{6c}\u{75}\u{61}"] = "\u{41}\u{41}\u{20}\u{3d}\u{20}\u{32}\u{30}"}
134files={["\u{50}\u{31}\u{2f}\u{69}\u{6e}\u{69}\u{74}\u{2e}\u{6c}\u{75}\u{61}"] = "\u{41}\u{41}\u{20}\u{3d}\u{20}\u{31}\u{30}",["\u{50}\u{31}\u{2f}\u{78}\u{75}\u{78}\u{75}\u{2e}\u{6c}\u{75}\u{61}"] = "\u{41}\u{41}\u{20}\u{3d}\u{20}\u{32}\u{30}"}
135createfiles(files,"\u{5f}\u{45}\u{4e}\u{56}\u{20}\u{3d}\u{20}\u{7b}\u{7d}\u{a}","\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{45}\u{4e}\u{56}\u{a}")
135createfiles(files,"\u{5f}\u{45}\u{4e}\u{56}\u{20}\u{3d}\u{20}\u{7b}\u{7d}\u{a}","\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{45}\u{4e}\u{56}\u{a}")
136−AA=0
136+AA=0x0
137local m,ext = assert(require("\u{50}\u{31}"))
137local m,ext = assert(require("\u{50}\u{31}"))
138assert(ext == "\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{50}\u{31}\u{2f}\u{69}\u{6e}\u{69}\u{74}\u{2e}\u{6c}\u{75}\u{61}")
138assert(ext == "\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{50}\u{31}\u{2f}\u{69}\u{6e}\u{69}\u{74}\u{2e}\u{6c}\u{75}\u{61}")
139−assert(AA == 0 and m.AA == 10)
139+assert(AA == 0x0 and m.AA == 0xa)
140assert(require("\u{50}\u{31}") == m)
140assert(require("\u{50}\u{31}") == m)
141assert(require("\u{50}\u{31}") == m)
141assert(require("\u{50}\u{31}") == m)
142assert(package.searchpath("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}",package.path) == D("\u{50}\u{31}\u{2f}\u{78}\u{75}\u{78}\u{75}\u{2e}\u{6c}\u{75}\u{61}"))
142assert(package.searchpath("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}",package.path) == D("\u{50}\u{31}\u{2f}\u{78}\u{75}\u{78}\u{75}\u{2e}\u{6c}\u{75}\u{61}"))
143m.xuxu,ext=assert(require("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}"))
143m.xuxu,ext=assert(require("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}"))
144−assert(AA == 0 and m.xuxu.AA == 20)
144+assert(AA == 0x0 and m.xuxu.AA == 0x14)
145assert(ext == "\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{50}\u{31}\u{2f}\u{78}\u{75}\u{78}\u{75}\u{2e}\u{6c}\u{75}\u{61}")
145assert(ext == "\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{50}\u{31}\u{2f}\u{78}\u{75}\u{78}\u{75}\u{2e}\u{6c}\u{75}\u{61}")
146assert(require("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}") == m.xuxu)
146assert(require("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}") == m.xuxu)
147assert(require("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}") == m.xuxu)
147assert(require("\u{50}\u{31}\u{2e}\u{78}\u{75}\u{78}\u{75}") == m.xuxu)
148−assert(require("\u{50}\u{31}") == m and m.AA == 10)
148+assert(require("\u{50}\u{31}") == m and m.AA == 0xa)
149removefiles(files)
149removefiles(files)
150AA=nil
150AA=nil
151package.path=""
151package.path=""
@@ -158,11 +158,11 @@ local m,err = pcall(require,fname)
158for t in string.gmatch(package.path .. "\u{3b}" .. package.cpath,"\u{5b}\u{5e}\u{3b}\u{5d}\u{2b}")
158for t in string.gmatch(package.path .. "\u{3b}" .. package.cpath,"\u{5b}\u{5e}\u{3b}\u{5d}\u{2b}")
159do
159do
160t=string.gsub(t,"\u{3f}",fname)
160t=string.gsub(t,"\u{3f}",fname)
161−assert(string.find(err,t,1,true))
161+assert(string.find(err,t,0x1,true))
162end
162end
163do
163do
164local searchers = package.searchers
164local searchers = package.searchers
165−package.searchers=3
165+package.searchers=0x3
166local st,msg = pcall(require,"\u{61}")
166local st,msg = pcall(require,"\u{61}")
167assert(not st and string.find(msg,"\u{6d}\u{75}\u{73}\u{74}\u{20}\u{62}\u{65}\u{20}\u{61}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}"))
167assert(not st and string.find(msg,"\u{6d}\u{75}\u{73}\u{74}\u{20}\u{62}\u{65}\u{20}\u{61}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}"))
168package.searchers=searchers
168package.searchers=searchers
@@ -171,7 +171,7 @@ local function import
171(...)
171(...)
172local f = {...}
172local f = {...}
173return function (m)
173return function (m)
174−for i = 1, # f
174+for i = 0x1, # f
175do
175do
176m[f[i]]=_G[f[i]]
176m[f[i]]=_G[f[i]]
177end
177end
@@ -188,10 +188,10 @@ assert(not f and type(err) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and when ==
188print(err,when)
188print(err,when)
189else
189else
190local f = assert(package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}"),p .. "\u{6f}\u{6e}\u{65}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}"))
190local f = assert(package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}"),p .. "\u{6f}\u{6e}\u{65}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}"))
191−local a,b = f(15,25)
191+local a,b = f(0xf,0x19)
192−assert(a == 25 and b == 15)
192+assert(a == 0x19 and b == 0xf)
193f=assert(package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}"),p .. "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{66}\u{75}\u{6e}\u{63}"))
193f=assert(package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}"),p .. "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{66}\u{75}\u{6e}\u{63}"))
194−assert(f(10,20) == "\u{31}\u{30}\u{25}\u{32}\u{30}\u{a}")
194+assert(f(0xa,0x14) == "\u{31}\u{30}\u{25}\u{32}\u{30}\u{a}")
195local f,err,when = package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}"),p .. "\u{78}\u{75}\u{78}\u{75}")
195local f,err,when = package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}"),p .. "\u{78}\u{75}\u{78}\u{75}")
196assert(not f and type(err) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and when == "\u{69}\u{6e}\u{69}\u{74}")
196assert(not f and type(err) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and when == "\u{69}\u{6e}\u{69}\u{74}")
197f,err,when=package.loadlib("\u{64}\u{6f}\u{6e}\u{6f}\u{74}\u{65}\u{78}\u{69}\u{73}\u{74}",p .. "\u{78}\u{75}\u{78}\u{75}")
197f,err,when=package.loadlib("\u{64}\u{6f}\u{6e}\u{6f}\u{74}\u{65}\u{78}\u{69}\u{73}\u{74}",p .. "\u{78}\u{75}\u{78}\u{75}")
@@ -200,13 +200,13 @@ f=assert(package.loadlib(DC("\u{6c}\u{69}\u{62}\u{31}\u{31}"),p .. "\u{6c}\u{75}
200assert(f() == "\u{65}\u{78}\u{70}\u{6f}\u{72}\u{74}\u{65}\u{64}")
200assert(f() == "\u{65}\u{78}\u{70}\u{6f}\u{72}\u{74}\u{65}\u{64}")
201package.cpath=DC("\u{3f}")
201package.cpath=DC("\u{3f}")
202local lib2,ext = require("\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}")
202local lib2,ext = require("\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}")
203−assert(string.find(ext,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}",1,true))
203+assert(string.find(ext,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}",0x1,true))
204assert(_ENV.x == "\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}" and _ENV.y == DC("\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}"))
204assert(_ENV.x == "\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}" and _ENV.y == DC("\u{6c}\u{69}\u{62}\u{32}\u{2d}\u{76}\u{32}"))
205assert(lib2.id("\u{78}") == true)
205assert(lib2.id("\u{78}") == true)
206local fs,ext = require("\u{6c}\u{69}\u{62}\u{31}\u{2e}\u{73}\u{75}\u{62}")
206local fs,ext = require("\u{6c}\u{69}\u{62}\u{31}\u{2e}\u{73}\u{75}\u{62}")
207assert(_ENV.x == "\u{6c}\u{69}\u{62}\u{31}\u{2e}\u{73}\u{75}\u{62}" and _ENV.y == DC("\u{6c}\u{69}\u{62}\u{31}"))
207assert(_ENV.x == "\u{6c}\u{69}\u{62}\u{31}\u{2e}\u{73}\u{75}\u{62}" and _ENV.y == DC("\u{6c}\u{69}\u{62}\u{31}"))
208−assert(string.find(ext,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{6c}\u{69}\u{62}\u{31}",1,true))
208+assert(string.find(ext,"\u{6c}\u{69}\u{62}\u{73}\u{2f}\u{6c}\u{69}\u{62}\u{31}",0x1,true))
209−assert(fs.id(45) == 45)
209+assert(fs.id(0x2d) == 0x2d)
210_ENV.x,_ENV.y=nil
210_ENV.x,_ENV.y=nil
211end
211end
212_ENV=_G
212_ENV=_G
@@ -216,37 +216,37 @@ package={}
216p.preload.pl=function (...)
216p.preload.pl=function (...)
217local _ENV = {...}
217local _ENV = {...}
218function xuxu(x)
218function xuxu(x)
219−return x + 20
219+return x + 0x14
220end
220end
221return _ENV
221return _ENV
222end
222end
223local pl,ext = require("\u{70}\u{6c}")
223local pl,ext = require("\u{70}\u{6c}")
224assert(require("\u{70}\u{6c}") == pl)
224assert(require("\u{70}\u{6c}") == pl)
225−assert(pl.xuxu(10) == 30)
225+assert(pl.xuxu(0xa) == 0x1e)
226−assert(pl[1] == "\u{70}\u{6c}" and pl[2] == "\u{3a}\u{70}\u{72}\u{65}\u{6c}\u{6f}\u{61}\u{64}\u{3a}" and ext == "\u{3a}\u{70}\u{72}\u{65}\u{6c}\u{6f}\u{61}\u{64}\u{3a}")
226+assert(pl[0x1] == "\u{70}\u{6c}" and pl[0x2] == "\u{3a}\u{70}\u{72}\u{65}\u{6c}\u{6f}\u{61}\u{64}\u{3a}" and ext == "\u{3a}\u{70}\u{72}\u{65}\u{6c}\u{6f}\u{61}\u{64}\u{3a}")
227package=p
227package=p
228assert(type(package.path) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
228assert(type(package.path) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
229end
229end
230print("\u{2b}")
230print("\u{2b}")
231end
231end
232print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{73}\u{73}\u{69}\u{67}\u{6e}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{2c}\u{20}\u{6c}\u{6f}\u{67}\u{69}\u{63}\u{61}\u{6c}\u{20}\u{6f}\u{70}\u{65}\u{72}\u{61}\u{74}\u{6f}\u{72}\u{73}\u{2c}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{6f}\u{72}\u{73}")
232print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{73}\u{73}\u{69}\u{67}\u{6e}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{2c}\u{20}\u{6c}\u{6f}\u{67}\u{69}\u{63}\u{61}\u{6c}\u{20}\u{6f}\u{70}\u{65}\u{72}\u{61}\u{74}\u{6f}\u{72}\u{73}\u{2c}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{6f}\u{72}\u{73}")
233−local res,res2 = 27
233+local res,res2 = 0x1b
234−local a,b = 1,2 + 3
234+local a,b = 0x1,0x2 + 0x3
235−assert(a == 1 and b == 5)
235+assert(a == 0x1 and b == 0x5)
236a={}
236a={}
237local function f
237local function f
238()
238()
239−return 10,11,12
239+return 0xa,0xb,0xc
240end
240end
241−a.x,b,a[1]=1,2,f()
241+a.x,b,a[0x1]=0x1,0x2,f()
242−assert(a.x == 1 and b == 2 and a[1] == 10)
242+assert(a.x == 0x1 and b == 0x2 and a[0x1] == 0xa)
243−a[f()],b,a[f() + 3]=f(),a,"\u{78}"
243+a[f()],b,a[f() + 0x3]=f(),a,"\u{78}"
244−assert(a[10] == 10 and b == a and a[13] == "\u{78}")
244+assert(a[0xa] == 0xa and b == a and a[0xd] == "\u{78}")
245do
245do
246local f = function (n)
246local f = function (n)
247local x = {}
247local x = {}
248;
248;
249−for i = 1, n
249+for i = 0x1, n
250do
250do
251x[i]=i
251x[i]=i
252end
252end
@@ -255,67 +255,67 @@ return table.unpack(x)
255end
255end
256;
256;
257local a,b,c
257local a,b,c
258−a,b=0,f(1)
258+a,b=0x0,f(0x1)
259−assert(a == 0 and b == 1)
259+assert(a == 0x0 and b == 0x1)
260−a,b=0,f(1)
260+a,b=0x0,f(0x1)
261−assert(a == 0 and b == 1)
261+assert(a == 0x0 and b == 0x1)
262−a,b,c=0,5,f(4)
262+a,b,c=0x0,0x5,f(0x4)
263−assert(a == 0 and b == 5 and c == 1)
263+assert(a == 0x0 and b == 0x5 and c == 0x1)
264−a,b,c=0,5,f(0)
264+a,b,c=0x0,0x5,f(0x0)
265−assert(a == 0 and b == 5 and c == nil)
265+assert(a == 0x0 and b == 0x5 and c == nil)
266−end
266+end
267−local a,b,c,d = 1 and nil,1 or nil,(1 and (nil or 1)),6
267+local a,b,c,d = 0x1 and nil,0x1 or nil,(0x1 and (nil or 0x1)),0x6
268−assert(not a and b and c and d == 6)
268+assert(not a and b and c and d == 0x6)
269−d=20
269+d=0x14
270a,b,c,d=f()
270a,b,c,d=f()
271−assert(a == 10 and b == 11 and c == 12 and d == nil)
271+assert(a == 0xa and b == 0xb and c == 0xc and d == nil)
272−a,b=f(),1,2,3,f()
272+a,b=f(),0x1,0x2,0x3,f()
273−assert(a == 10 and b == 1)
273+assert(a == 0xa and b == 0x1)
274assert(a < b == false and a > b == true)
274assert(a < b == false and a > b == true)
275−assert((10 and 2) == 2)
275+assert((0xa and 0x2) == 0x2)
276−assert((10 or 2) == 10)
276+assert((0xa or 0x2) == 0xa)
277−assert((10 or assert(nil)) == 10)
277+assert((0xa or assert(nil)) == 0xa)
278assert(not (nil and assert(nil)))
278assert(not (nil and assert(nil)))
279assert((nil or "\u{61}\u{6c}\u{6f}") == "\u{61}\u{6c}\u{6f}")
279assert((nil or "\u{61}\u{6c}\u{6f}") == "\u{61}\u{6c}\u{6f}")
280−assert((nil and 10) == nil)
280+assert((nil and 0xa) == nil)
281−assert((false and 10) == false)
281+assert((false and 0xa) == false)
282−assert((true or 10) == true)
282+assert((true or 0xa) == true)
283−assert((false or 10) == 10)
283+assert((false or 0xa) == 0xa)
284assert(false ~= nil)
284assert(false ~= nil)
285assert(nil ~= false)
285assert(nil ~= false)
286assert(not nil == true)
286assert(not nil == true)
287assert(not not nil == false)
287assert(not not nil == false)
288−assert(not not 1 == true)
288+assert(not not 0x1 == true)
289assert(not not a == true)
289assert(not not a == true)
290−assert(not not (6 or nil) == true)
290+assert(not not (0x6 or nil) == true)
291−assert(not not (nil and 56) == false)
291+assert(not not (nil and 0x38) == false)
292assert(not not (nil and true) == false)
292assert(not not (nil and true) == false)
293−assert(not 10 == false)
293+assert(not 0xa == false)
294assert(not {} == false)
294assert(not {} == false)
295assert(not 0.5 == false)
295assert(not 0.5 == false)
296assert(not "\u{78}" == false)
296assert(not "\u{78}" == false)
297assert({} ~= {})
297assert({} ~= {})
298print("\u{2b}")
298print("\u{2b}")
299a={}
299a={}
300−a[true]=20
300+a[true]=0x14
301−a[false]=10
301+a[false]=0xa
302−assert(a[1 < 2] == 20 and a[1 > 2] == 10)
302+assert(a[0x1 < 0x2] == 0x14 and a[0x1 > 0x2] == 0xa)
303function f(a)
303function f(a)
304return a
304return a
305end
305end
306local a = {}
306local a = {}
307−for i = 3000, - 3000, - 1
307+for i = 0xbb8, - 0xbb8, - 0x1
308do
308do
309a[i + 0.0]=i
309a[i + 0.0]=i
310;
310;
311end
311end
312a[1e31]="\u{61}\u{6c}\u{6f}"
312a[1e31]="\u{61}\u{6c}\u{6f}"
313;
313;
314−a[true]=10
314+a[true]=0xa
315;
315;
316−a[false]=20
316+a[false]=0x14
317−assert(a[1e31] == "\u{61}\u{6c}\u{6f}" and a[not 1] == 20 and a[10 < 20] == 10)
317+assert(a[1e31] == "\u{61}\u{6c}\u{6f}" and a[not 0x1] == 0x14 and a[0xa < 0x14] == 0xa)
318−for i = 3000, - 3000, - 1
318+for i = 0xbb8, - 0xbb8, - 0x1
319do
319do
320assert(a[i] == i)
320assert(a[i] == i)
321;
321;
@@ -328,79 +328,79 @@ a[print](a[a[f]] == a[print])
328assert(not pcall(function ()
328assert(not pcall(function ()
329local a = {}
329local a = {}
330;
330;
331−a[nil]=10
331+a[nil]=0xa
332end))
332end))
333assert(not pcall(function ()
333assert(not pcall(function ()
334−local a = {[nil] = 10}
334+local a = {[nil] = 0xa}
335end))
335end))
336assert(a[nil] == undef)
336assert(a[nil] == undef)
337a=nil
337a=nil
338local a,b,c
338local a,b,c
339−a={10,9,8,7,6,5,4,3,2,[- 3] = "\u{61}",[f] = print,["\u{61}"] = "\u{61}",["\u{62}"] = "\u{61}\u{62}"}
339+a={0xa,0x9,0x8,0x7,0x6,0x5,0x4,0x3,0x2,[- 0x3] = "\u{61}",[f] = print,["\u{61}"] = "\u{61}",["\u{62}"] = "\u{61}\u{62}"}
340−a,a.x,a.y=a,a[- 3]
340+a,a.x,a.y=a,a[- 0x3]
341−assert(a[1] == 10 and a[- 3] == a.a and a[f] == print and a.x == "\u{61}" and not a.y)
341+assert(a[0x1] == 0xa and a[- 0x3] == a.a and a[f] == print and a.x == "\u{61}" and not a.y)
342−a[1],f(a)[2],b,c={["\u{61}\u{6c}\u{6f}"] = assert},10,a[1],a[f],6,10,23,f(a),2
342+a[0x1],f(a)[0x2],b,c={["\u{61}\u{6c}\u{6f}"] = assert},0xa,a[0x1],a[f],0x6,0xa,0x17,f(a),0x2
343−a[1].alo(a[2] == 10 and b == 10 and c == print)
343+a[0x1].alo(a[0x2] == 0xa and b == 0xa and c == print)
344−a.aVeryLongName012345678901234567890123456789012345678901234567890123456789=10
344+a.aVeryLongName012345678901234567890123456789012345678901234567890123456789=0xa
345local function foo
345local function foo
346()
346()
347return a.aVeryLongName012345678901234567890123456789012345678901234567890123456789
347return a.aVeryLongName012345678901234567890123456789012345678901234567890123456789
348end
348end
349−assert(foo() == 10 and a.aVeryLongName012345678901234567890123456789012345678901234567890123456789 == 10)
349+assert(foo() == 0xa and a.aVeryLongName012345678901234567890123456789012345678901234567890123456789 == 0xa)
350do
350do
351local function foo
351local function foo
352()
352()
353−local _ENV <const> = 11
353+local _ENV <const> = 0xb
354X="\u{68}\u{69}"
354X="\u{68}\u{69}"
355end
355end
356local st,msg = pcall(foo)
356local st,msg = pcall(foo)
357assert(not st and string.find(msg,"\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}"))
357assert(not st and string.find(msg,"\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}"))
358end
358end
359local maxint = math.maxinteger
359local maxint = math.maxinteger
360−while maxint ~= (maxint + 0.0) or (maxint - 1) ~= (maxint - 1.0) do
360+while maxint ~= (maxint + 0.0) or (maxint - 0x1) ~= (maxint - 1.0) do
361−maxint=maxint // 2
361+maxint=maxint // 0x2
362end
362end
363local maxintF = maxint + 0.0
363local maxintF = maxint + 0.0
364−assert(maxintF == maxint and math.type(maxintF) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}" and maxintF >= 2.0 ^ 14)
364+assert(maxintF == maxint and math.type(maxintF) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}" and maxintF >= 2.0 ^ 0xe)
365−a[maxintF]=10
365+a[maxintF]=0xa
366;
366;
367−a[maxintF - 1.0]=11
367+a[maxintF - 1.0]=0xb
368;
368;
369−a[- maxintF]=12
369+a[- maxintF]=0xc
370;
370;
371−a[- maxintF + 1.0]=13
371+a[- maxintF + 1.0]=0xd
372;
372;
373−assert(a[maxint] == 10 and a[maxint - 1] == 11 and a[- maxint] == 12 and a[- maxint + 1] == 13)
373+assert(a[maxint] == 0xa and a[maxint - 0x1] == 0xb and a[- maxint] == 0xc and a[- maxint + 0x1] == 0xd)
374−a[maxint]=20
374+a[maxint]=0x14
375−a[- maxint]=22
375+a[- maxint]=0x16
376−assert(a[maxintF] == 20 and a[maxintF - 1.0] == 11 and a[- maxintF] == 22 and a[- maxintF + 1.0] == 13)
376+assert(a[maxintF] == 0x14 and a[maxintF - 1.0] == 0xb and a[- maxintF] == 0x16 and a[- maxintF + 1.0] == 0xd)
377a=nil
377a=nil
378do
378do
379local a,i,j,b
379local a,i,j,b
380a={"\u{61}","\u{62}"}
380a={"\u{61}","\u{62}"}
381;
381;
382−i=1
382+i=0x1
383;
383;
384−j=2
384+j=0x2
385;
385;
386b=a
386b=a
387i,a[i],a,j,a[j],a[i + j]=j,i,i,b,j,i
387i,a[i],a,j,a[j],a[i + j]=j,i,i,b,j,i
388−assert(i == 2 and b[1] == 1 and a == 1 and j == b and b[2] == 2 and b[3] == 1)
388+assert(i == 0x2 and b[0x1] == 0x1 and a == 0x1 and j == b and b[0x2] == 0x2 and b[0x3] == 0x1)
389a={}
389a={}
390local function foo
390local function foo
391()
391()
392−b,a.x,a=a,10,20
392+b,a.x,a=a,0xa,0x14
393end
393end
394foo()
394foo()
395−assert(a == 20 and b.x == 10)
395+assert(a == 0x14 and b.x == 0xa)
396end
396end
397do
397do
398local a,i,j,b
398local a,i,j,b
399a={"\u{61}","\u{62}"}
399a={"\u{61}","\u{62}"}
400;
400;
401−i=1
401+i=0x1
402;
402;
403−j=2
403+j=0x2
404;
404;
405b=a
405b=a
406local function foo
406local function foo
@@ -408,24 +408,24 @@ local function foo
408i,a[i],a,j,a[j],a[i + j]=j,i,i,b,j,i
408i,a[i],a,j,a[j],a[i + j]=j,i,i,b,j,i
409end
409end
410foo()
410foo()
411−assert(i == 2 and b[1] == 1 and a == 1 and j == b and b[2] == 2 and b[3] == 1)
411+assert(i == 0x2 and b[0x1] == 0x1 and a == 0x1 and j == b and b[0x2] == 0x2 and b[0x3] == 0x1)
412local t = {}
412local t = {}
413(function (a)
413(function (a)
414−t[a],a=10,20
414+t[a],a=0xa,0x14
415−end)(1)
415+end)(0x1)
416;
416;
417−assert(t[1] == 10)
417+assert(t[0x1] == 0xa)
418end
418end
419local function foo
419local function foo
420()
420()
421local a
421local a
422return function ()
422return function ()
423local b
423local b
424−a,b=3,14
424+a,b=0x3,0xe
425return a,b
425return a,b
426end
426end
427end
427end
428local a,b = foo()()
428local a,b = foo()()
429−assert(a == 3 and b == 14)
429+assert(a == 0x3 and b == 0xe)
430print("\u{4f}\u{4b}")
430print("\u{4f}\u{4b}")
431return res
431return res
zod/luau/res/lua/cycled/big.lua+14−14
@@ -3,21 +3,21 @@ return "\u{61}"
3end
3end
4print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
4print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
5local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
5local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
6−local lim = 2 ^ 18 + 1000
6+local lim = 0x2 ^ 0x12 + 0x3e8
7local prog = {"\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{79}\u{20}\u{3d}\u{20}\u{7b}\u{30}"}
7local prog = {"\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{79}\u{20}\u{3d}\u{20}\u{7b}\u{30}"}
8−for i = 1, lim
8+for i = 0x1, lim
9do
9do
10−prog[# prog + 1]=i
10+prog[# prog + 0x1]=i
11end
11end
12−prog[# prog + 1]="\u{7d}\u{a}"
12+prog[# prog + 0x1]="\u{7d}\u{a}"
13−prog[# prog + 1]="\u{58}\u{20}\u{3d}\u{20}\u{79}\u{a}"
13+prog[# prog + 0x1]="\u{58}\u{20}\u{3d}\u{20}\u{79}\u{a}"
14−prog[# prog + 1]=("\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{58}\u{5b}\u{25}\u{64}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{25}\u{64}\u{29}"):format(lim - 1,lim - 2)
14+prog[# prog + 0x1]=("\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{58}\u{5b}\u{25}\u{64}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{25}\u{64}\u{29}"):format(lim - 0x1,lim - 0x2)
15−prog[# prog + 1]="\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{30}"
15+prog[# prog + 0x1]="\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{30}"
16prog=table.concat(prog,"\u{3b}")
16prog=table.concat(prog,"\u{3b}")
17local env = {["\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}"] = string,["\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}"] = assert}
17local env = {["\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}"] = string,["\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}"] = assert}
18local f = assert(load(prog,nil,nil,env))
18local f = assert(load(prog,nil,nil,env))
19f()
19f()
20−assert(env.X[lim] == lim - 1 and env.X[lim + 1] == lim)
20+assert(env.X[lim] == lim - 0x1 and env.X[lim + 0x1] == lim)
21for k in pairs(env)
21for k in pairs(env)
22do
22do
23env[k]=undef
23env[k]=undef
@@ -36,8 +36,8 @@ local co = coroutine.wrap(f)
36assert(co() == "\u{73}")
36assert(co() == "\u{73}")
37assert(co() == "\u{67}")
37assert(co() == "\u{67}")
38assert(co() == "\u{67}")
38assert(co() == "\u{67}")
39−assert(co() == 0)
39+assert(co() == 0x0)
40−assert(X[lim] == lim - 1 and X[lim + 1] == lim)
40+assert(X[lim] == lim - 0x1 and X[lim + 0x1] == lim)
41getmetatable(env).__index=function ()
41getmetatable(env).__index=function ()
42
42
43end
43end
@@ -53,11 +53,11 @@ local e,m = xpcall(f,debug.traceback)
53assert(not e and m:find("\u{27}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{27}"))
53assert(not e and m:find("\u{27}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{27}"))
54f,X=nil
54f,X=nil
55coroutine.yield("\u{62}")
55coroutine.yield("\u{62}")
56−if 2 ^ 32 == 0 then
56+if 0x2 ^ 0x20 == 0x0 then
57print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}")
57print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}")
58−local repstrings = 192
58+local repstrings = 0xc0
59−local ssize = math.ceil(2.0 ^ 32 / repstrings) + 1
59+local ssize = math.ceil(2.0 ^ 0x20 / repstrings) + 0x1
60−assert(repstrings * ssize > 2.0 ^ 32)
60+assert(repstrings * ssize > 2.0 ^ 0x20)
61local longs = string.rep("\u{0}",ssize)
61local longs = string.rep("\u{0}",ssize)
62local rep = assert(load("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{2e}\u{2e}\u{2e}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. string.rep("\u{61}",repstrings,"\u{2e}\u{2e}")))
62local rep = assert(load("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{2e}\u{2e}\u{2e}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. string.rep("\u{61}",repstrings,"\u{2e}\u{2e}")))
63local a,b = pcall(rep,longs)
63local a,b = pcall(rep,longs)
zod/luau/res/lua/cycled/bitwise.lua+179−179
@@ -1,23 +1,23 @@
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{62}\u{69}\u{74}\u{77}\u{69}\u{73}\u{65}\u{20}\u{6f}\u{70}\u{65}\u{72}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}")
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{62}\u{69}\u{74}\u{77}\u{69}\u{73}\u{65}\u{20}\u{6f}\u{70}\u{65}\u{72}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}")
2require("\u{62}\u{77}\u{63}\u{6f}\u{65}\u{72}\u{63}\u{69}\u{6f}\u{6e}")
2require("\u{62}\u{77}\u{63}\u{6f}\u{65}\u{72}\u{63}\u{69}\u{6f}\u{6e}")
3−local numbits = string.packsize("\u{6a}") * 8
3+local numbits = string.packsize("\u{6a}") * 0x8
4−assert(~ 0 == - 1)
4+assert(~ 0x0 == - 0x1)
5−assert((1 << (numbits - 1)) == math.mininteger)
5+assert((0x1 << (numbits - 0x1)) == math.mininteger)
6local a,b,c,d
6local a,b,c,d
7−a=18446744073709551615
7+a=0xffffffffffffffff
8−assert(a == - 1 and a & - 1 == a and a & 35 == 35)
8+assert(a == - 0x1 and a & - 0x1 == a and a & 0x23 == 0x23)
9−a=17361641481138401520
9+a=0xf0f0f0f0f0f0f0f0
10−assert(a | - 1 == - 1)
10+assert(a | - 0x1 == - 0x1)
11−assert(a ~ a == 0 and a ~ 0 == a and a ~ ~ a == - 1)
11+assert(a ~ a == 0x0 and a ~ 0x0 == a and a ~ ~ a == - 0x1)
12−assert(a >> 4 == ~ a)
12+assert(a >> 0x4 == ~ a)
13−a=240
13+a=0xf0
14;
14;
15−b=204
15+b=0xcc
16;
16;
17−c=170
17+c=0xaa
18;
18;
19−d=253
19+d=0xfd
20−assert(a | b ~ c & d == 244)
20+assert(a | b ~ c & d == 0xf4)
21a=240.0
21a=240.0
22;
22;
23b=204.0
23b=204.0
@@ -25,55 +25,55 @@ b=204.0
25c="\u{30}\u{78}\u{41}\u{41}\u{2e}\u{30}"
25c="\u{30}\u{78}\u{41}\u{41}\u{2e}\u{30}"
26;
26;
27d="\u{30}\u{78}\u{46}\u{44}\u{2e}\u{30}"
27d="\u{30}\u{78}\u{46}\u{44}\u{2e}\u{30}"
28−assert(a | b ~ c & d == 244)
28+assert(a | b ~ c & d == 0xf4)
29−a=4026531840
29+a=0xf0000000
30;
30;
31−b=3422552064
31+b=0xcc000000
32;
32;
33−c=2852126720
33+c=0xaa000000
34;
34;
35−d=4244635648
35+d=0xfd000000
36−assert(a | b ~ c & d == 4093640704)
36+assert(a | b ~ c & d == 0xf4000000)
37−assert(~ ~ a == a and ~ a == - 1 ~ a and - d == ~ d + 1)
37+assert(~ ~ a == a and ~ a == - 0x1 ~ a and - d == ~ d + 0x1)
38−a=a << 32
38+a=a << 0x20
39−b=b << 32
39+b=b << 0x20
40−c=c << 32
40+c=c << 0x20
41−d=d << 32
41+d=d << 0x20
42−assert(a | b ~ c & d == 4093640704 << 32)
42+assert(a | b ~ c & d == 0xf4000000 << 0x20)
43−assert(~ ~ a == a and ~ a == - 1 ~ a and - d == ~ d + 1)
43+assert(~ ~ a == a and ~ a == - 0x1 ~ a and - d == ~ d + 0x1)
44do
44do
45local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3e}\u{3e}\u{20}\u{25}\u{64}",math.maxinteger)
45local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3e}\u{3e}\u{20}\u{25}\u{64}",math.maxinteger)
46−assert(load(code)() == 0)
46+assert(load(code)() == 0x0)
47local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3e}\u{3e}\u{20}\u{25}\u{64}",math.mininteger)
47local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3e}\u{3e}\u{20}\u{25}\u{64}",math.mininteger)
48−assert(load(code)() == 0)
48+assert(load(code)() == 0x0)
49local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3c}\u{3c}\u{20}\u{25}\u{64}",math.maxinteger)
49local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3c}\u{3c}\u{20}\u{25}\u{64}",math.maxinteger)
50−assert(load(code)() == 0)
50+assert(load(code)() == 0x0)
51local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3c}\u{3c}\u{20}\u{25}\u{64}",math.mininteger)
51local code = string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2d}\u{31}\u{20}\u{3c}\u{3c}\u{20}\u{25}\u{64}",math.mininteger)
52−assert(load(code)() == 0)
52+assert(load(code)() == 0x0)
53end
53end
54−assert(- 1 >> 1 == (1 << (numbits - 1)) - 1 and 1 << 31 == 2147483648)
54+assert(- 0x1 >> 0x1 == (0x1 << (numbits - 0x1)) - 0x1 and 0x1 << 0x1f == 0x80000000)
55−assert(- 1 >> (numbits - 1) == 1)
55+assert(- 0x1 >> (numbits - 0x1) == 0x1)
56−assert(- 1 >> numbits == 0 and - 1 >> - numbits == 0 and - 1 << numbits == 0 and - 1 << - numbits == 0)
56+assert(- 0x1 >> numbits == 0x0 and - 0x1 >> - numbits == 0x0 and - 0x1 << numbits == 0x0 and - 0x1 << - numbits == 0x0)
57−assert(1 >> math.mininteger == 0)
57+assert(0x1 >> math.mininteger == 0x0)
58−assert(1 >> math.maxinteger == 0)
58+assert(0x1 >> math.maxinteger == 0x0)
59−assert(1 << math.mininteger == 0)
59+assert(0x1 << math.mininteger == 0x0)
60−assert(1 << math.maxinteger == 0)
60+assert(0x1 << math.maxinteger == 0x0)
61−assert((2 ^ 30 - 1) << 2 ^ 30 == 0)
61+assert((0x2 ^ 0x1e - 0x1) << 0x2 ^ 0x1e == 0x0)
62−assert((2 ^ 30 - 1) >> 2 ^ 30 == 0)
62+assert((0x2 ^ 0x1e - 0x1) >> 0x2 ^ 0x1e == 0x0)
63−assert(1 >> - 3 == 1 << 3 and 1000 >> 5 == 1000 << - 5)
63+assert(0x1 >> - 0x3 == 0x1 << 0x3 and 0x3e8 >> 0x5 == 0x3e8 << - 0x5)
64−assert("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}" | 0 == - 1)
64+assert("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}" | 0x0 == - 0x1)
65−assert("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{65}" & "\u{2d}\u{31}" == - 2)
65+assert("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{65}" & "\u{2d}\u{31}" == - 0x2)
66−assert("\u{20}\u{9}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{65}\u{a}\u{9}" & "\u{2d}\u{31}" == 2)
66+assert("\u{20}\u{9}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{65}\u{a}\u{9}" & "\u{2d}\u{31}" == 0x2)
67−assert("\u{20}\u{20}\u{20}\u{a}\u{20}\u{20}\u{2d}\u{34}\u{35}\u{20}\u{20}\u{9}\u{20}" >> "\u{20}\u{20}\u{2d}\u{32}\u{20}\u{20}" == - 45 * 4)
67+assert("\u{20}\u{20}\u{20}\u{a}\u{20}\u{20}\u{2d}\u{34}\u{35}\u{20}\u{20}\u{9}\u{20}" >> "\u{20}\u{20}\u{2d}\u{32}\u{20}\u{20}" == - 0x2d * 0x4)
68−assert("\u{31}\u{32}\u{33}\u{34}\u{2e}\u{30}" << "\u{35}\u{2e}\u{30}" == 1234 * 32)
68+assert("\u{31}\u{32}\u{33}\u{34}\u{2e}\u{30}" << "\u{35}\u{2e}\u{30}" == 0x4d2 * 0x20)
69−assert("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{2e}\u{30}" ~ "\u{30}\u{78}\u{41}\u{41}\u{41}\u{41}" == 21845)
69+assert("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{2e}\u{30}" ~ "\u{30}\u{78}\u{41}\u{41}\u{41}\u{41}" == 0x5555)
70−assert(~ "\u{30}\u{78}\u{30}\u{2e}\u{30}\u{30}\u{30}\u{70}\u{34}" == - 1)
70+assert(~ "\u{30}\u{78}\u{30}\u{2e}\u{30}\u{30}\u{30}\u{70}\u{34}" == - 0x1)
71−assert(("\u{37}" .. 3) << 1 == 146)
71+assert(("\u{37}" .. 0x3) << 0x1 == 0x92)
72−assert(4294967295 >> (1 .. "\u{39}") == 8191)
72+assert(0xffffffff >> (0x1 .. "\u{39}") == 0x1fff)
73−assert(10 | (1 .. "\u{39}") == 27)
73+assert(0xa | (0x1 .. "\u{39}") == 0x1b)
74do
74do
75local st,msg = pcall(function ()
75local st,msg = pcall(function ()
76−return 4 & "\u{61}"
76+return 0x4 & "\u{61}"
77end)
77end)
78assert(string.find(msg,"\u{27}\u{62}\u{61}\u{6e}\u{64}\u{27}"))
78assert(string.find(msg,"\u{27}\u{62}\u{61}\u{6e}\u{64}\u{27}"))
79local st,msg = pcall(function ()
79local st,msg = pcall(function ()
@@ -82,89 +82,89 @@ end)
82assert(string.find(msg,"\u{27}\u{62}\u{6e}\u{6f}\u{74}\u{27}"))
82assert(string.find(msg,"\u{27}\u{62}\u{6e}\u{6f}\u{74}\u{27}"))
83end
83end
84assert(not pcall(function ()
84assert(not pcall(function ()
85−return "\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2e}\u{30}" | 0
85+return "\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2e}\u{30}" | 0x0
86end))
86end))
87assert(not pcall(function ()
87assert(not pcall(function ()
88−return "\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{0}" | 0
88+return "\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{0}" | 0x0
89end))
89end))
90print("\u{2b}")
90print("\u{2b}")
91package.preload.bit32=function ()
91package.preload.bit32=function ()
92local bit = {}
92local bit = {}
93function bit.bnot(a)
93function bit.bnot(a)
94−return ~ a & 4294967295
94+return ~ a & 0xffffffff
95end
95end
96function bit.band(x,y,z, ...)
96function bit.band(x,y,z, ...)
97if not z then
97if not z then
98−return ((x or - 1) & (y or - 1)) & 4294967295
98+return ((x or - 0x1) & (y or - 0x1)) & 0xffffffff
99else
99else
100local arg = {...}
100local arg = {...}
101local res = x & y & z
101local res = x & y & z
102−for i = 1, # arg
102+for i = 0x1, # arg
103do
103do
104res=res & arg[i]
104res=res & arg[i]
105end
105end
106−return res & 4294967295
106+return res & 0xffffffff
107end
107end
108end
108end
109function bit.bor(x,y,z, ...)
109function bit.bor(x,y,z, ...)
110if not z then
110if not z then
111−return ((x or 0) | (y or 0)) & 4294967295
111+return ((x or 0x0) | (y or 0x0)) & 0xffffffff
112else
112else
113local arg = {...}
113local arg = {...}
114local res = x | y | z
114local res = x | y | z
115−for i = 1, # arg
115+for i = 0x1, # arg
116do
116do
117res=res | arg[i]
117res=res | arg[i]
118end
118end
119−return res & 4294967295
119+return res & 0xffffffff
120end
120end
121end
121end
122function bit.bxor(x,y,z, ...)
122function bit.bxor(x,y,z, ...)
123if not z then
123if not z then
124−return ((x or 0) ~ (y or 0)) & 4294967295
124+return ((x or 0x0) ~ (y or 0x0)) & 0xffffffff
125else
125else
126local arg = {...}
126local arg = {...}
127local res = x ~ y ~ z
127local res = x ~ y ~ z
128−for i = 1, # arg
128+for i = 0x1, # arg
129do
129do
130res=res ~ arg[i]
130res=res ~ arg[i]
131end
131end
132−return res & 4294967295
132+return res & 0xffffffff
133end
133end
134end
134end
135function bit.btest(...)
135function bit.btest(...)
136−return bit.band(...) ~= 0
136+return bit.band(...) ~= 0x0
137end
137end
138function bit.lshift(a,b)
138function bit.lshift(a,b)
139−return ((a & 4294967295) << b) & 4294967295
139+return ((a & 0xffffffff) << b) & 0xffffffff
140end
140end
141function bit.rshift(a,b)
141function bit.rshift(a,b)
142−return ((a & 4294967295) >> b) & 4294967295
142+return ((a & 0xffffffff) >> b) & 0xffffffff
143end
143end
144function bit.arshift(a,b)
144function bit.arshift(a,b)
145−a=a & 4294967295
145+a=a & 0xffffffff
146−if b <= 0 or (a & 2147483648) == 0 then
146+if b <= 0x0 or (a & 0x80000000) == 0x0 then
147−return (a >> b) & 4294967295
147+return (a >> b) & 0xffffffff
148else
148else
149−return ((a >> b) | ~ (4294967295 >> b)) & 4294967295
149+return ((a >> b) | ~ (0xffffffff >> b)) & 0xffffffff
150end
150end
151end
151end
152function bit.lrotate(a,b)
152function bit.lrotate(a,b)
153−b=b & 31
153+b=b & 0x1f
154−a=a & 4294967295
154+a=a & 0xffffffff
155−a=(a << b) | (a >> (32 - b))
155+a=(a << b) | (a >> (0x20 - b))
156−return a & 4294967295
156+return a & 0xffffffff
157end
157end
158function bit.rrotate(a,b)
158function bit.rrotate(a,b)
159return bit.lrotate(a,- b)
159return bit.lrotate(a,- b)
160end
160end
161local function checkfield
161local function checkfield
162(f,w)
162(f,w)
163−w=w or 1
163+w=w or 0x1
164−assert(f >= 0,"\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{6e}\u{65}\u{67}\u{61}\u{74}\u{69}\u{76}\u{65}")
164+assert(f >= 0x0,"\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{6e}\u{65}\u{67}\u{61}\u{74}\u{69}\u{76}\u{65}")
165−assert(w > 0,"\u{77}\u{69}\u{64}\u{74}\u{68}\u{20}\u{6d}\u{75}\u{73}\u{74}\u{20}\u{62}\u{65}\u{20}\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{76}\u{65}")
165+assert(w > 0x0,"\u{77}\u{69}\u{64}\u{74}\u{68}\u{20}\u{6d}\u{75}\u{73}\u{74}\u{20}\u{62}\u{65}\u{20}\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{76}\u{65}")
166−assert(f + w <= 32,"\u{74}\u{72}\u{79}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{6f}\u{20}\u{61}\u{63}\u{63}\u{65}\u{73}\u{73}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{65}\u{78}\u{69}\u{73}\u{74}\u{65}\u{6e}\u{74}\u{20}\u{62}\u{69}\u{74}\u{73}")
166+assert(f + w <= 0x20,"\u{74}\u{72}\u{79}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{6f}\u{20}\u{61}\u{63}\u{63}\u{65}\u{73}\u{73}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{65}\u{78}\u{69}\u{73}\u{74}\u{65}\u{6e}\u{74}\u{20}\u{62}\u{69}\u{74}\u{73}")
167−return f,~ (- 1 << w)
167+return f,~ (- 0x1 << w)
168end
168end
169function bit.extract(a,f,w)
169function bit.extract(a,f,w)
170local f,mask = checkfield(f,w)
170local f,mask = checkfield(f,w)
@@ -174,136 +174,136 @@ function bit.replace(a,v,f,w)
174local f,mask = checkfield(f,w)
174local f,mask = checkfield(f,w)
175v=v & mask
175v=v & mask
176a=(a & ~ (mask << f)) | (v << f)
176a=(a & ~ (mask << f)) | (v << f)
177−return a & 4294967295
177+return a & 0xffffffff
178end
178end
179return bit
179return bit
180end
180end
181print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{62}\u{69}\u{74}\u{77}\u{69}\u{73}\u{65}\u{20}\u{6c}\u{69}\u{62}\u{72}\u{61}\u{72}\u{79}")
181print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{62}\u{69}\u{74}\u{77}\u{69}\u{73}\u{65}\u{20}\u{6c}\u{69}\u{62}\u{72}\u{61}\u{72}\u{79}")
182local bit32 = require("\u{62}\u{69}\u{74}\u{33}\u{32}")
182local bit32 = require("\u{62}\u{69}\u{74}\u{33}\u{32}")
183−assert(bit32.band() == bit32.bnot(0))
183+assert(bit32.band() == bit32.bnot(0x0))
184assert(bit32.btest() == true)
184assert(bit32.btest() == true)
185−assert(bit32.bor() == 0)
185+assert(bit32.bor() == 0x0)
186−assert(bit32.bxor() == 0)
186+assert(bit32.bxor() == 0x0)
187−assert(bit32.band() == bit32.band(4294967295))
187+assert(bit32.band() == bit32.band(0xffffffff))
188−assert(bit32.band(1,2) == 0)
188+assert(bit32.band(0x1,0x2) == 0x0)
189−assert(bit32.band(- 1) == 4294967295)
189+assert(bit32.band(- 0x1) == 0xffffffff)
190−assert(bit32.band((1 << 33) - 1) == 4294967295)
190+assert(bit32.band((0x1 << 0x21) - 0x1) == 0xffffffff)
191−assert(bit32.band(- (1 << 33) - 1) == 4294967295)
191+assert(bit32.band(- (0x1 << 0x21) - 0x1) == 0xffffffff)
192−assert(bit32.band((1 << 33) + 1) == 1)
192+assert(bit32.band((0x1 << 0x21) + 0x1) == 0x1)
193−assert(bit32.band(- (1 << 33) + 1) == 1)
193+assert(bit32.band(- (0x1 << 0x21) + 0x1) == 0x1)
194−assert(bit32.band(- (1 << 40)) == 0)
194+assert(bit32.band(- (0x1 << 0x28)) == 0x0)
195−assert(bit32.band(1 << 40) == 0)
195+assert(bit32.band(0x1 << 0x28) == 0x0)
196−assert(bit32.band(- (1 << 40) - 2) == 4294967294)
196+assert(bit32.band(- (0x1 << 0x28) - 0x2) == 0xfffffffe)
197−assert(bit32.band((1 << 40) - 4) == 4294967292)
197+assert(bit32.band((0x1 << 0x28) - 0x4) == 0xfffffffc)
198−assert(bit32.lrotate(0,- 1) == 0)
198+assert(bit32.lrotate(0x0,- 0x1) == 0x0)
199−assert(bit32.lrotate(0,7) == 0)
199+assert(bit32.lrotate(0x0,0x7) == 0x0)
200−assert(bit32.lrotate(305419896,0) == 305419896)
200+assert(bit32.lrotate(0x12345678,0x0) == 0x12345678)
201−assert(bit32.lrotate(305419896,32) == 305419896)
201+assert(bit32.lrotate(0x12345678,0x20) == 0x12345678)
202−assert(bit32.lrotate(305419896,4) == 591751041)
202+assert(bit32.lrotate(0x12345678,0x4) == 0x23456781)
203−assert(bit32.rrotate(305419896,- 4) == 591751041)
203+assert(bit32.rrotate(0x12345678,- 0x4) == 0x23456781)
204−assert(bit32.lrotate(305419896,- 8) == 2014458966)
204+assert(bit32.lrotate(0x12345678,- 0x8) == 0x78123456)
205−assert(bit32.rrotate(305419896,8) == 2014458966)
205+assert(bit32.rrotate(0x12345678,0x8) == 0x78123456)
206−assert(bit32.lrotate(2863311530,2) == 2863311530)
206+assert(bit32.lrotate(0xaaaaaaaa,0x2) == 0xaaaaaaaa)
207−assert(bit32.lrotate(2863311530,- 2) == 2863311530)
207+assert(bit32.lrotate(0xaaaaaaaa,- 0x2) == 0xaaaaaaaa)
208−for i = - 50, 50
208+for i = - 0x32, 0x32
209do
209do
210−assert(bit32.lrotate(2309737967,i) == bit32.lrotate(2309737967,i % 32))
210+assert(bit32.lrotate(0x89abcdef,i) == bit32.lrotate(0x89abcdef,i % 0x20))
211end
211end
212−assert(bit32.lshift(305419896,4) == 591751040)
212+assert(bit32.lshift(0x12345678,0x4) == 0x23456780)
213−assert(bit32.lshift(305419896,8) == 878082048)
213+assert(bit32.lshift(0x12345678,0x8) == 0x34567800)
214−assert(bit32.lshift(305419896,- 4) == 19088743)
214+assert(bit32.lshift(0x12345678,- 0x4) == 0x1234567)
215−assert(bit32.lshift(305419896,- 8) == 1193046)
215+assert(bit32.lshift(0x12345678,- 0x8) == 0x123456)
216−assert(bit32.lshift(305419896,32) == 0)
216+assert(bit32.lshift(0x12345678,0x20) == 0x0)
217−assert(bit32.lshift(305419896,- 32) == 0)
217+assert(bit32.lshift(0x12345678,- 0x20) == 0x0)
218−assert(bit32.rshift(305419896,4) == 19088743)
218+assert(bit32.rshift(0x12345678,0x4) == 0x1234567)
219−assert(bit32.rshift(305419896,8) == 1193046)
219+assert(bit32.rshift(0x12345678,0x8) == 0x123456)
220−assert(bit32.rshift(305419896,32) == 0)
220+assert(bit32.rshift(0x12345678,0x20) == 0x0)
221−assert(bit32.rshift(305419896,- 32) == 0)
221+assert(bit32.rshift(0x12345678,- 0x20) == 0x0)
222−assert(bit32.arshift(305419896,0) == 305419896)
222+assert(bit32.arshift(0x12345678,0x0) == 0x12345678)
223−assert(bit32.arshift(305419896,1) == 305419896 // 2)
223+assert(bit32.arshift(0x12345678,0x1) == 0x12345678 // 0x2)
224−assert(bit32.arshift(305419896,- 1) == 305419896 * 2)
224+assert(bit32.arshift(0x12345678,- 0x1) == 0x12345678 * 0x2)
225−assert(bit32.arshift(- 1,1) == 4294967295)
225+assert(bit32.arshift(- 0x1,0x1) == 0xffffffff)
226−assert(bit32.arshift(- 1,24) == 4294967295)
226+assert(bit32.arshift(- 0x1,0x18) == 0xffffffff)
227−assert(bit32.arshift(- 1,32) == 4294967295)
227+assert(bit32.arshift(- 0x1,0x20) == 0xffffffff)
228−assert(bit32.arshift(- 1,- 1) == bit32.band(- 1 * 2,4294967295))
228+assert(bit32.arshift(- 0x1,- 0x1) == bit32.band(- 0x1 * 0x2,0xffffffff))
229−assert(305419896 << 4 == 4886718336)
229+assert(0x12345678 << 0x4 == 0x123456780)
230−assert(305419896 << 8 == 78187493376)
230+assert(0x12345678 << 0x8 == 0x1234567800)
231−assert(305419896 << - 4 == 19088743)
231+assert(0x12345678 << - 0x4 == 0x1234567)
232−assert(305419896 << - 8 == 1193046)
232+assert(0x12345678 << - 0x8 == 0x123456)
233−assert(305419896 << 32 == 1311768464867721216)
233+assert(0x12345678 << 0x20 == 0x1234567800000000)
234−assert(305419896 << - 32 == 0)
234+assert(0x12345678 << - 0x20 == 0x0)
235−assert(305419896 >> 4 == 19088743)
235+assert(0x12345678 >> 0x4 == 0x1234567)
236−assert(305419896 >> 8 == 1193046)
236+assert(0x12345678 >> 0x8 == 0x123456)
237−assert(305419896 >> 32 == 0)
237+assert(0x12345678 >> 0x20 == 0x0)
238−assert(305419896 >> - 32 == 1311768464867721216)
238+assert(0x12345678 >> - 0x20 == 0x1234567800000000)
239print("\u{2b}")
239print("\u{2b}")
240−local c = {0,1,2,3,10,2147483648,2863311530,1431655765,4294967295,2147483647}
240+local c = {0x0,0x1,0x2,0x3,0xa,0x80000000,0xaaaaaaaa,0x55555555,0xffffffff,0x7fffffff}
241for _,b in pairs(c)
241for _,b in pairs(c)
242do
242do
243assert(bit32.band(b) == b)
243assert(bit32.band(b) == b)
244assert(bit32.band(b,b) == b)
244assert(bit32.band(b,b) == b)
245assert(bit32.band(b,b,b,b) == b)
245assert(bit32.band(b,b,b,b) == b)
246−assert(bit32.btest(b,b) == (b ~= 0))
246+assert(bit32.btest(b,b) == (b ~= 0x0))
247assert(bit32.band(b,b,b) == b)
247assert(bit32.band(b,b,b) == b)
248−assert(bit32.band(b,b,b,~ b) == 0)
248+assert(bit32.band(b,b,b,~ b) == 0x0)
249−assert(bit32.btest(b,b,b) == (b ~= 0))
249+assert(bit32.btest(b,b,b) == (b ~= 0x0))
250−assert(bit32.band(b,bit32.bnot(b)) == 0)
250+assert(bit32.band(b,bit32.bnot(b)) == 0x0)
251−assert(bit32.bor(b,bit32.bnot(b)) == bit32.bnot(0))
251+assert(bit32.bor(b,bit32.bnot(b)) == bit32.bnot(0x0))
252assert(bit32.bor(b) == b)
252assert(bit32.bor(b) == b)
253assert(bit32.bor(b,b) == b)
253assert(bit32.bor(b,b) == b)
254assert(bit32.bor(b,b,b) == b)
254assert(bit32.bor(b,b,b) == b)
255−assert(bit32.bor(b,b,0,~ b) == 4294967295)
255+assert(bit32.bor(b,b,0x0,~ b) == 0xffffffff)
256assert(bit32.bxor(b) == b)
256assert(bit32.bxor(b) == b)
257−assert(bit32.bxor(b,b) == 0)
257+assert(bit32.bxor(b,b) == 0x0)
258assert(bit32.bxor(b,b,b) == b)
258assert(bit32.bxor(b,b,b) == b)
259−assert(bit32.bxor(b,b,b,b) == 0)
259+assert(bit32.bxor(b,b,b,b) == 0x0)
260−assert(bit32.bxor(b,0) == b)
260+assert(bit32.bxor(b,0x0) == b)
261assert(bit32.bnot(b) ~= b)
261assert(bit32.bnot(b) ~= b)
262assert(bit32.bnot(bit32.bnot(b)) == b)
262assert(bit32.bnot(bit32.bnot(b)) == b)
263−assert(bit32.bnot(b) == (1 << 32) - 1 - b)
263+assert(bit32.bnot(b) == (0x1 << 0x20) - 0x1 - b)
264−assert(bit32.lrotate(b,32) == b)
264+assert(bit32.lrotate(b,0x20) == b)
265−assert(bit32.rrotate(b,32) == b)
265+assert(bit32.rrotate(b,0x20) == b)
266−assert(bit32.lshift(bit32.lshift(b,- 4),4) == bit32.band(b,bit32.bnot(15)))
266+assert(bit32.lshift(bit32.lshift(b,- 0x4),0x4) == bit32.band(b,bit32.bnot(0xf)))
267−assert(bit32.rshift(bit32.rshift(b,4),- 4) == bit32.band(b,bit32.bnot(15)))
267+assert(bit32.rshift(bit32.rshift(b,0x4),- 0x4) == bit32.band(b,bit32.bnot(0xf)))
268end
268end
269−c={0,1,2,3,10,8388608,11184810,5592405,16777215,8388607}
269+c={0x0,0x1,0x2,0x3,0xa,0x800000,0xaaaaaa,0x555555,0xffffff,0x7fffff}
270for _,b in pairs(c)
270for _,b in pairs(c)
271do
271do
272−for i = - 40, 40
272+for i = - 0x28, 0x28
273do
273do
274local x = bit32.lshift(b,i)
274local x = bit32.lshift(b,i)
275−local y = math.floor(math.fmod(b * 2.0 ^ i,2.0 ^ 32))
275+local y = math.floor(math.fmod(b * 2.0 ^ i,2.0 ^ 0x20))
276−assert(math.fmod(x - y,2.0 ^ 32) == 0)
276+assert(math.fmod(x - y,2.0 ^ 0x20) == 0x0)
277end
277end
278end
278end
279assert(not pcall(bit32.band,{}))
279assert(not pcall(bit32.band,{}))
280assert(not pcall(bit32.bnot,"\u{61}"))
280assert(not pcall(bit32.bnot,"\u{61}"))
281−assert(not pcall(bit32.lshift,45))
281+assert(not pcall(bit32.lshift,0x2d))
282−assert(not pcall(bit32.lshift,45,print))
282+assert(not pcall(bit32.lshift,0x2d,print))
283−assert(not pcall(bit32.rshift,45,print))
283+assert(not pcall(bit32.rshift,0x2d,print))
284print("\u{2b}")
284print("\u{2b}")
285−assert(bit32.extract(305419896,0,4) == 8)
285+assert(bit32.extract(0x12345678,0x0,0x4) == 0x8)
286−assert(bit32.extract(305419896,4,4) == 7)
286+assert(bit32.extract(0x12345678,0x4,0x4) == 0x7)
287−assert(bit32.extract(2684358929,28,4) == 10)
287+assert(bit32.extract(0xa0001111,0x1c,0x4) == 0xa)
288−assert(bit32.extract(2684358929,31,1) == 1)
288+assert(bit32.extract(0xa0001111,0x1f,0x1) == 0x1)
289−assert(bit32.extract(1342177553,31,1) == 0)
289+assert(bit32.extract(0x50000111,0x1f,0x1) == 0x0)
290−assert(bit32.extract(4063516281,0,32) == 4063516281)
290+assert(bit32.extract(0xf2345679,0x0,0x20) == 0xf2345679)
291−assert(not pcall(bit32.extract,0,- 1))
291+assert(not pcall(bit32.extract,0x0,- 0x1))
292−assert(not pcall(bit32.extract,0,32))
292+assert(not pcall(bit32.extract,0x0,0x20))
293−assert(not pcall(bit32.extract,0,0,33))
293+assert(not pcall(bit32.extract,0x0,0x0,0x21))
294−assert(not pcall(bit32.extract,0,31,2))
294+assert(not pcall(bit32.extract,0x0,0x1f,0x2))
295−assert(bit32.replace(305419896,5,28,4) == 1379161720)
295+assert(bit32.replace(0x12345678,0x5,0x1c,0x4) == 0x52345678)
296−assert(bit32.replace(305419896,2271560481,0,32) == 2271560481)
296+assert(bit32.replace(0x12345678,0x87654321,0x0,0x20) == 0x87654321)
297−assert(bit32.replace(0,1,2) == 2 ^ 2)
297+assert(bit32.replace(0x0,0x1,0x2) == 0x2 ^ 0x2)
298−assert(bit32.replace(0,- 1,4) == 2 ^ 4)
298+assert(bit32.replace(0x0,- 0x1,0x4) == 0x2 ^ 0x4)
299−assert(bit32.replace(- 1,0,31) == (1 << 31) - 1)
299+assert(bit32.replace(- 0x1,0x0,0x1f) == (0x1 << 0x1f) - 0x1)
300−assert(bit32.replace(- 1,0,1,2) == (1 << 32) - 7)
300+assert(bit32.replace(- 0x1,0x0,0x1,0x2) == (0x1 << 0x20) - 0x7)
301−assert(bit32.bor(3.0) == 3)
301+assert(bit32.bor(3.0) == 0x3)
302−assert(bit32.bor(- 4.0) == 4294967292)
302+assert(bit32.bor(- 4.0) == 0xfffffffc)
303−if 2.0 ^ 50 < 2.0 ^ 50 + 1.0 and 2.0 ^ 50 < (- 1 >> 1) then
303+if 2.0 ^ 0x32 < 2.0 ^ 0x32 + 1.0 and 2.0 ^ 0x32 < (- 0x1 >> 0x1) then
304−assert(bit32.bor(2.0 ^ 32 - 5.0) == 4294967291)
304+assert(bit32.bor(2.0 ^ 0x20 - 5.0) == 0xfffffffb)
305−assert(bit32.bor(- 2.0 ^ 32 - 6.0) == 4294967290)
305+assert(bit32.bor(- 2.0 ^ 0x20 - 6.0) == 0xfffffffa)
306−assert(bit32.bor(2.0 ^ 48 - 5.0) == 4294967291)
306+assert(bit32.bor(2.0 ^ 0x30 - 5.0) == 0xfffffffb)
307−assert(bit32.bor(- 2.0 ^ 48 - 6.0) == 4294967290)
307+assert(bit32.bor(- 2.0 ^ 0x30 - 6.0) == 0xfffffffa)
308end
308end
309print("\u{4f}\u{4b}")
309print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/bwcoercion.lua+1−1
@@ -20,7 +20,7 @@ if mm then
20return mm(x,y)
20return mm(x,y)
21end
21end
22end
22end
23−error("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{27}" .. strsub(mtname,3) .. "\u{27}\u{20}\u{61}\u{20}" .. type(x) .. "\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{61}\u{20}" .. type(y),4)
23+error("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{27}" .. strsub(mtname,0x3) .. "\u{27}\u{20}\u{61}\u{20}" .. type(x) .. "\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{61}\u{20}" .. type(y),0x4)
24end
24end
25local function checkargs
25local function checkargs
26(x,y,mtname)
26(x,y,mtname)
zod/luau/res/lua/cycled/calls.lua+153−153
@@ -1,8 +1,8 @@
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}")
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}")
2local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
2local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
3−assert(type(1 < 2) == "\u{62}\u{6f}\u{6f}\u{6c}\u{65}\u{61}\u{6e}")
3+assert(type(0x1 < 0x2) == "\u{62}\u{6f}\u{6f}\u{6c}\u{65}\u{61}\u{6e}")
4assert(type(true) == "\u{62}\u{6f}\u{6f}\u{6c}\u{65}\u{61}\u{6e}" and type(false) == "\u{62}\u{6f}\u{6f}\u{6c}\u{65}\u{61}\u{6e}")
4assert(type(true) == "\u{62}\u{6f}\u{6f}\u{6c}\u{65}\u{61}\u{6e}" and type(false) == "\u{62}\u{6f}\u{6f}\u{6c}\u{65}\u{61}\u{6e}")
5−assert(type(nil) == "\u{6e}\u{69}\u{6c}" and type(- 3) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and type("\u{78}") == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type({}) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and type(type) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
5+assert(type(nil) == "\u{6e}\u{69}\u{6c}" and type(- 0x3) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and type("\u{78}") == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type({}) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and type(type) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
6assert(type(assert) == type(print))
6assert(type(assert) == type(print))
7local function f
7local function f
8(x)
8(x)
@@ -12,53 +12,53 @@ assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
12assert(not pcall(type))
12assert(not pcall(type))
13fact=false
13fact=false
14do
14do
15−local res = 1
15+local res = 0x1
16local function fact
16local function fact
17(n)
17(n)
18−if n == 0 then
18+if n == 0x0 then
19return res
19return res
20else
20else
21−return n * fact(n - 1)
21+return n * fact(n - 0x1)
22end
22end
23end
23end
24−assert(fact(5) == 120)
24+assert(fact(0x5) == 0x78)
25end
25end
26assert(fact == false)
26assert(fact == false)
27fact=nil
27fact=nil
28−local a = {["\u{69}"] = 10}
28+local a = {["\u{69}"] = 0xa}
29−local self = 20
29+local self = 0x14
30function a:x(x)
30function a:x(x)
31return x + self.i
31return x + self.i
32end
32end
33function a.y(x)
33function a.y(x)
34return x + self
34return x + self
35end
35end
36−assert(a:x(1) + 10 == a.y(1))
36+assert(a:x(0x1) + 0xa == a.y(0x1))
37−a.t={["\u{69}"] = - 100}
37+a.t={["\u{69}"] = - 0x64}
38a["\u{74}"].x=function (self,a,b)
38a["\u{74}"].x=function (self,a,b)
39return self.i + a + b
39return self.i + a + b
40end
40end
41−assert(a.t:x(2,3) == - 95)
41+assert(a.t:x(0x2,0x3) == - 0x5f)
42do
42do
43−local a = {["\u{78}"] = 0}
43+local a = {["\u{78}"] = 0x0}
44function a:add(x)
44function a:add(x)
45−self.x,a.y=self.x + x,20
45+self.x,a.y=self.x + x,0x14
46;
46;
47return self
47return self
48end
48end
49−assert(a:add(10):add(20):add(30).x == 60 and a.y == 20)
49+assert(a:add(0xa):add(0x14):add(0x1e).x == 0x3c and a.y == 0x14)
50end
50end
51local a = {["\u{62}"] = {["\u{63}"] = {}}}
51local a = {["\u{62}"] = {["\u{63}"] = {}}}
52function a.b.c.f1(x)
52function a.b.c.f1(x)
53−return x + 1
53+return x + 0x1
54end
54end
55function a.b.c:f2(x,y)
55function a.b.c:f2(x,y)
56self[x]=y
56self[x]=y
57end
57end
58−assert(a.b.c.f1(4) == 5)
58+assert(a.b.c.f1(0x4) == 0x5)
59−a.b.c:f2("\u{6b}",12)
59+a.b.c:f2("\u{6b}",0xc)
60;
60;
61−assert(a.b.c.k == 12)
61+assert(a.b.c.k == 0xc)
62print("\u{2b}")
62print("\u{2b}")
63t=nil
63t=nil
64function f(a,b,c)
64function f(a,b,c)
@@ -66,94 +66,94 @@ local d = "\u{61}"
66;
66;
67t={a,b,c,d}
67t={a,b,c,d}
68end
68end
69−f(1,2)
69+f(0x1,0x2)
70−assert(t[1] == 1 and t[2] == 2 and t[3] == nil and t[4] == "\u{61}")
70+assert(t[0x1] == 0x1 and t[0x2] == 0x2 and t[0x3] == nil and t[0x4] == "\u{61}")
71−f(1,2,3,4)
71+f(0x1,0x2,0x3,0x4)
72−assert(t[1] == 1 and t[2] == 2 and t[3] == 3 and t[4] == "\u{61}")
72+assert(t[0x1] == 0x1 and t[0x2] == 0x2 and t[0x3] == 0x3 and t[0x4] == "\u{61}")
73t=nil
73t=nil
74function fat(x)
74function fat(x)
75−if x <= 1 then
75+if x <= 0x1 then
76−return 1
76+return 0x1
77else
77else
78−return x * load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{61}\u{74}\u{28}" .. x - 1 .. "\u{29}","")()
78+return x * load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{61}\u{74}\u{28}" .. x - 0x1 .. "\u{29}","")()
79end
79end
80end
80end
81assert(load("\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{27}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{66}\u{61}\u{74}\u{28}\u{36}\u{29}\u{3d}\u{3d}\u{37}\u{32}\u{30}\u{29}\u{27}\u{20}\u{28}\u{29}\u{20}"))()
81assert(load("\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{27}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{66}\u{61}\u{74}\u{28}\u{36}\u{29}\u{3d}\u{3d}\u{37}\u{32}\u{30}\u{29}\u{27}\u{20}\u{28}\u{29}\u{20}"))()
82a=load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{61}\u{74}\u{28}\u{35}\u{29}\u{2c}\u{20}\u{33}")
82a=load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{61}\u{74}\u{28}\u{35}\u{29}\u{2c}\u{20}\u{33}")
83local a,b = a()
83local a,b = a()
84−assert(a == 120 and b == 3)
84+assert(a == 0x78 and b == 0x3)
85fat=nil
85fat=nil
86print("\u{2b}")
86print("\u{2b}")
87local function err_on_n
87local function err_on_n
88(n)
88(n)
89−if n == 0 then
89+if n == 0x0 then
90error()
90error()
91;
91;
92−exit(1)
92+exit(0x1)
93;
93;
94else
94else
95−err_on_n(n - 1)
95+err_on_n(n - 0x1)
96;
96;
97−exit(1)
97+exit(0x1)
98;
98;
99end
99end
100end
100end
101do
101do
102local function dummy
102local function dummy
103(n)
103(n)
104−if n > 0 then
104+if n > 0x0 then
105assert(not pcall(err_on_n,n))
105assert(not pcall(err_on_n,n))
106−dummy(n - 1)
106+dummy(n - 0x1)
107end
107end
108end
108end
109−dummy(10)
109+dummy(0xa)
110end
110end
111_G.deep=nil
111_G.deep=nil
112function deep(n)
112function deep(n)
113−if n > 0 then
113+if n > 0x0 then
114−deep(n - 1)
114+deep(n - 0x1)
115end
115end
116end
116end
117−deep(10)
117+deep(0xa)
118−deep(180)
118+deep(0xb4)
119print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}")
119print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}")
120function deep(n)
120function deep(n)
121−if n > 0 then
121+if n > 0x0 then
122−return deep(n - 1)
122+return deep(n - 0x1)
123else
123else
124−return 101
124+return 0x65
125end
125end
126end
126end
127−assert(deep(30000) == 101)
127+assert(deep(0x7530) == 0x65)
128a={}
128a={}
129function a:deep(n)
129function a:deep(n)
130−if n > 0 then
130+if n > 0x0 then
131−return self:deep(n - 1)
131+return self:deep(n - 0x1)
132else
132else
133−return 101
133+return 0x65
134end
134end
135end
135end
136−assert(a:deep(30000) == 101)
136+assert(a:deep(0x7530) == 0x65)
137do
137do
138local function foo
138local function foo
139(x, ...)
139(x, ...)
140local a = {...}
140local a = {...}
141;
141;
142−return x,a[1],a[2]
142+return x,a[0x1],a[0x2]
143end
143end
144local function foo1
144local function foo1
145(x)
145(x)
146−return foo(10,x,x + 1)
146+return foo(0xa,x,x + 0x1)
147end
147end
148−local a,b,c = foo1(- 2)
148+local a,b,c = foo1(- 0x2)
149−assert(a == 10 and b == - 2 and c == - 1)
149+assert(a == 0xa and b == - 0x2 and c == - 0x1)
150local t = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = foo})
150local t = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = foo})
151local function foo2
151local function foo2
152(x)
152(x)
153−return t(10,x)
153+return t(0xa,x)
154end
154end
155−a,b,c=foo2(100)
155+a,b,c=foo2(0x64)
156−assert(a == t and b == 10 and c == 100)
156+assert(a == t and b == 0xa and c == 0x64)
157a,b=(function ()
157a,b=(function ()
158return foo()
158return foo()
159end)()
159end)()
@@ -172,13 +172,13 @@ local function foo1
172return foo(...)
172return foo(...)
173end
173end
174local a,b,c = foo1()
174local a,b,c = foo1()
175−assert(X == nil and Y == nil and # A == 0)
175+assert(X == nil and Y == nil and # A == 0x0)
176−a,b,c=foo1(10)
176+a,b,c=foo1(0xa)
177−assert(X == 10 and Y == nil and # A == 0)
177+assert(X == 0xa and Y == nil and # A == 0x0)
178−a,b,c=foo1(10,20)
178+a,b,c=foo1(0xa,0x14)
179−assert(X == 10 and Y == 20 and # A == 0)
179+assert(X == 0xa and Y == 0x14 and # A == 0x0)
180−a,b,c=foo1(10,20,30)
180+a,b,c=foo1(0xa,0x14,0x1e)
181−assert(X == 10 and Y == 20 and # A == 1 and A[1] == 30)
181+assert(X == 0xa and Y == 0x14 and # A == 0x1 and A[0x1] == 0x1e)
182end
182end
183do
183do
184local function loop
184local function loop
@@ -189,48 +189,48 @@ local err,msg = xpcall(loop,loop)
189assert(not err and string.find(msg,"\u{65}\u{72}\u{72}\u{6f}\u{72}"))
189assert(not err and string.find(msg,"\u{65}\u{72}\u{72}\u{6f}\u{72}"))
190end
190end
191do
191do
192−local n = 10000
192+local n = 0x2710
193local function foo
193local function foo
194()
194()
195−if n == 0 then
195+if n == 0x0 then
196−return 1023
196+return 0x3ff
197else
197else
198−n=n - 1
198+n=n - 0x1
199;
199;
200return foo()
200return foo()
201end
201end
202end
202end
203−for i = 1, 100
203+for i = 0x1, 0x64
204do
204do
205foo=setmetatable({},{["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = foo})
205foo=setmetatable({},{["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = foo})
206end
206end
207assert(coroutine.wrap(function ()
207assert(coroutine.wrap(function ()
208return foo()
208return foo()
209−end)() == 1023)
209+end)() == 0x3ff)
210end
210end
211print("\u{2b}")
211print("\u{2b}")
212do
212do
213−local N = 20
213+local N = 0x14
214local u = table.pack
214local u = table.pack
215−for i = 1, N
215+for i = 0x1, N
216do
216do
217u=setmetatable({i},{["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = u})
217u=setmetatable({i},{["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = u})
218end
218end
219local Res = u("\u{61}","\u{62}","\u{63}")
219local Res = u("\u{61}","\u{62}","\u{63}")
220−assert(Res.n == N + 3)
220+assert(Res.n == N + 0x3)
221−for i = 1, N
221+for i = 0x1, N
222do
222do
223−assert(Res[i][1] == i)
223+assert(Res[i][0x1] == i)
224end
224end
225−assert(Res[N + 1] == "\u{61}" and Res[N + 2] == "\u{62}" and Res[N + 3] == "\u{63}")
225+assert(Res[N + 0x1] == "\u{61}" and Res[N + 0x2] == "\u{62}" and Res[N + 0x3] == "\u{63}")
226end
226end
227a=nil
227a=nil
228(function (x)
228(function (x)
229a=x
229a=x
230−end)(23)
230+end)(0x17)
231−assert(a == 23 and (function (x)
231+assert(a == 0x17 and (function (x)
232−return x * 2
232+return x * 0x2
233−end)(20) == 40)
233+end)(0x14) == 0x28)
234local Z = function (le)
234local Z = function (le)
235local function a
235local function a
236(f)
236(f)
@@ -242,15 +242,15 @@ return a(a)
242end
242end
243local F = function (f)
243local F = function (f)
244return function (n)
244return function (n)
245−if n == 0 then
245+if n == 0x0 then
246−return 1
246+return 0x1
247else
247else
248−return n * f(n - 1)
248+return n * f(n - 0x1)
249end
249end
250end
250end
251end
251end
252local fat = Z(F)
252local fat = Z(F)
253−assert(fat(0) == 1 and fat(4) == 24 and Z(F)(5) == 5 * Z(F)(4))
253+assert(fat(0x0) == 0x1 and fat(0x4) == 0x18 and Z(F)(0x5) == 0x5 * Z(F)(0x4))
254local function g
254local function g
255(z)
255(z)
256local function f
256local function f
@@ -259,22 +259,22 @@ return function (x,y)
259return a + b + c + d + a + x + y + z
259return a + b + c + d + a + x + y + z
260end
260end
261end
261end
262−return f(z,z + 1,z + 2,z + 3)
262+return f(z,z + 0x1,z + 0x2,z + 0x3)
263end
263end
264−local f = g(10)
264+local f = g(0xa)
265−assert(f(9,16) == 10 + 11 + 12 + 13 + 10 + 9 + 16 + 10)
265+assert(f(0x9,0x10) == 0xa + 0xb + 0xc + 0xd + 0xa + 0x9 + 0x10 + 0xa)
266print("\u{2b}")
266print("\u{2b}")
267local function unlpack
267local function unlpack
268(t,i)
268(t,i)
269−i=i or 1
269+i=i or 0x1
270if (i <= # t) then
270if (i <= # t) then
271−return t[i],unlpack(t,i + 1)
271+return t[i],unlpack(t,i + 0x1)
272end
272end
273end
273end
274local function equaltab
274local function equaltab
275(t1,t2)
275(t1,t2)
276assert(# t1 == # t2)
276assert(# t1 == # t2)
277−for i = 1, # t1
277+for i = 0x1, # t1
278do
278do
279assert(t1[i] == t2[i])
279assert(t1[i] == t2[i])
280end
280end
@@ -284,38 +284,38 @@ return (table.pack(...))
284end
284end
285local function f
285local function f
286()
286()
287−return 1,2,30,4
287+return 0x1,0x2,0x1e,0x4
288end
288end
289local function ret2
289local function ret2
290(a,b)
290(a,b)
291return a,b
291return a,b
292end
292end
293−local a,b,c,d = unlpack({1,2,3})
293+local a,b,c,d = unlpack({0x1,0x2,0x3})
294−assert(a == 1 and b == 2 and c == 3 and d == nil)
294+assert(a == 0x1 and b == 0x2 and c == 0x3 and d == nil)
295−a={1,2,3,4,false,10,"\u{61}\u{6c}\u{6f}",false,assert}
295+a={0x1,0x2,0x3,0x4,false,0xa,"\u{61}\u{6c}\u{6f}",false,assert}
296equaltab(pack(unlpack(a)),a)
296equaltab(pack(unlpack(a)),a)
297−equaltab(pack(unlpack(a),- 1),{1,- 1})
297+equaltab(pack(unlpack(a),- 0x1),{0x1,- 0x1})
298a,b,c,d=ret2(f()),ret2(f())
298a,b,c,d=ret2(f()),ret2(f())
299−assert(a == 1 and b == 1 and c == 2 and d == nil)
299+assert(a == 0x1 and b == 0x1 and c == 0x2 and d == nil)
300a,b,c,d=unlpack(pack(ret2(f()),ret2(f())))
300a,b,c,d=unlpack(pack(ret2(f()),ret2(f())))
301−assert(a == 1 and b == 1 and c == 2 and d == nil)
301+assert(a == 0x1 and b == 0x1 and c == 0x2 and d == nil)
302a,b,c,d=unlpack(pack(ret2(f()),(ret2(f()))))
302a,b,c,d=unlpack(pack(ret2(f()),(ret2(f()))))
303−assert(a == 1 and b == 1 and c == nil and d == nil)
303+assert(a == 0x1 and b == 0x1 and c == nil and d == nil)
304−a=ret2({unlpack({1,2,3}),unlpack({3,2,1}),unlpack({"\u{61}","\u{62}"})})
304+a=ret2({unlpack({0x1,0x2,0x3}),unlpack({0x3,0x2,0x1}),unlpack({"\u{61}","\u{62}"})})
305−assert(a[1] == 1 and a[2] == 3 and a[3] == "\u{61}" and a[4] == "\u{62}")
305+assert(a[0x1] == 0x1 and a[0x2] == 0x3 and a[0x3] == "\u{61}" and a[0x4] == "\u{62}")
306−rawget({},"\u{78}",1)
306+rawget({},"\u{78}",0x1)
307−rawset({},"\u{78}",1,2)
307+rawset({},"\u{78}",0x1,0x2)
308−assert(math.sin(1,2) == math.sin(1))
308+assert(math.sin(0x1,0x2) == math.sin(0x1))
309−table.sort({10,9,8,4,19,23,0,0},function (a,b)
309+table.sort({0xa,0x9,0x8,0x4,0x13,0x17,0x0,0x0},function (a,b)
310return a < b
310return a < b
311end,"\u{65}\u{78}\u{74}\u{72}\u{61}\u{20}\u{61}\u{72}\u{67}")
311end,"\u{65}\u{78}\u{74}\u{72}\u{61}\u{20}\u{61}\u{72}\u{67}")
312local x = "\u{2d}\u{2d}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{0}\u{0}\u{0}\u{a}\u{20}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{20}\u{2b}\u{20}\u{a}\u{32}\u{33}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{27}\u{68}\u{69}\u{27}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{0}\u{27}"
312local x = "\u{2d}\u{2d}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{0}\u{0}\u{0}\u{a}\u{20}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{20}\u{2b}\u{20}\u{a}\u{32}\u{33}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{27}\u{68}\u{69}\u{27}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{0}\u{27}"
313local function read1
313local function read1
314(x)
314(x)
315−local i = 0
315+local i = 0x0
316return function ()
316return function ()
317collectgarbage()
317collectgarbage()
318−i=i + 1
318+i=i + 0x1
319return string.sub(x,i,i)
319return string.sub(x,i,i)
320end
320end
321end
321end
@@ -324,7 +324,7 @@ local function cannotload
324assert(not a and string.find(b,msg))
324assert(not a and string.find(b,msg))
325end
325end
326a=assert(load(read1(x),"\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}","\u{74}",_G))
326a=assert(load(read1(x),"\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}","\u{74}",_G))
327−assert(a() == "\u{0}" and _G.x == 33)
327+assert(a() == "\u{0}" and _G.x == 0x21)
328assert(debug.getinfo(a).source == "\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}")
328assert(debug.getinfo(a).source == "\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}")
329cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{74}\u{65}\u{78}\u{74}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(read1(x),"\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}","\u{62}",{}))
329cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{74}\u{65}\u{78}\u{74}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(read1(x),"\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}","\u{62}",{}))
330cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{74}\u{65}\u{78}\u{74}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(x,"\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}","\u{62}"))
330cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{74}\u{65}\u{78}\u{74}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(x,"\u{6d}\u{6f}\u{64}\u{6e}\u{61}\u{6d}\u{65}","\u{62}"))
@@ -337,13 +337,13 @@ return true
337end))
337end))
338local t = {nil,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{33}"}
338local t = {nil,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{33}"}
339f,msg=load(function ()
339f,msg=load(function ()
340−return table.remove(t,1)
340+return table.remove(t,0x1)
341end)
341end)
342assert(f() == nil)
342assert(f() == nil)
343f=load(string.dump(function ()
343f=load(string.dump(function ()
344−return 1
344+return 0x1
345end),nil,"\u{62}",{})
345end),nil,"\u{62}",{})
346−assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and f() == 1)
346+assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and f() == 0x1)
347do
347do
348local f = string.dump(function ()
348local f = string.dump(function ()
349return "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
349return "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
@@ -353,7 +353,7 @@ assert(f() == "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30
353end
353end
354x=string.dump(load("\u{78}\u{20}\u{3d}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}"))
354x=string.dump(load("\u{78}\u{20}\u{3d}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}"))
355a=assert(load(read1(x),nil,"\u{62}"))
355a=assert(load(read1(x),nil,"\u{62}"))
356−assert(a() == 1 and _G.x == 1)
356+assert(a() == 0x1 and _G.x == 0x1)
357cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(read1(x),nil,"\u{74}"))
357cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(read1(x),nil,"\u{74}"))
358cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(x,nil,"\u{74}"))
358cannotload("\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}",load(x,nil,"\u{74}"))
359_G.x=nil
359_G.x=nil
@@ -363,10 +363,10 @@ cannotload("\u{75}\u{6e}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u
363cannotload("\u{68}\u{68}\u{69}",load(function ()
363cannotload("\u{68}\u{68}\u{69}",load(function ()
364error("\u{68}\u{68}\u{69}")
364error("\u{68}\u{68}\u{69}")
365end))
365end))
366−assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{45}\u{4e}\u{56}",nil,nil,123)() == 123)
366+assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{45}\u{4e}\u{56}",nil,nil,0x7b)() == 0x7b)
367local x
367local x
368;
368;
369−XX=123
369+XX=0x7b
370local function h
370local function h
371()
371()
372local y = x
372local y = x
@@ -374,117 +374,117 @@ return XX
374end
374end
375local d = string.dump(h)
375local d = string.dump(h)
376x=load(d,"","\u{62}")
376x=load(d,"","\u{62}")
377−assert(debug.getupvalue(x,2) == "\u{5f}\u{45}\u{4e}\u{56}")
377+assert(debug.getupvalue(x,0x2) == "\u{5f}\u{45}\u{4e}\u{56}")
378−debug.setupvalue(x,2,_G)
378+debug.setupvalue(x,0x2,_G)
379−assert(x() == 123)
379+assert(x() == 0x7b)
380−assert(assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{58}\u{58}\u{20}\u{2b}\u{20}\u{2e}\u{2e}\u{2e}",nil,nil,{["\u{58}\u{58}"] = 13}))(4) == 17)
380+assert(assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{58}\u{58}\u{20}\u{2b}\u{20}\u{2e}\u{2e}\u{2e}",nil,nil,{["\u{58}\u{58}"] = 0xd}))(0x4) == 0x11)
381XX=nil
381XX=nil
382x="\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{78}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{79}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{7a}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{2b}\u{79}\u{2b}\u{7a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}"
382x="\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{78}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{79}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{7a}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{2b}\u{79}\u{2b}\u{7a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}"
383a=assert(load(read1(x),"\u{72}\u{65}\u{61}\u{64}","\u{74}"))
383a=assert(load(read1(x),"\u{72}\u{65}\u{61}\u{64}","\u{74}"))
384−assert(a()(2)(3)(10) == 15)
384+assert(a()(0x2)(0x3)(0xa) == 0xf)
385x=string.dump(a)
385x=string.dump(a)
386a=assert(load(read1(x),"\u{72}\u{65}\u{61}\u{64}","\u{62}"))
386a=assert(load(read1(x),"\u{72}\u{65}\u{61}\u{64}","\u{62}"))
387−assert(a()(2)(3)(10) == 15)
387+assert(a()(0x2)(0x3)(0xa) == 0xf)
388−local a,b = 20,30
388+local a,b = 0x14,0x1e
389x=load(string.dump(function (x)
389x=load(string.dump(function (x)
390if x == "\u{73}\u{65}\u{74}" then
390if x == "\u{73}\u{65}\u{74}" then
391−a=10 + b
391+a=0xa + b
392;
392;
393−b=b + 1
393+b=b + 0x1
394else
394else
395return a
395return a
396end
396end
397end),"","\u{62}",nil)
397end),"","\u{62}",nil)
398assert(x() == nil)
398assert(x() == nil)
399−assert(debug.setupvalue(x,1,"\u{68}\u{69}") == "\u{61}")
399+assert(debug.setupvalue(x,0x1,"\u{68}\u{69}") == "\u{61}")
400assert(x() == "\u{68}\u{69}")
400assert(x() == "\u{68}\u{69}")
401−assert(debug.setupvalue(x,2,13) == "\u{62}")
401+assert(debug.setupvalue(x,0x2,0xd) == "\u{62}")
402−assert(not debug.setupvalue(x,3,10))
402+assert(not debug.setupvalue(x,0x3,0xa))
403x("\u{73}\u{65}\u{74}")
403x("\u{73}\u{65}\u{74}")
404−assert(x() == 23)
404+assert(x() == 0x17)
405x("\u{73}\u{65}\u{74}")
405x("\u{73}\u{65}\u{74}")
406−assert(x() == 24)
406+assert(x() == 0x18)
407do
407do
408−local nup = 200
408+local nup = 0xc8
409local prog = {"\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{31}"}
409local prog = {"\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{31}"}
410−for i = 2, nup
410+for i = 0x2, nup
411do
411do
412−prog[# prog + 1]="\u{2c}\u{20}\u{61}" .. i
412+prog[# prog + 0x1]="\u{2c}\u{20}\u{61}" .. i
413end
413end
414−prog[# prog + 1]="\u{20}\u{3d}\u{20}\u{31}"
414+prog[# prog + 0x1]="\u{20}\u{3d}\u{20}\u{31}"
415−for i = 2, nup
415+for i = 0x2, nup
416do
416do
417−prog[# prog + 1]="\u{2c}\u{20}" .. i
417+prog[# prog + 0x1]="\u{2c}\u{20}" .. i
418end
418end
419−local sum = 1
419+local sum = 0x1
420−prog[# prog + 1]="\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{31}"
420+prog[# prog + 0x1]="\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{31}"
421−for i = 2, nup
421+for i = 0x2, nup
422do
422do
423−prog[# prog + 1]="\u{20}\u{2b}\u{20}\u{61}" .. i
423+prog[# prog + 0x1]="\u{20}\u{2b}\u{20}\u{61}" .. i
424;
424;
425sum=sum + i
425sum=sum + i
426end
426end
427−prog[# prog + 1]="\u{20}\u{65}\u{6e}\u{64}"
427+prog[# prog + 0x1]="\u{20}\u{65}\u{6e}\u{64}"
428prog=table.concat(prog)
428prog=table.concat(prog)
429local f = assert(load(prog))()
429local f = assert(load(prog))()
430assert(f() == sum)
430assert(f() == sum)
431f=load(string.dump(f))
431f=load(string.dump(f))
432−local a = 10
432+local a = 0xa
433local h = function ()
433local h = function ()
434return a
434return a
435end
435end
436−for i = 1, nup
436+for i = 0x1, nup
437do
437do
438−debug.upvaluejoin(f,i,h,1)
438+debug.upvaluejoin(f,i,h,0x1)
439end
439end
440−assert(f() == 10 * nup)
440+assert(f() == 0xa * nup)
441end
441end
442do
442do
443−local t = {["\u{78}"] = 1}
443+local t = {["\u{78}"] = 0x1}
444function t:_012345678901234567890123456789012345678901234567890123456789()
444function t:_012345678901234567890123456789012345678901234567890123456789()
445return self.x
445return self.x
446end
446end
447−assert(t:_012345678901234567890123456789012345678901234567890123456789() == 1)
447+assert(t:_012345678901234567890123456789012345678901234567890123456789() == 0x1)
448end
448end
449assert((function ()
449assert((function ()
450return nil
450return nil
451−end)(4) == nil)
451+end)(0x4) == nil)
452assert((function ()
452assert((function ()
453local a
453local a
454;
454;
455return a
455return a
456−end)(4) == nil)
456+end)(0x4) == nil)
457assert((function (a)
457assert((function (a)
458return a
458return a
459end)() == nil)
459end)() == nil)
460print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}\u{73}")
460print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}\u{73}")
461do
461do
462−local header = string.pack("\u{63}\u{34}\u{42}\u{42}\u{63}\u{36}\u{42}\u{42}\u{42}","\u{1b}\u{4c}\u{75}\u{61}",84,0,"\u{19}\u{93}\u{d}\u{a}\u{1a}\u{a}",4,string.packsize("\u{6a}"),string.packsize("\u{6e}"))
462+local header = string.pack("\u{63}\u{34}\u{42}\u{42}\u{63}\u{36}\u{42}\u{42}\u{42}","\u{1b}\u{4c}\u{75}\u{61}",0x54,0x0,"\u{19}\u{93}\u{d}\u{a}\u{1a}\u{a}",0x4,string.packsize("\u{6a}"),string.packsize("\u{6e}"))
463local c = string.dump(function ()
463local c = string.dump(function ()
464−local a = 1
464+local a = 0x1
465;
465;
466−local b = 3
466+local b = 0x3
467;
467;
468local f = function ()
468local f = function ()
469return a + b + _ENV.c
469return a + b + _ENV.c
470end
470end
471local s1 = "\u{61}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}"
471local s1 = "\u{61}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}"
472local s2 = "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}"
472local s2 = "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}"
473−return a + b * 3
473+return a + b * 0x3
474end)
474end)
475−assert(assert(load(c))() == 10)
475+assert(assert(load(c))() == 0xa)
476−assert(string.sub(c,1,# header) == header)
476+assert(string.sub(c,0x1,# header) == header)
477−local ci,cn = string.unpack("\u{6a}\u{6e}",c,# header + 1)
477+local ci,cn = string.unpack("\u{6a}\u{6e}",c,# header + 0x1)
478−assert(ci == 22136 and cn == 370.5)
478+assert(ci == 0x5678 and cn == 370.5)
479−for i = 1, # header
479+for i = 0x1, # header
480do
480do
481−local s = string.sub(c,1,i - 1) .. string.char(string.byte(string.sub(c,i,i)) + 1) .. string.sub(c,i + 1,- 1)
481+local s = string.sub(c,0x1,i - 0x1) .. string.char(string.byte(string.sub(c,i,i)) + 0x1) .. string.sub(c,i + 0x1,- 0x1)
482assert(# s == # c)
482assert(# s == # c)
483assert(not load(s))
483assert(not load(s))
484end
484end
485−for i = 1, # c - 1
485+for i = 0x1, # c - 0x1
486do
486do
487−local st,msg = load(string.sub(c,1,i))
487+local st,msg = load(string.sub(c,0x1,i))
488assert(not st and string.find(msg,"\u{74}\u{72}\u{75}\u{6e}\u{63}\u{61}\u{74}\u{65}\u{64}"))
488assert(not st and string.find(msg,"\u{74}\u{72}\u{75}\u{6e}\u{63}\u{61}\u{74}\u{65}\u{64}"))
489end
489end
490end
490end
zod/luau/res/lua/cycled/closure.lua+104−104
@@ -1,14 +1,14 @@
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{73}")
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{75}\u{72}\u{65}\u{73}")
2−local A,B = 0,{["\u{67}"] = 10}
2+local A,B = 0x0,{["\u{67}"] = 0xa}
3local function f
3local function f
4(x)
4(x)
5local a = {}
5local a = {}
6−for i = 1, 1000
6+for i = 0x1, 0x3e8
7do
7do
8−local y = 0
8+local y = 0x0
9do
9do
10a[i]=function ()
10a[i]=function ()
11−B.g=B.g + 1
11+B.g=B.g + 0x1
12;
12;
13y=y + x
13y=y + x
14;
14;
@@ -20,43 +20,43 @@ local dummy = function ()
20return a[A]
20return a[A]
21end
21end
22collectgarbage()
22collectgarbage()
23−A=1
23+A=0x1
24;
24;
25−assert(dummy() == a[1])
25+assert(dummy() == a[0x1])
26;
26;
27−A=0
27+A=0x0
28;
28;
29−assert(a[1]() == x)
29+assert(a[0x1]() == x)
30−assert(a[3]() == x)
30+assert(a[0x3]() == x)
31collectgarbage()
31collectgarbage()
32−assert(B.g == 12)
32+assert(B.g == 0xc)
33return a
33return a
34end
34end
35−local a = f(10)
35+local a = f(0xa)
36−local x = {[1] = {}}
36+local x = {[0x1] = {}}
37setmetatable(x,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
37setmetatable(x,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
38−while x[1] do
38+while x[0x1] do
39local a = A .. A .. A .. A
39local a = A .. A .. A .. A
40−A=A + 1
40+A=A + 0x1
41end
41end
42−assert(a[1]() == 20 + A)
42+assert(a[0x1]() == 0x14 + A)
43−assert(a[1]() == 30 + A)
43+assert(a[0x1]() == 0x1e + A)
44−assert(a[2]() == 10 + A)
44+assert(a[0x2]() == 0xa + A)
45collectgarbage()
45collectgarbage()
46−assert(a[2]() == 20 + A)
46+assert(a[0x2]() == 0x14 + A)
47−assert(a[2]() == 30 + A)
47+assert(a[0x2]() == 0x1e + A)
48−assert(a[3]() == 20 + A)
48+assert(a[0x3]() == 0x14 + A)
49−assert(a[8]() == 10 + A)
49+assert(a[0x8]() == 0xa + A)
50assert(getmetatable(x).__mode == "\u{6b}\u{76}")
50assert(getmetatable(x).__mode == "\u{6b}\u{76}")
51−assert(B.g == 19)
51+assert(B.g == 0x13)
52a={}
52a={}
53−for i = 1, 5
53+for i = 0x1, 0x5
54do
54do
55a[i]=function (x)
55a[i]=function (x)
56return i + a + _ENV
56return i + a + _ENV
57end
57end
58end
58end
59−assert(a[3] ~= a[4] and a[4] ~= a[5])
59+assert(a[0x3] ~= a[0x4] and a[0x4] ~= a[0x5])
60do
60do
61local a = function (x)
61local a = function (x)
62return math.sin(_ENV[x])
62return math.sin(_ENV[x])
@@ -68,26 +68,26 @@ end
68assert(f() == f())
68assert(f() == f())
69end
69end
70a={}
70a={}
71−for i = 1, 10
71+for i = 0x1, 0xa
72do
72do
73a[i]={["\u{73}\u{65}\u{74}"] = function (x)
73a[i]={["\u{73}\u{65}\u{74}"] = function (x)
74i=x
74i=x
75end,["\u{67}\u{65}\u{74}"] = function ()
75end,["\u{67}\u{65}\u{74}"] = function ()
76return i
76return i
77end}
77end}
78−if i == 3 then
78+if i == 0x3 then
79break
79break
80end
80end
81end
81end
82−assert(a[4] == undef)
82+assert(a[0x4] == undef)
83−a[1].set(10)
83+a[0x1].set(0xa)
84−assert(a[2].get() == 2)
84+assert(a[0x2].get() == 0x2)
85−a[2].set("\u{61}")
85+a[0x2].set("\u{61}")
86−assert(a[3].get() == 3)
86+assert(a[0x3].get() == 0x3)
87−assert(a[2].get() == "\u{61}")
87+assert(a[0x2].get() == "\u{61}")
88a={}
88a={}
89local t = {"\u{61}","\u{62}"}
89local t = {"\u{61}","\u{62}"}
90−for i = 1, # t
90+for i = 0x1, # t
91do
91do
92local k = t[i]
92local k = t[i]
93a[i]={["\u{73}\u{65}\u{74}"] = function (x,y)
93a[i]={["\u{73}\u{65}\u{74}"] = function (x,y)
@@ -97,28 +97,28 @@ k=y
97end,["\u{67}\u{65}\u{74}"] = function ()
97end,["\u{67}\u{65}\u{74}"] = function ()
98return i,k
98return i,k
99end}
99end}
100−if i == 2 then
100+if i == 0x2 then
101break
101break
102end
102end
103end
103end
104−a[1].set(10,20)
104+a[0x1].set(0xa,0x14)
105−local r,s = a[2].get()
105+local r,s = a[0x2].get()
106−assert(r == 2 and s == "\u{62}")
106+assert(r == 0x2 and s == "\u{62}")
107−r,s=a[1].get()
107+r,s=a[0x1].get()
108−assert(r == 10 and s == 20)
108+assert(r == 0xa and s == 0x14)
109−a[2].set("\u{61}","\u{62}")
109+a[0x2].set("\u{61}","\u{62}")
110−r,s=a[2].get()
110+r,s=a[0x2].get()
111assert(r == "\u{61}" and s == "\u{62}")
111assert(r == "\u{61}" and s == "\u{62}")
112local f
112local f
113−for i = 1, 3
113+for i = 0x1, 0x3
114do
114do
115f=function ()
115f=function ()
116return i
116return i
117end
117end
118break
118break
119end
119end
120−assert(f() == 1)
120+assert(f() == 0x1)
121−for k = 1, # t
121+for k = 0x1, # t
122do
122do
123local v = t[k]
123local v = t[k]
124f=function ()
124f=function ()
@@ -126,13 +126,13 @@ return k,v
126end
126end
127break
127break
128end
128end
129−assert(({f()})[1] == 1)
129+assert(({f()})[0x1] == 0x1)
130−assert(({f()})[2] == "\u{61}")
130+assert(({f()})[0x2] == "\u{61}")
131local b
131local b
132function f(x)
132function f(x)
133−local first = 1
133+local first = 0x1
134−while 1 do
134+while 0x1 do
135−if x == 3 and not first then
135+if x == 0x3 and not first then
136return
136return
137end
137end
138local a = "\u{78}\u{75}\u{78}\u{75}"
138local a = "\u{78}\u{75}\u{78}\u{75}"
@@ -143,35 +143,35 @@ else
143return a
143return a
144end
144end
145end
145end
146−if x == 1 then
146+if x == 0x1 then
147do
147do
148break
148break
149end
149end
150−elseif x == 2 then
150+elseif x == 0x2 then
151return
151return
152else
152else
153−if x ~= 3 then
153+if x ~= 0x3 then
154error()
154error()
155end
155end
156end
156end
157first=nil
157first=nil
158end
158end
159end
159end
160−for i = 1, 3
160+for i = 0x1, 0x3
161do
161do
162f(i)
162f(i)
163assert(b("\u{67}\u{65}\u{74}") == "\u{78}\u{75}\u{78}\u{75}")
163assert(b("\u{67}\u{65}\u{74}") == "\u{78}\u{75}\u{78}\u{75}")
164−b("\u{73}\u{65}\u{74}",10)
164+b("\u{73}\u{65}\u{74}",0xa)
165;
165;
166−assert(b("\u{67}\u{65}\u{74}") == 10 + i)
166+assert(b("\u{67}\u{65}\u{74}") == 0xa + i)
167b=nil
167b=nil
168end
168end
169−pcall(f,4)
169+pcall(f,0x4)
170;
170;
171assert(b("\u{67}\u{65}\u{74}") == "\u{78}\u{75}\u{78}\u{75}")
171assert(b("\u{67}\u{65}\u{74}") == "\u{78}\u{75}\u{78}\u{75}")
172−b("\u{73}\u{65}\u{74}",10)
172+b("\u{73}\u{65}\u{74}",0xa)
173;
173;
174−assert(b("\u{67}\u{65}\u{74}") == 14)
174+assert(b("\u{67}\u{65}\u{74}") == 0xe)
175local y,w
175local y,w
176function f(x)
176function f(x)
177return function (y)
177return function (y)
@@ -180,14 +180,14 @@ return w + x + y + z
180end
180end
181end
181end
182end
182end
183−y=f(10)
183+y=f(0xa)
184w=1.345
184w=1.345
185−assert(y(20)(30) == 60 + w)
185+assert(y(0x14)(0x1e) == 0x3c + w)
186do
186do
187local X,Y
187local X,Y
188−local a = math.sin(0)
188+local a = math.sin(0x0)
189while a do
189while a do
190−local b = 10
190+local b = 0xa
191X=function ()
191X=function ()
192return b
192return b
193end
193end
@@ -196,29 +196,29 @@ break
196end
196end
197end
197end
198do
198do
199−local b = 20
199+local b = 0x14
200Y=function ()
200Y=function ()
201return b
201return b
202end
202end
203end
203end
204−assert(X() == 10 and Y() == 20)
204+assert(X() == 0xa and Y() == 0x14)
205end
205end
206local a = {}
206local a = {}
207−local i = 1
207+local i = 0x1
208repeat
208repeat
209local x = i
209local x = i
210a[i]=function ()
210a[i]=function ()
211−i=x + 1
211+i=x + 0x1
212;
212;
213return x
213return x
214end
214end
215−until i > 10 or a[i]() ~= x
215+until i > 0xa or a[i]() ~= x
216−assert(i == 11 and a[1]() == 1 and a[3]() == 3 and i == 4)
216+assert(i == 0xb and a[0x1]() == 0x1 and a[0x3]() == 0x3 and i == 0x4)
217a={}
217a={}
218−for i = 1, 10
218+for i = 0x1, 0xa
219do
219do
220−if i % 3 == 0 then
220+if i % 0x3 == 0x0 then
221−local y = 0
221+local y = 0x0
222a[i]=function (x)
222a[i]=function (x)
223local t = y
223local t = y
224;
224;
@@ -226,11 +226,11 @@ y=x
226;
226;
227return t
227return t
228end
228end
229−elseif i % 3 == 1 then
229+elseif i % 0x3 == 0x1 then
230goto L1
230goto L1
231error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
231error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
232::L1::
232::L1::
233−local y = 1
233+local y = 0x1
234a[i]=function (x)
234a[i]=function (x)
235local t = y
235local t = y
236;
236;
@@ -238,7 +238,7 @@ y=x
238;
238;
239return t
239return t
240end
240end
241−elseif i % 3 == 2 then
241+elseif i % 0x3 == 0x2 then
242local t
242local t
243goto l4
243goto l4
244::l4a::
244::l4a::
@@ -247,7 +247,7 @@ a[i]=t
247goto l4b
247goto l4b
248error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
248error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
249::l4::
249::l4::
250−local y = 2
250+local y = 0x2
251t=function (x)
251t=function (x)
252local t = y
252local t = y
253;
253;
@@ -260,9 +260,9 @@ error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\
260::l4b::
260::l4b::
261end
261end
262end
262end
263−for i = 1, 10
263+for i = 0x1, 0xa
264do
264do
265−assert(a[i](i * 10) == i % 3 and a[i]() == i * 10)
265+assert(a[i](i * 0xa) == i % 0x3 and a[i]() == i * 0xa)
266end
266end
267print("\u{2b}")
267print("\u{2b}")
268local function t
268local function t
@@ -273,9 +273,9 @@ assert(a == "\u{74}\u{65}\u{73}\u{74}" and b == "\u{4f}\u{4b}")
273end
273end
274local function v
274local function v
275(f, ...)
275(f, ...)
276−c("\u{74}\u{65}\u{73}\u{74}",f() ~= 1 and "\u{46}\u{41}\u{49}\u{4c}\u{45}\u{44}" or "\u{4f}\u{4b}")
276+c("\u{74}\u{65}\u{73}\u{74}",f() ~= 0x1 and "\u{46}\u{41}\u{49}\u{4c}\u{45}\u{44}" or "\u{4f}\u{4b}")
277end
277end
278−local x = 1
278+local x = 0x1
279return v(function ()
279return v(function ()
280return x
280return x
281end)
281end)
@@ -284,7 +284,7 @@ t()
284local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
284local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
285local foo1,foo2,foo3
285local foo1,foo2,foo3
286do
286do
287−local a,b,c = 3,5,7
287+local a,b,c = 0x3,0x5,0x7
288foo1=function ()
288foo1=function ()
289return a + b
289return a + b
290end
290end
@@ -294,34 +294,34 @@ return b + a
294end
294end
295;
295;
296do
296do
297−local a = 10
297+local a = 0xa
298foo3=function ()
298foo3=function ()
299return a + b
299return a + b
300end
300end
301;
301;
302end
302end
303end
303end
304−assert(debug.upvalueid(foo1,1))
304+assert(debug.upvalueid(foo1,0x1))
305−assert(debug.upvalueid(foo1,2))
305+assert(debug.upvalueid(foo1,0x2))
306−assert(not debug.upvalueid(foo1,3))
306+assert(not debug.upvalueid(foo1,0x3))
307−assert(debug.upvalueid(foo1,1) == debug.upvalueid(foo2,2))
307+assert(debug.upvalueid(foo1,0x1) == debug.upvalueid(foo2,0x2))
308−assert(debug.upvalueid(foo1,2) == debug.upvalueid(foo2,1))
308+assert(debug.upvalueid(foo1,0x2) == debug.upvalueid(foo2,0x1))
309−assert(debug.upvalueid(foo3,1))
309+assert(debug.upvalueid(foo3,0x1))
310−assert(debug.upvalueid(foo1,1) ~= debug.upvalueid(foo3,1))
310+assert(debug.upvalueid(foo1,0x1) ~= debug.upvalueid(foo3,0x1))
311−assert(debug.upvalueid(foo1,2) == debug.upvalueid(foo3,2))
311+assert(debug.upvalueid(foo1,0x2) == debug.upvalueid(foo3,0x2))
312−assert(debug.upvalueid(string.gmatch("\u{78}","\u{78}"),1) ~= nil)
312+assert(debug.upvalueid(string.gmatch("\u{78}","\u{78}"),0x1) ~= nil)
313−assert(foo1() == 3 + 5 and foo2() == 5 + 3)
313+assert(foo1() == 0x3 + 0x5 and foo2() == 0x5 + 0x3)
314−debug.upvaluejoin(foo1,2,foo2,2)
314+debug.upvaluejoin(foo1,0x2,foo2,0x2)
315−assert(foo1() == 3 + 3 and foo2() == 5 + 3)
315+assert(foo1() == 0x3 + 0x3 and foo2() == 0x5 + 0x3)
316−assert(foo3() == 10 + 5)
316+assert(foo3() == 0xa + 0x5)
317−debug.upvaluejoin(foo3,2,foo2,1)
317+debug.upvaluejoin(foo3,0x2,foo2,0x1)
318−assert(foo3() == 10 + 5)
318+assert(foo3() == 0xa + 0x5)
319−debug.upvaluejoin(foo3,2,foo2,2)
319+debug.upvaluejoin(foo3,0x2,foo2,0x2)
320−assert(foo3() == 10 + 3)
320+assert(foo3() == 0xa + 0x3)
321−assert(not pcall(debug.upvaluejoin,foo1,3,foo2,1))
321+assert(not pcall(debug.upvaluejoin,foo1,0x3,foo2,0x1))
322−assert(not pcall(debug.upvaluejoin,foo1,1,foo2,3))
322+assert(not pcall(debug.upvaluejoin,foo1,0x1,foo2,0x3))
323−assert(not pcall(debug.upvaluejoin,foo1,0,foo2,1))
323+assert(not pcall(debug.upvaluejoin,foo1,0x0,foo2,0x1))
324−assert(not pcall(debug.upvaluejoin,print,1,foo2,1))
324+assert(not pcall(debug.upvaluejoin,print,0x1,foo2,0x1))
325−assert(not pcall(debug.upvaluejoin,{},1,foo2,1))
325+assert(not pcall(debug.upvaluejoin,{},0x1,foo2,0x1))
326−assert(not pcall(debug.upvaluejoin,foo1,1,print,1))
326+assert(not pcall(debug.upvaluejoin,foo1,0x1,print,0x1))
327print("\u{4f}\u{4b}")
327print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/code.lua+161−161
@@ -3,15 +3,15 @@ if T == nil then
3return
3return
4end
4end
5print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{64}\u{65}\u{20}\u{67}\u{65}\u{6e}\u{65}\u{72}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6d}\u{69}\u{7a}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}")
5print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{64}\u{65}\u{20}\u{67}\u{65}\u{6e}\u{65}\u{72}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6d}\u{69}\u{7a}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}")
6−local k0aux <const> = 0
6+local k0aux <const> = 0x0
7local k0 <const> = k0aux
7local k0 <const> = k0aux
8−local k1 <const> = 1
8+local k1 <const> = 0x1
9−local k3 <const> = 3
9+local k3 <const> = 0x3
10local k6 <const> = k3 + (k3 << k0)
10local k6 <const> = k3 + (k3 << k0)
11−local kFF0 <const> = 4080
11+local kFF0 <const> = 0xff0
12local k3_78 <const> = 3.78
12local k3_78 <const> = 3.78
13−local x,k3_78_4 <const> = 10,k3_78 / 4
13+local x,k3_78_4 <const> = 0xa,k3_78 / 0x4
14−assert(x == 10)
14+assert(x == 0xa)
15local kx <const> = "\u{78}"
15local kx <const> = "\u{78}"
16local kTrue <const> = true
16local kTrue <const> = true
17local kFalse <const> = false
17local kFalse <const> = false
@@ -29,7 +29,7 @@ local function checkKlist
29(func,list)
29(func,list)
30local k = T.listk(func)
30local k = T.listk(func)
31assert(# k == # list)
31assert(# k == # list)
32−for i = 1, # k
32+for i = 0x1, # k
33do
33do
34assert(k[i] == list[i] and math.type(k[i]) == math.type(list[i]))
34assert(k[i] == list[i] and math.type(k[i]) == math.type(list[i]))
35end
35end
@@ -39,79 +39,79 @@ local function foo
39local a
39local a
40a=k3
40a=k3
41;
41;
42−a=0
42+a=0x0
43;
43;
44a=0.0
44a=0.0
45;
45;
46−a=- 7 + 7
46+a=- 0x7 + 0x7
47−a=k3_78 / 4
47+a=k3_78 / 0x4
48;
48;
49a=k3_78_4
49a=k3_78_4
50−a=- k3_78 / 4
50+a=- k3_78 / 0x4
51;
51;
52−a=k3_78 / 4
52+a=k3_78 / 0x4
53;
53;
54−a=- 3.78 / 4
54+a=- 3.78 / 0x4
55−a=- 3.79 / 4
55+a=- 3.79 / 0x4
56;
56;
57a=0.0
57a=0.0
58;
58;
59−a=- 0
59+a=- 0x0
60;
60;
61a=k3
61a=k3
62;
62;
63a=3.0
63a=3.0
64;
64;
65−a=3
65+a=0x3
66;
66;
67a=3.0
67a=3.0
68end
68end
69−checkKlist(foo,{3.78 / 4,- 3.78 / 4,- 3.79 / 4})
69+checkKlist(foo,{3.78 / 0x4,- 3.78 / 0x4,- 3.79 / 0x4})
70foo=function (f,a)
70foo=function (f,a)
71−f(100 * 1000)
71+f(0x64 * 0x3e8)
72−f(100.0 * 1000)
72+f(100.0 * 0x3e8)
73−f(- 100 * 1000)
73+f(- 0x64 * 0x3e8)
74−f(- 100 * 1e3)
74+f(- 0x64 * 1e3)
75−f(100000)
75+f(0x186a0)
76f(1e5)
76f(1e5)
77−f(- 100000)
77+f(- 0x186a0)
78f(- 1e5)
78f(- 1e5)
79end
79end
80−checkKlist(foo,{100000,1e5,- 100000,- 1e5})
80+checkKlist(foo,{0x186a0,1e5,- 0x186a0,- 1e5})
81foo=function (t,a)
81foo=function (t,a)
82−t[a]=1
82+t[a]=0x1
83;
83;
84t[a]=1.0
84t[a]=1.0
85−t[a]=1
85+t[a]=0x1
86;
86;
87t[a]=1.0
87t[a]=1.0
88−t[a]=2
88+t[a]=0x2
89;
89;
90t[a]=2.0
90t[a]=2.0
91−t[a]=0
91+t[a]=0x0
92;
92;
93t[a]=0.0
93t[a]=0.0
94−t[a]=1
94+t[a]=0x1
95;
95;
96t[a]=1.0
96t[a]=1.0
97−t[a]=2
97+t[a]=0x2
98;
98;
99t[a]=2.0
99t[a]=2.0
100−t[a]=0
100+t[a]=0x0
101;
101;
102t[a]=0.0
102t[a]=0.0
103end
103end
104−checkKlist(foo,{1,1.0,2,2.0,0,0.0})
104+checkKlist(foo,{0x1,1.0,0x2,2.0,0x0,0.0})
105local function check
105local function check
106(f, ...)
106(f, ...)
107local arg = {...}
107local arg = {...}
108local c = T.listcode(f)
108local c = T.listcode(f)
109−for i = 1, # arg
109+for i = 0x1, # arg
110do
110do
111local opcode = string.match(c[i],"\u{25}\u{75}\u{25}\u{77}\u{2b}")
111local opcode = string.match(c[i],"\u{25}\u{75}\u{25}\u{77}\u{2b}")
112assert(arg[i] == opcode)
112assert(arg[i] == opcode)
113end
113end
114−assert(c[# arg + 2] == undef)
114+assert(c[# arg + 0x2] == undef)
115end
115end
116local function checkR
116local function checkR
117(f,p,r, ...)
117(f,p,r, ...)
@@ -124,7 +124,7 @@ local function checkequal
124a=T.listcode(a)
124a=T.listcode(a)
125b=T.listcode(b)
125b=T.listcode(b)
126assert(# a == # b)
126assert(# a == # b)
127−for i = 1, # a
127+for i = 0x1, # a
128do
128do
129a[i]=string.gsub(a[i],"\u{25}\u{62}\u{28}\u{29}","")
129a[i]=string.gsub(a[i],"\u{25}\u{62}\u{28}\u{29}","")
130b[i]=string.gsub(b[i],"\u{25}\u{62}\u{28}\u{29}","")
130b[i]=string.gsub(b[i],"\u{25}\u{62}\u{28}\u{29}","")
@@ -162,7 +162,7 @@ c=nil
162;
162;
163end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
163end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
164check(function ()
164check(function ()
165−local a,b,c,d = 1,1,1,1
165+local a,b,c,d = 0x1,0x1,0x1,0x1
166d=nil
166d=nil
167;
167;
168c=nil
168c=nil
@@ -172,7 +172,7 @@ b=nil
172a=nil
172a=nil
173end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
173end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
174do
174do
175−local a,b,c,d = 1,1,1,1
175+local a,b,c,d = 0x1,0x1,0x1,0x1
176d=nil
176d=nil
177;
177;
178c=nil
178c=nil
@@ -187,17 +187,17 @@ return a
187end,"\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
187end,"\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
188check(function ()
188check(function ()
189while kTrue do
189while kTrue do
190−local a = - 1
190+local a = - 0x1
191end
191end
192end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4a}\u{4d}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
192end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4a}\u{4d}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
193check(function ()
193check(function ()
194−while 1 do
194+while 0x1 do
195−local a = - 1
195+local a = - 0x1
196end
196end
197end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4a}\u{4d}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
197end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4a}\u{4d}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
198check(function ()
198check(function ()
199repeat
199repeat
200−local x = 1
200+local x = 0x1
201until true
201until true
202end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
202end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
203check(function (a,b,c,d)
203check(function (a,b,c,d)
@@ -228,86 +228,86 @@ a.x=b
228a[b]="\u{78}"
228a[b]="\u{78}"
229end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{53}\u{45}\u{54}\u{46}\u{49}\u{45}\u{4c}\u{44}","\u{53}\u{45}\u{54}\u{46}\u{49}\u{45}\u{4c}\u{44}","\u{53}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
229end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{53}\u{45}\u{54}\u{46}\u{49}\u{45}\u{4c}\u{44}","\u{53}\u{45}\u{54}\u{46}\u{49}\u{45}\u{4c}\u{44}","\u{53}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
230check(function (a)
230check(function (a)
231−local k255 <const> = 255
231+local k255 <const> = 0xff
232−a[1]=a[100]
232+a[0x1]=a[0x64]
233−a[k255]=a[256]
233+a[k255]=a[0x100]
234−a[256]=5
234+a[0x100]=0x5
235end,"\u{47}\u{45}\u{54}\u{49}","\u{53}\u{45}\u{54}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{47}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{53}\u{45}\u{54}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{53}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
235end,"\u{47}\u{45}\u{54}\u{49}","\u{53}\u{45}\u{54}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{47}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{53}\u{45}\u{54}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{53}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
236check(function ()
236check(function ()
237local a,b
237local a,b
238a=a - a
238a=a - a
239b=a / a
239b=a / a
240−b=5 - 4
240+b=0x5 - 0x4
241end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{53}\u{55}\u{42}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{44}\u{49}\u{56}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
241end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{53}\u{55}\u{42}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{44}\u{49}\u{56}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
242check(function ()
242check(function ()
243local a,b
243local a,b
244a[kTrue]=false
244a[kTrue]=false
245end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{4c}\u{4f}\u{41}\u{44}\u{54}\u{52}\u{55}\u{45}","\u{53}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
245end,"\u{4c}\u{4f}\u{41}\u{44}\u{4e}\u{49}\u{4c}","\u{4c}\u{4f}\u{41}\u{44}\u{54}\u{52}\u{55}\u{45}","\u{53}\u{45}\u{54}\u{54}\u{41}\u{42}\u{4c}\u{45}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
246checkR(function (a)
246checkR(function (a)
247−if a == 1 then
247+if a == 0x1 then
248−return 2
248+return 0x2
249end
249end
250−end,1,2,"\u{45}\u{51}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
250+end,0x1,0x2,"\u{45}\u{51}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
251checkR(function (a)
251checkR(function (a)
252if - 4.0 == a then
252if - 4.0 == a then
253−return 2
253+return 0x2
254end
254end
255−end,- 4,2,"\u{45}\u{51}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
255+end,- 0x4,0x2,"\u{45}\u{51}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
256checkR(function (a)
256checkR(function (a)
257if a == "\u{68}\u{69}" then
257if a == "\u{68}\u{69}" then
258−return 2
258+return 0x2
259end
259end
260−end,10,nil,"\u{45}\u{51}\u{4b}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
260+end,0xa,nil,"\u{45}\u{51}\u{4b}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
261checkR(function (a)
261checkR(function (a)
262−if a == 10000 then
262+if a == 0x2710 then
263−return 2
263+return 0x2
264end
264end
265−end,1,nil,"\u{45}\u{51}\u{4b}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
265+end,0x1,nil,"\u{45}\u{51}\u{4b}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
266checkR(function (a)
266checkR(function (a)
267−if - 10000 == a then
267+if - 0x2710 == a then
268−return 2
268+return 0x2
269end
269end
270−end,- 10000,2,"\u{45}\u{51}\u{4b}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
270+end,- 0x2710,0x2,"\u{45}\u{51}\u{4b}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
271checkR(function (a)
271checkR(function (a)
272−if - 10 <= a then
272+if - 0xa <= a then
273−return 2
273+return 0x2
274end
274end
275−end,- 10,2,"\u{47}\u{45}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
275+end,- 0xa,0x2,"\u{47}\u{45}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
276checkR(function (a)
276checkR(function (a)
277if 128.0 > a then
277if 128.0 > a then
278−return 2
278+return 0x2
279end
279end
280−end,129,nil,"\u{4c}\u{54}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
280+end,0x81,nil,"\u{4c}\u{54}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
281checkR(function (a)
281checkR(function (a)
282if - 127.0 < a then
282if - 127.0 < a then
283−return 2
283+return 0x2
284end
284end
285−end,- 127,nil,"\u{47}\u{54}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
285+end,- 0x7f,nil,"\u{47}\u{54}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
286checkR(function (a)
286checkR(function (a)
287−if 10 < a then
287+if 0xa < a then
288−return 2
288+return 0x2
289end
289end
290−end,11,2,"\u{47}\u{54}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
290+end,0xb,0x2,"\u{47}\u{54}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
291checkR(function (a)
291checkR(function (a)
292−if 129 < a then
292+if 0x81 < a then
293−return 2
293+return 0x2
294end
294end
295−end,130,2,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{54}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
295+end,0x82,0x2,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{54}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
296checkR(function (a)
296checkR(function (a)
297if a >= 23.0 then
297if a >= 23.0 then
298−return 2
298+return 0x2
299end
299end
300−end,25,2,"\u{47}\u{45}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
300+end,0x19,0x2,"\u{47}\u{45}\u{49}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
301checkR(function (a)
301checkR(function (a)
302if a >= 23.1 then
302if a >= 23.1 then
303−return 2
303+return 0x2
304end
304end
305−end,0,nil,"\u{4c}\u{4f}\u{41}\u{44}\u{4b}","\u{4c}\u{45}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
305+end,0x0,nil,"\u{4c}\u{4f}\u{41}\u{44}\u{4b}","\u{4c}\u{45}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
306checkR(function (a)
306checkR(function (a)
307if a > 2300.0 then
307if a > 2300.0 then
308−return 2
308+return 0x2
309end
309end
310−end,0,nil,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{4c}\u{54}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
310+end,0x0,nil,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{4c}\u{54}","\u{4a}\u{4d}\u{50}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
311local function checkK
311local function checkK
312(func,val)
312(func,val)
313check(func,"\u{4c}\u{4f}\u{41}\u{44}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
313check(func,"\u{4c}\u{4f}\u{41}\u{44}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
@@ -331,47 +331,47 @@ return 0.0
331end,0.0)
331end,0.0)
332checkI(function ()
332checkI(function ()
333return k0
333return k0
334−end,0)
334+end,0x0)
335checkI(function ()
335checkI(function ()
336−return - k0 // 1
336+return - k0 // 0x1
337−end,0)
337+end,0x0)
338checkK(function ()
338checkK(function ()
339−return 3 ^ - 1
339+return 0x3 ^ - 0x1
340−end,1 / 3)
340+end,0x1 / 0x3)
341checkK(function ()
341checkK(function ()
342−return (1 + 1) ^ (50 + 50)
342+return (0x1 + 0x1) ^ (0x32 + 0x32)
343−end,2 ^ 100)
343+end,0x2 ^ 0x64)
344checkK(function ()
344checkK(function ()
345−return (- 2) ^ (31 - 2)
345+return (- 0x2) ^ (0x1f - 0x2)
346−end,- 536870912 + 0.0)
346+end,- 0x20000000 + 0.0)
347checkF(function ()
347checkF(function ()
348−return (- k3 ^ 0 + 5) // 3.0
348+return (- k3 ^ 0x0 + 0x5) // 3.0
349end,1.0)
349end,1.0)
350checkI(function ()
350checkI(function ()
351−return - k3 % 5
351+return - k3 % 0x5
352−end,2)
352+end,0x2)
353checkF(function ()
353checkF(function ()
354−return - ((2.0 ^ 8 + - (- 1)) % 8) / 2 * 4 - 3
354+return - ((2.0 ^ 0x8 + - (- 0x1)) % 0x8) / 0x2 * 0x4 - 0x3
355end,- 5.0)
355end,- 5.0)
356checkF(function ()
356checkF(function ()
357−return - ((2 ^ 8 + - (- 1)) % 8) // 2 * 4 - 3
357+return - ((0x2 ^ 0x8 + - (- 0x1)) % 0x8) // 0x2 * 0x4 - 0x3
358end,- 7.0)
358end,- 7.0)
359checkI(function ()
359checkI(function ()
360−return 240.0 | 204.0 ~ 170 & 253
360+return 240.0 | 204.0 ~ 0xaa & 0xfd
361−end,244)
361+end,0xf4)
362checkI(function ()
362checkI(function ()
363return ~ (~ kFF0 | kFF0)
363return ~ (~ kFF0 | kFF0)
364−end,0)
364+end,0x0)
365checkI(function ()
365checkI(function ()
366return ~ ~ - 1024.0
366return ~ ~ - 1024.0
367−end,- 1024)
367+end,- 0x400)
368checkI(function ()
368checkI(function ()
369−return ((100 << k6) << - 4) >> 2
369+return ((0x64 << k6) << - 0x4) >> 0x2
370−end,100)
370+end,0x64)
371−local a = 17
371+local a = 0x11
372;
372;
373−local sbx = ((1 << a) - 1) >> 1
373+local sbx = ((0x1 << a) - 0x1) >> 0x1
374−local border <const> = 65535
374+local border <const> = 0xffff
375checkI(function ()
375checkI(function ()
376return border
376return border
377end,sbx)
377end,sbx)
@@ -379,14 +379,14 @@ checkI(function ()
379return - border
379return - border
380end,- sbx)
380end,- sbx)
381checkI(function ()
381checkI(function ()
382−return border + 1
382+return border + 0x1
383−end,sbx + 1)
383+end,sbx + 0x1)
384checkK(function ()
384checkK(function ()
385−return border + 2
385+return border + 0x2
386−end,sbx + 2)
386+end,sbx + 0x2)
387checkK(function ()
387checkK(function ()
388−return - (border + 1)
388+return - (border + 0x1)
389−end,- (sbx + 1))
389+end,- (sbx + 0x1))
390local border <const> = 65535.0
390local border <const> = 65535.0
391checkF(function ()
391checkF(function ()
392return border
392return border
@@ -395,112 +395,112 @@ checkF(function ()
395return - border
395return - border
396end,- sbx + 0.0)
396end,- sbx + 0.0)
397checkF(function ()
397checkF(function ()
398−return border + 1
398+return border + 0x1
399end,(sbx + 1.0))
399end,(sbx + 1.0))
400checkK(function ()
400checkK(function ()
401−return border + 2
401+return border + 0x2
402end,(sbx + 2.0))
402end,(sbx + 2.0))
403checkK(function ()
403checkK(function ()
404−return - (border + 1)
404+return - (border + 0x1)
405end,- (sbx + 1.0))
405end,- (sbx + 1.0))
406checkR(function (x)
406checkR(function (x)
407return x + k1
407return x + k1
408−end,10,11,"\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
408+end,0xa,0xb,"\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
409checkR(function (x)
409checkR(function (x)
410−return x - 127
410+return x - 0x7f
411−end,10,- 117,"\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
411+end,0xa,- 0x75,"\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
412checkR(function (x)
412checkR(function (x)
413−return 128 + x
413+return 0x80 + x
414end,0.0,128.0,"\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
414end,0.0,128.0,"\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
415checkR(function (x)
415checkR(function (x)
416−return x * - 127
416+return x * - 0x7f
417end,- 1.0,127.0,"\u{4d}\u{55}\u{4c}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
417end,- 1.0,127.0,"\u{4d}\u{55}\u{4c}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
418checkR(function (x)
418checkR(function (x)
419−return 20 * x
419+return 0x14 * x
420−end,2,40,"\u{4d}\u{55}\u{4c}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
420+end,0x2,0x28,"\u{4d}\u{55}\u{4c}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
421checkR(function (x)
421checkR(function (x)
422−return x ^ - 2
422+return x ^ - 0x2
423−end,2,0.25,"\u{50}\u{4f}\u{57}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
423+end,0x2,0.25,"\u{50}\u{4f}\u{57}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
424checkR(function (x)
424checkR(function (x)
425−return x / 40
425+return x / 0x28
426−end,40,1.0,"\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
426+end,0x28,1.0,"\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
427checkR(function (x)
427checkR(function (x)
428−return x // 1
428+return x // 0x1
429end,10.0,10.0,"\u{49}\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
429end,10.0,10.0,"\u{49}\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
430checkR(function (x)
430checkR(function (x)
431−return x % (100 - 10)
431+return x % (0x64 - 0xa)
432−end,91,1,"\u{4d}\u{4f}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
432+end,0x5b,0x1,"\u{4d}\u{4f}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
433checkR(function (x)
433checkR(function (x)
434return k1 << x
434return k1 << x
435−end,3,8,"\u{53}\u{48}\u{4c}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
435+end,0x3,0x8,"\u{53}\u{48}\u{4c}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
436checkR(function (x)
436checkR(function (x)
437−return x << 127
437+return x << 0x7f
438−end,10,0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
438+end,0xa,0x0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
439checkR(function (x)
439checkR(function (x)
440−return x << - 127
440+return x << - 0x7f
441−end,10,0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
441+end,0xa,0x0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
442checkR(function (x)
442checkR(function (x)
443−return x >> 128
443+return x >> 0x80
444−end,8,0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
444+end,0x8,0x0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
445checkR(function (x)
445checkR(function (x)
446−return x >> - 127
446+return x >> - 0x7f
447−end,8,0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
447+end,0x8,0x0,"\u{53}\u{48}\u{52}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
448checkR(function (x)
448checkR(function (x)
449−return x & 1
449+return x & 0x1
450−end,9,1,"\u{42}\u{41}\u{4e}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
450+end,0x9,0x1,"\u{42}\u{41}\u{4e}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
451checkR(function (x)
451checkR(function (x)
452−return 10 | x
452+return 0xa | x
453−end,1,11,"\u{42}\u{4f}\u{52}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
453+end,0x1,0xb,"\u{42}\u{4f}\u{52}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
454checkR(function (x)
454checkR(function (x)
455−return - 10 ~ x
455+return - 0xa ~ x
456−end,- 1,9,"\u{42}\u{58}\u{4f}\u{52}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
456+end,- 0x1,0x9,"\u{42}\u{58}\u{4f}\u{52}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
457checkR(function (x)
457checkR(function (x)
458return x + 0.0
458return x + 0.0
459−end,1,1.0,"\u{41}\u{44}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
459+end,0x1,1.0,"\u{41}\u{44}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
460checkR(function (x)
460checkR(function (x)
461−return x * - 10000
461+return x * - 0x2710
462−end,2,- 20000,"\u{4d}\u{55}\u{4c}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
462+end,0x2,- 0x4e20,"\u{4d}\u{55}\u{4c}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
463checkR(function (x)
463checkR(function (x)
464return x ^ 0.5
464return x ^ 0.5
465−end,4,2.0,"\u{50}\u{4f}\u{57}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
465+end,0x4,2.0,"\u{50}\u{4f}\u{57}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
466checkR(function (x)
466checkR(function (x)
467return x / 2.0
467return x / 2.0
468−end,4,2.0,"\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
468+end,0x4,2.0,"\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
469checkR(function (x)
469checkR(function (x)
470−return x // 10000
470+return x // 0x2710
471−end,10000,1,"\u{49}\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
471+end,0x2710,0x1,"\u{49}\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
472checkR(function (x)
472checkR(function (x)
473−return x % (100.0 - 10)
473+return x % (100.0 - 0xa)
474−end,91,1.0,"\u{4d}\u{4f}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
474+end,0x5b,1.0,"\u{4d}\u{4f}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
475check(function ()
475check(function ()
476return - 0.0
476return - 0.0
477end,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{55}\u{4e}\u{4d}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
477end,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{55}\u{4e}\u{4d}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
478check(function ()
478check(function ()
479−return k3 / 0
479+return k3 / 0x0
480end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
480end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
481check(function ()
481check(function ()
482−return 0 % 0
482+return 0x0 % 0x0
483end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4d}\u{4f}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
483end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4d}\u{4f}\u{44}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
484check(function ()
484check(function ()
485−return - 4 // 0
485+return - 0x4 // 0x0
486end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{49}\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
486end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{49}\u{44}\u{49}\u{56}\u{4b}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{4b}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
487check(function (x)
487check(function (x)
488return x >> 2.0
488return x >> 2.0
489end,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{53}\u{48}\u{52}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
489end,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{53}\u{48}\u{52}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
490check(function (x)
490check(function (x)
491−return x << 128
491+return x << 0x80
492end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{53}\u{48}\u{4c}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
492end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{53}\u{48}\u{4c}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
493check(function (x)
493check(function (x)
494return x & 2.0
494return x & 2.0
495end,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{42}\u{41}\u{4e}\u{44}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
495end,"\u{4c}\u{4f}\u{41}\u{44}\u{46}","\u{42}\u{41}\u{4e}\u{44}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{31}")
496check(function ()
496check(function ()
497−for i = - 10, 10.5
497+for i = - 0xa, 10.5
498do
498do
499
499
500end
500end
501end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{4b}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{46}\u{4f}\u{52}\u{50}\u{52}\u{45}\u{50}","\u{46}\u{4f}\u{52}\u{4c}\u{4f}\u{4f}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
501end,"\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{4c}\u{4f}\u{41}\u{44}\u{4b}","\u{4c}\u{4f}\u{41}\u{44}\u{49}","\u{46}\u{4f}\u{52}\u{50}\u{52}\u{45}\u{50}","\u{46}\u{4f}\u{52}\u{4c}\u{4f}\u{4f}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
502check(function ()
502check(function ()
503−for i = 268435455, 10.0, 1
503+for i = 0xfffffff, 10.0, 0x1
504do
504do
505
505
506end
506end
@@ -540,28 +540,28 @@ end)
540checkequal(function (l)
540checkequal(function (l)
541local a
541local a
542;
542;
543−return 0 <= a and a <= l
543+return 0x0 <= a and a <= l
544end,function (l)
544end,function (l)
545local a
545local a
546;
546;
547−return not (not (a >= 0) or not (a <= l))
547+return not (not (a >= 0x0) or not (a <= l))
548end)
548end)
549check(function (a,b)
549check(function (a,b)
550while a do
550while a do
551if b then
551if b then
552break
552break
553else
553else
554−a=a + 1
554+a=a + 0x1
555end
555end
556end
556end
557end,"\u{54}\u{45}\u{53}\u{54}","\u{4a}\u{4d}\u{50}","\u{54}\u{45}\u{53}\u{54}","\u{4a}\u{4d}\u{50}","\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{4a}\u{4d}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
557end,"\u{54}\u{45}\u{53}\u{54}","\u{4a}\u{4d}\u{50}","\u{54}\u{45}\u{53}\u{54}","\u{4a}\u{4d}\u{50}","\u{41}\u{44}\u{44}\u{49}","\u{4d}\u{4d}\u{42}\u{49}\u{4e}\u{49}","\u{4a}\u{4d}\u{50}","\u{52}\u{45}\u{54}\u{55}\u{52}\u{4e}\u{30}")
558checkequal(function ()
558checkequal(function ()
559−return 6 or true or nil
559+return 0x6 or true or nil
560end,function ()
560end,function ()
561return k6 or kTrue or kNil
561return k6 or kTrue or kNil
562end)
562end)
563checkequal(function ()
563checkequal(function ()
564−return 6 and true or nil
564+return 0x6 and true or nil
565end,function ()
565end,function ()
566return k6 and kTrue or kNil
566return k6 and kTrue or kNil
567end)
567end)
@@ -580,7 +580,7 @@ local f2 = f1()
580local f3 = f2()
580local f3 = f2()
581assert(f3() == k0)
581assert(f3() == k0)
582checkK(f3,k0)
582checkK(f3,k0)
583−assert(T.listk(f1)[1] == nil)
583+assert(T.listk(f1)[0x1] == nil)
584−assert(T.listk(f2)[1] == nil)
584+assert(T.listk(f2)[0x1] == nil)
585end
585end
586print("\u{4f}\u{4b}")
586print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/constructs.lua+139−139
@@ -6,7 +6,7 @@ print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{79}\u{6e}\u{74}\
6local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
6local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
7local function checkload
7local function checkload
8(s,msg)
8(s,msg)
9−assert(string.find(select(2,load(s)),msg))
9+assert(string.find(select(0x2,load(s)),msg))
10end
10end
11local a
11local a
12do
12do
@@ -17,66 +17,66 @@ end
17;
17;
18do
18do
19;
19;
20−a=3
20+a=0x3
21;
21;
22−assert(a == 3)
22+assert(a == 0x3)
23end
23end
24;
24;
25;
25;
26if false then
26if false then
27−a=3 // 0
27+a=0x3 // 0x0
28;
28;
29−a=0 % 0
29+a=0x0 % 0x0
30end
30end
31−assert(2 ^ 3 ^ 2 == 2 ^ (3 ^ 2))
31+assert(0x2 ^ 0x3 ^ 0x2 == 0x2 ^ (0x3 ^ 0x2))
32;
32;
33−assert(2 ^ 3 * 4 == (2 ^ 3) * 4)
33+assert(0x2 ^ 0x3 * 0x4 == (0x2 ^ 0x3) * 0x4)
34;
34;
35−assert(2.0 ^ - 2 == 1 / 4 and - 2 ^ - - 2 == - - - 4)
35+assert(2.0 ^ - 0x2 == 0x1 / 0x4 and - 0x2 ^ - - 0x2 == - - - 0x4)
36;
36;
37−assert(not nil and 2 and not (2 > 3 or 3 < 2))
37+assert(not nil and 0x2 and not (0x2 > 0x3 or 0x3 < 0x2))
38;
38;
39−assert(- 3 - 1 - 5 == 0 + 0 - 9)
39+assert(- 0x3 - 0x1 - 0x5 == 0x0 + 0x0 - 0x9)
40;
40;
41−assert(- 2 ^ 2 == - 4 and (- 2) ^ 2 == 4 and 2 * 2 - 3 - 1 == 0)
41+assert(- 0x2 ^ 0x2 == - 0x4 and (- 0x2) ^ 0x2 == 0x4 and 0x2 * 0x2 - 0x3 - 0x1 == 0x0)
42;
42;
43−assert(- 3 % 5 == 2 and - 3 + 5 == 2)
43+assert(- 0x3 % 0x5 == 0x2 and - 0x3 + 0x5 == 0x2)
44−assert(2 * 1 + 3 / 3 == 3 and 1 + 2 .. 3 * 1 == "\u{33}\u{33}")
44+assert(0x2 * 0x1 + 0x3 / 0x3 == 0x3 and 0x1 + 0x2 .. 0x3 * 0x1 == "\u{33}\u{33}")
45;
45;
46−assert(not (2 + 1 > 3 * 1) and "\u{61}" .. "\u{62}" > "\u{61}")
46+assert(not (0x2 + 0x1 > 0x3 * 0x1) and "\u{61}" .. "\u{62}" > "\u{61}")
47;
47;
48−assert(240 | 204 ~ 170 & 253 == 244)
48+assert(0xf0 | 0xcc ~ 0xaa & 0xfd == 0xf4)
49−assert(253 & 170 ~ 204 | 240 == 244)
49+assert(0xfd & 0xaa ~ 0xcc | 0xf0 == 0xf4)
50−assert(240 & 15 + 1 == 16)
50+assert(0xf0 & 0xf + 0x1 == 0x10)
51−assert(3 ^ 4 // 2 ^ 3 // 5 == 2)
51+assert(0x3 ^ 0x4 // 0x2 ^ 0x3 // 0x5 == 0x2)
52−assert(- 3 + 4 * 5 // 2 ^ 3 ^ 2 // 9 + 4 % 10 / 3 == (- 3) + (((4 * 5) // (2 ^ (3 ^ 2))) // 9) + ((4 % 10) / 3))
52+assert(- 0x3 + 0x4 * 0x5 // 0x2 ^ 0x3 ^ 0x2 // 0x9 + 0x4 % 0xa / 0x3 == (- 0x3) + (((0x4 * 0x5) // (0x2 ^ (0x3 ^ 0x2))) // 0x9) + ((0x4 % 0xa) / 0x3))
53assert(not ((true or false) and nil))
53assert(not ((true or false) and nil))
54assert(true or false and nil)
54assert(true or false and nil)
55−assert((((1 or false) and true) or false) == true)
55+assert((((0x1 or false) and true) or false) == true)
56assert((((nil and true) or false) and true) == false)
56assert((((nil and true) or false) and true) == false)
57−local a,b = 1,nil
57+local a,b = 0x1,nil
58;
58;
59−assert(- (1 or 2) == - 1 and (1 and 2) + (- 1.25 or - 4) == 0.75)
59+assert(- (0x1 or 0x2) == - 0x1 and (0x1 and 0x2) + (- 1.25 or - 0x4) == 0.75)
60;
60;
61−local x = ((b or a) + 1 == 2 and (10 or a) + 1 == 11)
61+local x = ((b or a) + 0x1 == 0x2 and (0xa or a) + 0x1 == 0xb)
62;
62;
63assert(x)
63assert(x)
64;
64;
65−x=(((2 < 3) or 1) == true and (2 < 3 and 4) == 4)
65+x=(((0x2 < 0x3) or 0x1) == true and (0x2 < 0x3 and 0x4) == 0x4)
66;
66;
67assert(x)
67assert(x)
68;
68;
69−local x,y = 1,2
69+local x,y = 0x1,0x2
70;
70;
71−assert((x > y) and x or y == 2)
71+assert((x > y) and x or y == 0x2)
72;
72;
73−x,y=2,1
73+x,y=0x2,0x1
74;
74;
75−assert((x > y) and x or y == 2)
75+assert((x > y) and x or y == 0x2)
76;
76;
77−assert(1234567890 == tonumber("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}") and 1234567890 + 1 == 1234567891)
77+assert(0x499602d2 == tonumber("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}") and 0x499602d2 + 0x1 == 0x499602d3)
78do
78do
79−local operand = {3,100,5.0,- 10,- 5.0,10000,- 10000}
79+local operand = {0x3,0x64,5.0,- 0xa,- 5.0,0x2710,- 0x2710}
80local operator = {"\u{2b}","\u{2d}","\u{2a}","\u{2f}","\u{2f}\u{2f}","\u{25}","\u{5e}","\u{26}","\u{7c}","\u{5e}","\u{3c}\u{3c}","\u{3e}\u{3e}","\u{3d}\u{3d}","\u{7e}\u{3d}","\u{3c}","\u{3e}","\u{3c}\u{3d}","\u{3e}\u{3d}"}
80local operator = {"\u{2b}","\u{2d}","\u{2a}","\u{2f}","\u{2f}\u{2f}","\u{25}","\u{5e}","\u{26}","\u{7c}","\u{5e}","\u{3c}\u{3c}","\u{3e}\u{3e}","\u{3d}\u{3d}","\u{7e}\u{3d}","\u{3c}","\u{3e}","\u{3c}\u{3d}","\u{3e}\u{3d}"}
81for _,op in ipairs(operator)
81for _,op in ipairs(operator)
82do
82do
@@ -105,7 +105,7 @@ _ENV.XX=nil
105end
105end
106repeat
106repeat
107
107
108−until 1
108+until 0x1
109;
109;
110repeat
110repeat
111
111
@@ -124,20 +124,20 @@ local a
124;
124;
125local function f
125local function f
126(x)
126(x)
127−x={["\u{61}"] = 1}
127+x={["\u{61}"] = 0x1}
128;
128;
129−x={["\u{78}"] = 1}
129+x={["\u{78}"] = 0x1}
130;
130;
131−x={["\u{47}"] = 1}
131+x={["\u{47}"] = 0x1}
132end
132end
133end
133end
134do
134do
135local code = {"\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{7b}"}
135local code = {"\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{7b}"}
136−for i = 1, 257
136+for i = 0x1, 0x101
137do
137do
138−code[# code + 1]=i .. "\u{2e}\u{31}\u{2c}"
138+code[# code + 0x1]=i .. "\u{2e}\u{31}\u{2c}"
139end
139end
140−code[# code + 1]="\u{7d}\u{3b}"
140+code[# code + 0x1]="\u{7d}\u{3b}"
141code=table.concat(code)
141code=table.concat(code)
142local function check
142local function check
143(ret,val)
143(ret,val)
@@ -145,10 +145,10 @@ local code = code .. ret
145code=load(code)
145code=load(code)
146assert(code() == val)
146assert(code() == val)
147end
147end
148−check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{7e}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",1 ~ 2)
148+check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{7e}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",0x1 ~ 0x2)
149−check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{7c}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",1 | 2)
149+check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{7c}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",0x1 | 0x2)
150−check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{2b}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",1 + 2)
150+check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{2b}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",0x1 + 0x2)
151−check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{3c}\u{3c}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",1 << 2)
151+check("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{28}\u{31}\u{20}\u{3c}\u{3c}\u{20}\u{28}\u{32}\u{20}\u{6f}\u{72}\u{20}\u{33}\u{29}\u{29}",0x1 << 0x2)
152end
152end
153local function f
153local function f
154(i)
154(i)
@@ -156,125 +156,125 @@ if type(i) ~= "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" then
156return i,"\u{6a}\u{6f}\u{6a}\u{6f}"
156return i,"\u{6a}\u{6f}\u{6a}\u{6f}"
157end
157end
158;
158;
159−if i > 0 then
159+if i > 0x0 then
160−return i,f(i - 1)
160+return i,f(i - 0x1)
161end
161end
162;
162;
163end
163end
164−x={f(3),f(5),f(10)}
164+x={f(0x3),f(0x5),f(0xa)}
165;
165;
166−assert(x[1] == 3 and x[2] == 5 and x[3] == 10 and x[4] == 9 and x[12] == 1)
166+assert(x[0x1] == 0x3 and x[0x2] == 0x5 and x[0x3] == 0xa and x[0x4] == 0x9 and x[0xc] == 0x1)
167;
167;
168assert(x[nil] == nil)
168assert(x[nil] == nil)
169x={f("\u{61}\u{6c}\u{6f}"),f("\u{78}\u{69}\u{78}\u{69}"),nil}
169x={f("\u{61}\u{6c}\u{6f}"),f("\u{78}\u{69}\u{78}\u{69}"),nil}
170;
170;
171−assert(x[1] == "\u{61}\u{6c}\u{6f}" and x[2] == "\u{78}\u{69}\u{78}\u{69}" and x[3] == nil)
171+assert(x[0x1] == "\u{61}\u{6c}\u{6f}" and x[0x2] == "\u{78}\u{69}\u{78}\u{69}" and x[0x3] == nil)
172;
172;
173x={f("\u{61}\u{6c}\u{6f}") .. "\u{78}\u{69}\u{78}\u{69}"}
173x={f("\u{61}\u{6c}\u{6f}") .. "\u{78}\u{69}\u{78}\u{69}"}
174;
174;
175−assert(x[1] == "\u{61}\u{6c}\u{6f}\u{78}\u{69}\u{78}\u{69}")
175+assert(x[0x1] == "\u{61}\u{6c}\u{6f}\u{78}\u{69}\u{78}\u{69}")
176x={f({})}
176x={f({})}
177−assert(x[2] == "\u{6a}\u{6f}\u{6a}\u{6f}" and type(x[1]) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
177+assert(x[0x2] == "\u{6a}\u{6f}\u{6a}\u{6f}" and type(x[0x1]) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
178local f = function (i)
178local f = function (i)
179−if i < 10 then
179+if i < 0xa then
180return "\u{61}"
180return "\u{61}"
181−elseif i < 20 then
181+elseif i < 0x14 then
182return "\u{62}"
182return "\u{62}"
183−elseif i < 30 then
183+elseif i < 0x1e then
184return "\u{63}"
184return "\u{63}"
185end
185end
186;
186;
187end
187end
188−assert(f(3) == "\u{61}" and f(12) == "\u{62}" and f(26) == "\u{63}" and f(100) == nil)
188+assert(f(0x3) == "\u{61}" and f(0xc) == "\u{62}" and f(0x1a) == "\u{63}" and f(0x64) == nil)
189−for i = 1, 1000
189+for i = 0x1, 0x3e8
190do
190do
191break
191break
192;
192;
193end
193end
194;
194;
195−local n = 100
195+local n = 0x64
196;
196;
197−local i = 3
197+local i = 0x3
198;
198;
199local t = {}
199local t = {}
200;
200;
201local a = nil
201local a = nil
202while not a do
202while not a do
203−a=0
203+a=0x0
204;
204;
205−for i = 1, n
205+for i = 0x1, n
206do
206do
207−for i = i, 1, - 1
207+for i = i, 0x1, - 0x1
208do
208do
209−a=a + 1
209+a=a + 0x1
210;
210;
211−t[i]=1
211+t[i]=0x1
212;
212;
213end
213end
214;
214;
215end
215end
216;
216;
217end
217end
218−assert(a == n * (n + 1) / 2 and i == 3)
218+assert(a == n * (n + 0x1) / 0x2 and i == 0x3)
219;
219;
220−assert(t[1] and t[n] and not t[0] and not t[n + 1])
220+assert(t[0x1] and t[n] and not t[0x0] and not t[n + 0x1])
221function f(b)
221function f(b)
222−local x = 1
222+local x = 0x1
223;
223;
224repeat
224repeat
225local a
225local a
226;
226;
227−if b == 1 then
227+if b == 0x1 then
228−local b = 1
228+local b = 0x1
229;
229;
230−x=10
230+x=0xa
231;
231;
232break
232break
233−elseif b == 2 then
233+elseif b == 0x2 then
234−x=20
234+x=0x14
235;
235;
236break
236break
237;
237;
238−elseif b == 3 then
238+elseif b == 0x3 then
239−x=30
239+x=0x1e
240;
240;
241else
241else
242−local a,b,c,d = math.sin(1)
242+local a,b,c,d = math.sin(0x1)
243;
243;
244−x=x + 1
244+x=x + 0x1
245;
245;
246end
246end
247−until x >= 12
247+until x >= 0xc
248;
248;
249return x
249return x
250end
250end
251;
251;
252−assert(f(1) == 10 and f(2) == 20 and f(3) == 30 and f(4) == 12)
252+assert(f(0x1) == 0xa and f(0x2) == 0x14 and f(0x3) == 0x1e and f(0x4) == 0xc)
253local f = function (i)
253local f = function (i)
254−if i < 10 then
254+if i < 0xa then
255return "\u{61}"
255return "\u{61}"
256−elseif i < 20 then
256+elseif i < 0x14 then
257return "\u{62}"
257return "\u{62}"
258−elseif i < 30 then
258+elseif i < 0x1e then
259return "\u{63}"
259return "\u{63}"
260else
260else
261−return 8
261+return 0x8
262end
262end
263end
263end
264−assert(f(3) == "\u{61}" and f(12) == "\u{62}" and f(26) == "\u{63}" and f(100) == 8)
264+assert(f(0x3) == "\u{61}" and f(0xc) == "\u{62}" and f(0x1a) == "\u{63}" and f(0x64) == 0x8)
265−local a,b = nil,23
265+local a,b = nil,0x17
266−x={f(100) * 2 + 3 or a,a or b + 2}
266+x={f(0x64) * 0x2 + 0x3 or a,a or b + 0x2}
267−assert(x[1] == 19 and x[2] == 25)
267+assert(x[0x1] == 0x13 and x[0x2] == 0x19)
268−x={["\u{66}"] = 2 + 3 or a,["\u{61}"] = b + 2}
268+x={["\u{66}"] = 0x2 + 0x3 or a,["\u{61}"] = b + 0x2}
269−assert(x.f == 5 and x.a == 25)
269+assert(x.f == 0x5 and x.a == 0x19)
270−a={["\u{79}"] = 1}
270+a={["\u{79}"] = 0x1}
271x={a.y}
271x={a.y}
272−assert(x[1] == 1)
272+assert(x[0x1] == 0x1)
273local function f
273local function f
274(i)
274(i)
275−while 1 do
275+while 0x1 do
276−if i > 0 then
276+if i > 0x0 then
277−i=i - 1
277+i=i - 0x1
278;
278;
279else
279else
280return
280return
@@ -286,32 +286,32 @@ end
286;
286;
287local function g
287local function g
288(i)
288(i)
289−while 1 do
289+while 0x1 do
290−if i > 0 then
290+if i > 0x0 then
291−i=i - 1
291+i=i - 0x1
292else
292else
293return
293return
294end
294end
295end
295end
296end
296end
297−f(10)
297+f(0xa)
298;
298;
299−g(10)
299+g(0xa)
300;
300;
301do
301do
302function f()
302function f()
303−return 1,2,3
303+return 0x1,0x2,0x3
304end
304end
305local a,b,c = f()
305local a,b,c = f()
306;
306;
307−assert(a == 1 and b == 2 and c == 3)
307+assert(a == 0x1 and b == 0x2 and c == 0x3)
308a,b,c=(f())
308a,b,c=(f())
309;
309;
310−assert(a == 1 and b == nil and c == nil)
310+assert(a == 0x1 and b == nil and c == nil)
311end
311end
312−local a,b = 3 and f()
312+local a,b = 0x3 and f()
313;
313;
314−assert(a == 1 and b == nil)
314+assert(a == 0x1 and b == nil)
315function g()
315function g()
316f()
316f()
317;
317;
@@ -323,7 +323,7 @@ function g()
323return nil or f()
323return nil or f()
324end
324end
325a,b=g()
325a,b=g()
326−assert(a == 1 and b == nil)
326+assert(a == 0x1 and b == nil)
327print("\u{2b}")
327print("\u{2b}")
328;
328;
329do
329do
@@ -338,71 +338,71 @@ f=string.gsub(f,"\u{25}\u{73}\u{2b}","\u{a}")
338;
338;
339f,a=load(f)()
339f,a=load(f)()
340;
340;
341−assert(a.a == 1 and a.b)
341+assert(a.a == 0x1 and a.b)
342function g(a,b,c,d,e)
342function g(a,b,c,d,e)
343if not (a >= b or c or d and e or nil) then
343if not (a >= b or c or d and e or nil) then
344−return 0
344+return 0x0
345else
345else
346−return 1
346+return 0x1
347end
347end
348;
348;
349end
349end
350local function h
350local function h
351(a,b,c,d,e)
351(a,b,c,d,e)
352while (a >= b or c or (d and e) or nil) do
352while (a >= b or c or (d and e) or nil) do
353−return 1
353+return 0x1
354end
354end
355;
355;
356−return 0
356+return 0x0
357end
357end
358;
358;
359−assert(f(2,1) == true and g(2,1) == 1 and h(2,1) == 1)
359+assert(f(0x2,0x1) == true and g(0x2,0x1) == 0x1 and h(0x2,0x1) == 0x1)
360−assert(f(1,2,"\u{61}") == "\u{61}" and g(1,2,"\u{61}") == 1 and h(1,2,"\u{61}") == 1)
360+assert(f(0x1,0x2,"\u{61}") == "\u{61}" and g(0x1,0x2,"\u{61}") == 0x1 and h(0x1,0x2,"\u{61}") == 0x1)
361−assert(f(1,2,"\u{61}") ~= nil,"")
361+assert(f(0x1,0x2,"\u{61}") ~= nil,"")
362−assert(f(1,2,"\u{61}") == "\u{61}" and g(1,2,"\u{61}") == 1 and h(1,2,"\u{61}") == 1)
362+assert(f(0x1,0x2,"\u{61}") == "\u{61}" and g(0x1,0x2,"\u{61}") == 0x1 and h(0x1,0x2,"\u{61}") == 0x1)
363−assert(f(1,2,nil,1,"\u{78}") == "\u{78}" and g(1,2,nil,1,"\u{78}") == 1 and h(1,2,nil,1,"\u{78}") == 1)
363+assert(f(0x1,0x2,nil,0x1,"\u{78}") == "\u{78}" and g(0x1,0x2,nil,0x1,"\u{78}") == 0x1 and h(0x1,0x2,nil,0x1,"\u{78}") == 0x1)
364−assert(f(1,2,nil,nil,"\u{78}") == nil and g(1,2,nil,nil,"\u{78}") == 0 and h(1,2,nil,nil,"\u{78}") == 0)
364+assert(f(0x1,0x2,nil,nil,"\u{78}") == nil and g(0x1,0x2,nil,nil,"\u{78}") == 0x0 and h(0x1,0x2,nil,nil,"\u{78}") == 0x0)
365−assert(f(1,2,nil,1,nil) == nil and g(1,2,nil,1,nil) == 0 and h(1,2,nil,1,nil) == 0)
365+assert(f(0x1,0x2,nil,0x1,nil) == nil and g(0x1,0x2,nil,0x1,nil) == 0x0 and h(0x1,0x2,nil,0x1,nil) == 0x0)
366−assert(1 and 2 < 3 == true and 2 < 3 and "\u{61}" < "\u{62}" == true)
366+assert(0x1 and 0x2 < 0x3 == true and 0x2 < 0x3 and "\u{61}" < "\u{62}" == true)
367−x=2 < 3 and not 3
367+x=0x2 < 0x3 and not 0x3
368;
368;
369assert(x == false)
369assert(x == false)
370−x=2 < 1 or (2 > 1 and "\u{61}")
370+x=0x2 < 0x1 or (0x2 > 0x1 and "\u{61}")
371;
371;
372assert(x == "\u{61}")
372assert(x == "\u{61}")
373do
373do
374local a
374local a
375;
375;
376if nil then
376if nil then
377−a=1
377+a=0x1
378;
378;
379else
379else
380−a=2
380+a=0x2
381;
381;
382end
382end
383;
383;
384−assert(a == 2)
384+assert(a == 0x2)
385end
385end
386local function F
386local function F
387(a)
387(a)
388−assert(debug.getinfo(1,"\u{6e}").name == "\u{46}")
388+assert(debug.getinfo(0x1,"\u{6e}").name == "\u{46}")
389−return a,2,3
389+return a,0x2,0x3
390end
390end
391−a,b=F(1) ~= nil
391+a,b=F(0x1) ~= nil
392;
392;
393assert(a == true and b == nil)
393assert(a == true and b == nil)
394;
394;
395a,b=F(nil) == nil
395a,b=F(nil) == nil
396;
396;
397assert(a == true and b == nil)
397assert(a == true and b == nil)
398−_ENV.GLOB1=math.random(0,1)
398+_ENV.GLOB1=math.random(0x0,0x1)
399−local basiccases = {{"\u{6e}\u{69}\u{6c}",nil},{"\u{66}\u{61}\u{6c}\u{73}\u{65}",false},{"\u{74}\u{72}\u{75}\u{65}",true},{"\u{31}\u{30}",10},{"\u{28}\u{30}\u{3d}\u{3d}\u{5f}\u{45}\u{4e}\u{56}\u{2e}\u{47}\u{4c}\u{4f}\u{42}\u{31}\u{29}",0 == _ENV.GLOB1}}
399+local basiccases = {{"\u{6e}\u{69}\u{6c}",nil},{"\u{66}\u{61}\u{6c}\u{73}\u{65}",false},{"\u{74}\u{72}\u{75}\u{65}",true},{"\u{31}\u{30}",0xa},{"\u{28}\u{30}\u{3d}\u{3d}\u{5f}\u{45}\u{4e}\u{56}\u{2e}\u{47}\u{4c}\u{4f}\u{42}\u{31}\u{29}",0x0 == _ENV.GLOB1}}
400local prog
400local prog
401−if _ENV.GLOB1 == 0 then
401+if _ENV.GLOB1 == 0x0 then
402−basiccases[2][1]="\u{46}"
402+basiccases[0x2][0x1]="\u{46}"
403prog="\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{46}\u{20}\u{3c}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{3e}\u{20}\u{3d}\u{20}\u{66}\u{61}\u{6c}\u{73}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{25}\u{73}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{49}\u{58}\u{20}\u{3d}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{73}\u{a}"
403prog="\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{46}\u{20}\u{3c}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{3e}\u{20}\u{3d}\u{20}\u{66}\u{61}\u{6c}\u{73}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{25}\u{73}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{49}\u{58}\u{20}\u{3d}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{73}\u{a}"
404else
404else
405−basiccases[4][1]="\u{6b}\u{31}\u{30}"
405+basiccases[0x4][0x1]="\u{6b}\u{31}\u{30}"
406prog="\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{6b}\u{31}\u{30}\u{20}\u{3c}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{3e}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{25}\u{73}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{49}\u{58}\u{20}\u{3d}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{73}\u{a}\u{20}\u{20}"
406prog="\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{6b}\u{31}\u{30}\u{20}\u{3c}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{3e}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{25}\u{73}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{49}\u{58}\u{20}\u{3d}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{73}\u{a}\u{20}\u{20}"
407end
407end
408print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{2d}\u{63}\u{69}\u{72}\u{63}\u{75}\u{69}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6d}\u{69}\u{7a}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{28}" .. _ENV.GLOB1 .. "\u{29}")
408print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{2d}\u{63}\u{69}\u{72}\u{63}\u{75}\u{69}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6d}\u{69}\u{7a}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{28}" .. _ENV.GLOB1 .. "\u{29}")
@@ -423,7 +423,7 @@ local cases <const> = {}
423local function createcases
423local function createcases
424(n)
424(n)
425local res = {}
425local res = {}
426−for i = 1, n - 1
426+for i = 0x1, n - 0x1
427do
427do
428for _,v1 in ipairs(cases[i])
428for _,v1 in ipairs(cases[i])
429do
429do
@@ -431,33 +431,33 @@ for _,v2 in ipairs(cases[n - i])
431do
431do
432for _,op in ipairs(binops)
432for _,op in ipairs(binops)
433do
433do
434−local t = {"\u{28}" .. v1[1] .. op[1] .. v2[1] .. "\u{29}",op[2](v1[2],v2[2])}
434+local t = {"\u{28}" .. v1[0x1] .. op[0x1] .. v2[0x1] .. "\u{29}",op[0x2](v1[0x2],v2[0x2])}
435−res[# res + 1]=t
435+res[# res + 0x1]=t
436−res[# res + 1]={"\u{6e}\u{6f}\u{74}" .. t[1],not t[2]}
436+res[# res + 0x1]={"\u{6e}\u{6f}\u{74}" .. t[0x1],not t[0x2]}
437end
437end
438end
438end
439end
439end
440end
440end
441return res
441return res
442end
442end
443−local level = _soft and 3 or 4
443+local level = _soft and 0x3 or 0x4
444−cases[1]=basiccases
444+cases[0x1]=basiccases
445−for i = 2, level
445+for i = 0x2, level
446do
446do
447cases[i]=createcases(i)
447cases[i]=createcases(i)
448end
448end
449print("\u{2b}")
449print("\u{2b}")
450−local i = 0
450+local i = 0x0
451−for n = 1, level
451+for n = 0x1, level
452do
452do
453for _,v in pairs(cases[n])
453for _,v in pairs(cases[n])
454do
454do
455−local s = v[1]
455+local s = v[0x1]
456local p = load(string.format(prog,s,s),"")
456local p = load(string.format(prog,s,s),"")
457IX=false
457IX=false
458−assert(p() == v[2] and IX == not not v[2])
458+assert(p() == v[0x2] and IX == not not v[0x2])
459−i=i + 1
459+i=i + 0x1
460−if i % 60000 == 0 then
460+if i % 0xea60 == 0x0 then
461print("\u{2b}")
461print("\u{2b}")
462end
462end
463end
463end
zod/luau/res/lua/cycled/coroutine.lua+280−280
@@ -6,12 +6,12 @@ assert(type(main) == "\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}" and ismain)
6assert(not coroutine.resume(main))
6assert(not coroutine.resume(main))
7assert(not coroutine.isyieldable(main) and not coroutine.isyieldable())
7assert(not coroutine.isyieldable(main) and not coroutine.isyieldable())
8assert(not pcall(coroutine.yield))
8assert(not pcall(coroutine.yield))
9−assert(not pcall(coroutine.resume,0))
9+assert(not pcall(coroutine.resume,0x0))
10−assert(not pcall(coroutine.status,0))
10+assert(not pcall(coroutine.status,0x0))
11local function eqtab
11local function eqtab
12(t1,t2)
12(t1,t2)
13assert(# t1 == # t2)
13assert(# t1 == # t2)
14−for i = 1, # t1
14+for i = 0x1, # t1
15do
15do
16local v = t1[i]
16local v = t1[i]
17assert(t2[i] == v)
17assert(t2[i] == v)
@@ -27,7 +27,7 @@ assert(coroutine.resume(f) == false)
27assert(coroutine.status(f) == "\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}")
27assert(coroutine.status(f) == "\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}")
28local arg = {...}
28local arg = {...}
29assert(coroutine.isyieldable(x))
29assert(coroutine.isyieldable(x))
30−for i = 1, # arg
30+for i = 0x1, # arg
31do
31do
32_G.x={coroutine.yield(table.unpack(arg[i]))}
32_G.x={coroutine.yield(table.unpack(arg[i]))}
33end
33end
@@ -38,19 +38,19 @@ assert(coroutine.isyieldable(f))
38assert(type(f) == "\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}" and coroutine.status(f) == "\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}")
38assert(type(f) == "\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}" and coroutine.status(f) == "\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}")
39assert(string.find(tostring(f),"\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}"))
39assert(string.find(tostring(f),"\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}"))
40local s,a,b,c,d
40local s,a,b,c,d
41−s,a,b,c,d=coroutine.resume(f,{1,2,3},{},{1},{"\u{61}","\u{62}","\u{63}"})
41+s,a,b,c,d=coroutine.resume(f,{0x1,0x2,0x3},{},{0x1},{"\u{61}","\u{62}","\u{63}"})
42assert(coroutine.isyieldable(f))
42assert(coroutine.isyieldable(f))
43assert(s and a == nil and coroutine.status(f) == "\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}")
43assert(s and a == nil and coroutine.status(f) == "\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}")
44s,a,b,c,d=coroutine.resume(f)
44s,a,b,c,d=coroutine.resume(f)
45eqtab(_G.x,{})
45eqtab(_G.x,{})
46−assert(s and a == 1 and b == nil)
46+assert(s and a == 0x1 and b == nil)
47assert(coroutine.isyieldable(f))
47assert(coroutine.isyieldable(f))
48−s,a,b,c,d=coroutine.resume(f,1,2,3)
48+s,a,b,c,d=coroutine.resume(f,0x1,0x2,0x3)
49−eqtab(_G.x,{1,2,3})
49+eqtab(_G.x,{0x1,0x2,0x3})
50assert(s and a == "\u{61}" and b == "\u{62}" and c == "\u{63}" and d == nil)
50assert(s and a == "\u{61}" and b == "\u{62}" and c == "\u{63}" and d == nil)
51s,a,b,c,d=coroutine.resume(f,"\u{78}\u{75}\u{78}\u{75}")
51s,a,b,c,d=coroutine.resume(f,"\u{78}\u{75}\u{78}\u{75}")
52eqtab(_G.x,{"\u{78}\u{75}\u{78}\u{75}"})
52eqtab(_G.x,{"\u{78}\u{75}\u{78}\u{75}"})
53−assert(s and a == 1 and b == 2 and c == 3 and d == nil)
53+assert(s and a == 0x1 and b == 0x2 and c == 0x3 and d == nil)
54assert(coroutine.status(f) == "\u{64}\u{65}\u{61}\u{64}")
54assert(coroutine.status(f) == "\u{64}\u{65}\u{61}\u{64}")
55s,a=coroutine.resume(f,"\u{78}\u{75}\u{78}\u{75}")
55s,a=coroutine.resume(f,"\u{78}\u{75}\u{78}\u{75}")
56assert(not s and string.find(a,"\u{64}\u{65}\u{61}\u{64}") and coroutine.status(f) == "\u{64}\u{65}\u{61}\u{64}")
56assert(not s and string.find(a,"\u{64}\u{65}\u{61}\u{64}") and coroutine.status(f) == "\u{64}\u{65}\u{61}\u{64}")
@@ -60,13 +60,13 @@ local function foo
60return coroutine.yield(i)
60return coroutine.yield(i)
61end
61end
62local f = coroutine.wrap(function ()
62local f = coroutine.wrap(function ()
63−for i = 1, 10
63+for i = 0x1, 0xa
64do
64do
65assert(foo(i) == _G.x)
65assert(foo(i) == _G.x)
66end
66end
67return "\u{61}"
67return "\u{61}"
68end)
68end)
69−for i = 1, 10
69+for i = 0x1, 0xa
70do
70do
71_G.x=i
71_G.x=i
72;
72;
@@ -79,19 +79,19 @@ _G.x=nil
79local function pf
79local function pf
80(n,i)
80(n,i)
81coroutine.yield(n)
81coroutine.yield(n)
82−pf(n * i,i + 1)
82+pf(n * i,i + 0x1)
83end
83end
84f=coroutine.wrap(pf)
84f=coroutine.wrap(pf)
85−local s = 1
85+local s = 0x1
86−for i = 1, 10
86+for i = 0x1, 0xa
87do
87do
88−assert(f(1,1) == s)
88+assert(f(0x1,0x1) == s)
89s=s * i
89s=s * i
90end
90end
91local function gen
91local function gen
92(n)
92(n)
93return coroutine.wrap(function ()
93return coroutine.wrap(function ()
94−for i = 2, n
94+for i = 0x2, n
95do
95do
96coroutine.yield(i)
96coroutine.yield(i)
97end
97end
@@ -100,20 +100,20 @@ end
100local function filter
100local function filter
101(p,g)
101(p,g)
102return coroutine.wrap(function ()
102return coroutine.wrap(function ()
103−while 1 do
103+while 0x1 do
104local n = g()
104local n = g()
105if n == nil then
105if n == nil then
106return
106return
107end
107end
108−if math.fmod(n,p) ~= 0 then
108+if math.fmod(n,p) ~= 0x0 then
109coroutine.yield(n)
109coroutine.yield(n)
110end
110end
111end
111end
112end)
112end)
113end
113end
114−local x = gen(80)
114+local x = gen(0x50)
115local a = {}
115local a = {}
116−while 1 do
116+while 0x1 do
117local n = x()
117local n = x()
118if n == nil then
118if n == nil then
119break
119break
@@ -121,7 +121,7 @@ end
121table.insert(a,n)
121table.insert(a,n)
122x=filter(n,x)
122x=filter(n,x)
123end
123end
124−assert(# a == 22 and a[# a] == 79)
124+assert(# a == 0x16 and a[# a] == 0x4f)
125x,a=nil
125x,a=nil
126print("\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}")
126print("\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}")
127local function func2close
127local function func2close
@@ -150,19 +150,19 @@ co=coroutine.create(function ()
150local x <close> = func2close(function ()
150local x <close> = func2close(function ()
151coroutine.close(co)
151coroutine.close(co)
152end)
152end)
153−coroutine.yield(20)
153+coroutine.yield(0x14)
154end)
154end)
155local st,msg = coroutine.resume(co)
155local st,msg = coroutine.resume(co)
156−assert(st and msg == 20)
156+assert(st and msg == 0x14)
157st,msg=coroutine.close(co)
157st,msg=coroutine.close(co)
158assert(not st and string.find(msg,"\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}"))
158assert(not st and string.find(msg,"\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}"))
159end
159end
160local X
160local X
161local co = coroutine.create(error)
161local co = coroutine.create(error)
162−local st,msg = coroutine.resume(co,100)
162+local st,msg = coroutine.resume(co,0x64)
163−assert(not st and msg == 100)
163+assert(not st and msg == 0x64)
164st,msg=coroutine.close(co)
164st,msg=coroutine.close(co)
165−assert(not st and msg == 100)
165+assert(not st and msg == 0x64)
166st,msg=coroutine.close(co)
166st,msg=coroutine.close(co)
167assert(st and msg == nil)
167assert(st and msg == nil)
168co=coroutine.create(function ()
168co=coroutine.create(function ()
@@ -178,25 +178,25 @@ coroutine.resume(co)
178assert(X)
178assert(X)
179assert(coroutine.close(co))
179assert(coroutine.close(co))
180assert(not X and coroutine.status(co) == "\u{64}\u{65}\u{61}\u{64}")
180assert(not X and coroutine.status(co) == "\u{64}\u{65}\u{61}\u{64}")
181−local x = 0
181+local x = 0x0
182co=coroutine.create(function ()
182co=coroutine.create(function ()
183local y <close> = func2close(function (self,err)
183local y <close> = func2close(function (self,err)
184−assert(err == 111)
184+assert(err == 0x6f)
185−x=200
185+x=0xc8
186−error(200)
186+error(0xc8)
187end)
187end)
188local x <close> = func2close(function (self,err)
188local x <close> = func2close(function (self,err)
189assert(err == nil)
189assert(err == nil)
190;
190;
191−error(111)
191+error(0x6f)
192end)
192end)
193coroutine.yield()
193coroutine.yield()
194end)
194end)
195coroutine.resume(co)
195coroutine.resume(co)
196−assert(x == 0)
196+assert(x == 0x0)
197local st,msg = coroutine.close(co)
197local st,msg = coroutine.close(co)
198−assert(st == false and coroutine.status(co) == "\u{64}\u{65}\u{61}\u{64}" and msg == 200)
198+assert(st == false and coroutine.status(co) == "\u{64}\u{65}\u{61}\u{64}" and msg == 0xc8)
199−assert(x == 200)
199+assert(x == 0xc8)
200st,msg=coroutine.close(co)
200st,msg=coroutine.close(co)
201assert(st and msg == nil)
201assert(st and msg == nil)
202end
202end
@@ -206,59 +206,59 @@ local Y = false
206local function foo
206local function foo
207()
207()
208local x <close> = func2close(function (self,err)
208local x <close> = func2close(function (self,err)
209−Y=debug.getinfo(2)
209+Y=debug.getinfo(0x2)
210X=err
210X=err
211end)
211end)
212−error(43)
212+error(0x2b)
213end
213end
214local co = coroutine.create(function ()
214local co = coroutine.create(function ()
215return pcall(foo)
215return pcall(foo)
216end)
216end)
217local st1,st2,err = coroutine.resume(co)
217local st1,st2,err = coroutine.resume(co)
218−assert(st1 and not st2 and err == 43)
218+assert(st1 and not st2 and err == 0x2b)
219−assert(X == 43 and Y.what == "\u{43}")
219+assert(X == 0x2b and Y.what == "\u{43}")
220local track = {}
220local track = {}
221local function h
221local function h
222(o)
222(o)
223local hv <close> = o
223local hv <close> = o
224−return 1
224+return 0x1
225end
225end
226local function foo
226local function foo
227()
227()
228local x <close> = func2close(function (_,msg)
228local x <close> = func2close(function (_,msg)
229−track[# track + 1]=msg or false
229+track[# track + 0x1]=msg or false
230−error(20)
230+error(0x14)
231end)
231end)
232local y <close> = func2close(function (_,msg)
232local y <close> = func2close(function (_,msg)
233−track[# track + 1]=msg or false
233+track[# track + 0x1]=msg or false
234−return 1000
234+return 0x3e8
235end)
235end)
236local z <close> = func2close(function (_,msg)
236local z <close> = func2close(function (_,msg)
237−track[# track + 1]=msg or false
237+track[# track + 0x1]=msg or false
238−error(10)
238+error(0xa)
239end)
239end)
240−coroutine.yield(1)
240+coroutine.yield(0x1)
241h(func2close(function (_,msg)
241h(func2close(function (_,msg)
242−track[# track + 1]=msg or false
242+track[# track + 0x1]=msg or false
243−error(2)
243+error(0x2)
244end))
244end))
245end
245end
246local co = coroutine.create(pcall)
246local co = coroutine.create(pcall)
247local st,res = coroutine.resume(co,foo)
247local st,res = coroutine.resume(co,foo)
248−assert(st and res == 1)
248+assert(st and res == 0x1)
249local st,res1,res2 = coroutine.resume(co)
249local st,res1,res2 = coroutine.resume(co)
250assert(coroutine.status(co) == "\u{64}\u{65}\u{61}\u{64}")
250assert(coroutine.status(co) == "\u{64}\u{65}\u{61}\u{64}")
251−assert(st and not res1 and res2 == 20)
251+assert(st and not res1 and res2 == 0x14)
252−assert(track[1] == false and track[2] == 2 and track[3] == 10 and track[4] == 10)
252+assert(track[0x1] == false and track[0x2] == 0x2 and track[0x3] == 0xa and track[0x4] == 0xa)
253end
253end
254local co = coroutine.wrap(function ()
254local co = coroutine.wrap(function ()
255−assert(not pcall(table.sort,{1,2,3},coroutine.yield))
255+assert(not pcall(table.sort,{0x1,0x2,0x3},coroutine.yield))
256assert(coroutine.isyieldable())
256assert(coroutine.isyieldable())
257−coroutine.yield(20)
257+coroutine.yield(0x14)
258−return 30
258+return 0x1e
259end)
259end)
260−assert(co() == 20)
260+assert(co() == 0x14)
261−assert(co() == 30)
261+assert(co() == 0x1e)
262local f = function (s,i)
262local f = function (s,i)
263return coroutine.yield(i)
263return coroutine.yield(i)
264end
264end
@@ -266,8 +266,8 @@ local f1 = coroutine.wrap(function ()
266return xpcall(pcall,function (...)
266return xpcall(pcall,function (...)
267return ...
267return ...
268end,function ()
268end,function ()
269−local s = 0
269+local s = 0x0
270−for i in f,nil,1
270+for i in f,nil,0x1
271do
271do
272pcall(function ()
272pcall(function ()
273s=s + i
273s=s + i
@@ -277,12 +277,12 @@ error({s})
277end)
277end)
278end)
278end)
279f1()
279f1()
280−for i = 1, 10
280+for i = 0x1, 0xa
281do
281do
282assert(f1(i) == i)
282assert(f1(i) == i)
283end
283end
284local r1,r2,v = f1(nil)
284local r1,r2,v = f1(nil)
285−assert(r1 and not r2 and v[1] == (10 + 1) * 10 / 2)
285+assert(r1 and not r2 and v[0x1] == (0xa + 0x1) * 0xa / 0x2)
286local function f
286local function f
287(a,b)
287(a,b)
288a=coroutine.yield(a)
288a=coroutine.yield(a)
@@ -291,14 +291,14 @@ error({a + b})
291end
291end
292local function g
292local function g
293(x)
293(x)
294−return x[1] * 2
294+return x[0x1] * 0x2
295end
295end
296co=coroutine.wrap(function ()
296co=coroutine.wrap(function ()
297−coroutine.yield(xpcall(f,g,10,20))
297+coroutine.yield(xpcall(f,g,0xa,0x14))
298end)
298end)
299−assert(co() == 10)
299+assert(co() == 0xa)
300−local r,msg = co(100)
300+local r,msg = co(0x64)
301−assert(not r and msg == 240)
301+assert(not r and msg == 0xf0)
302do
302do
303local function f
303local function f
304(c)
304(c)
@@ -315,13 +315,13 @@ end
315do
315do
316local X
316local X
317local co = coroutine.create(function ()
317local co = coroutine.create(function ()
318−coroutine.yield(10)
318+coroutine.yield(0xa)
319−return 20
319+return 0x14
320end)
320end)
321local trace = {}
321local trace = {}
322local function dotrace
322local function dotrace
323(event)
323(event)
324−trace[# trace + 1]=event
324+trace[# trace + 0x1]=event
325end
325end
326debug.sethook(co,dotrace,"\u{63}\u{6c}\u{72}")
326debug.sethook(co,dotrace,"\u{63}\u{6c}\u{72}")
327repeat
327repeat
@@ -335,21 +335,21 @@ assert(v == correcttrace[k])
335end
335end
336end
336end
337function foo()
337function foo()
338−assert(debug.getinfo(1).currentline == debug.getinfo(foo).linedefined + 1)
338+assert(debug.getinfo(0x1).currentline == debug.getinfo(foo).linedefined + 0x1)
339−assert(debug.getinfo(2).currentline == debug.getinfo(goo).linedefined)
339+assert(debug.getinfo(0x2).currentline == debug.getinfo(goo).linedefined)
340−coroutine.yield(3)
340+coroutine.yield(0x3)
341error(foo)
341error(foo)
342end
342end
343function goo()
343function goo()
344foo()
344foo()
345end
345end
346x=coroutine.wrap(goo)
346x=coroutine.wrap(goo)
347−assert(x() == 3)
347+assert(x() == 0x3)
348local a,b = pcall(x)
348local a,b = pcall(x)
349assert(not a and b == foo)
349assert(not a and b == foo)
350x=coroutine.create(goo)
350x=coroutine.create(goo)
351a,b=coroutine.resume(x)
351a,b=coroutine.resume(x)
352−assert(a and b == 3)
352+assert(a and b == 0x3)
353a,b=coroutine.resume(x)
353a,b=coroutine.resume(x)
354assert(not a and b == foo and coroutine.status(x) == "\u{64}\u{65}\u{61}\u{64}")
354assert(not a and b == foo and coroutine.status(x) == "\u{64}\u{65}\u{61}\u{64}")
355a,b=coroutine.resume(x)
355a,b=coroutine.resume(x)
@@ -357,64 +357,64 @@ assert(not a and string.find(b,"\u{64}\u{65}\u{61}\u{64}") and coroutine.status(
357goo=nil
357goo=nil
358local function all
358local function all
359(a,n,k)
359(a,n,k)
360−if k == 0 then
360+if k == 0x0 then
361coroutine.yield(a)
361coroutine.yield(a)
362else
362else
363−for i = 1, n
363+for i = 0x1, n
364do
364do
365a[k]=i
365a[k]=i
366−all(a,n,k - 1)
366+all(a,n,k - 0x1)
367end
367end
368end
368end
369end
369end
370−local a = 0
370+local a = 0x0
371for t in coroutine.wrap(function ()
371for t in coroutine.wrap(function ()
372−all({},5,4)
372+all({},0x5,0x4)
373end)
373end)
374do
374do
375−a=a + 1
375+a=a + 0x1
376end
376end
377−assert(a == 5 ^ 4)
377+assert(a == 0x5 ^ 0x4)
378local C = {}
378local C = {}
379;
379;
380setmetatable(C,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
380setmetatable(C,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
381local x = coroutine.wrap(function ()
381local x = coroutine.wrap(function ()
382−local a = 10
382+local a = 0xa
383local function f
383local function f
384()
384()
385−a=a + 10
385+a=a + 0xa
386;
386;
387return a
387return a
388end
388end
389while true do
389while true do
390−a=a + 1
390+a=a + 0x1
391coroutine.yield(f)
391coroutine.yield(f)
392end
392end
393end)
393end)
394−C[1]=x
394+C[0x1]=x
395;
395;
396local f = x()
396local f = x()
397−assert(f() == 21 and x()() == 32 and x() == f)
397+assert(f() == 0x15 and x()() == 0x20 and x() == f)
398x=nil
398x=nil
399collectgarbage()
399collectgarbage()
400−assert(C[1] == undef)
400+assert(C[0x1] == undef)
401−assert(f() == 43 and f() == 53)
401+assert(f() == 0x2b and f() == 0x35)
402local function co_func
402local function co_func
403(current_co)
403(current_co)
404assert(coroutine.running() == current_co)
404assert(coroutine.running() == current_co)
405assert(coroutine.resume(current_co) == false)
405assert(coroutine.resume(current_co) == false)
406−coroutine.yield(10,20)
406+coroutine.yield(0xa,0x14)
407assert(coroutine.resume(current_co) == false)
407assert(coroutine.resume(current_co) == false)
408−coroutine.yield(23)
408+coroutine.yield(0x17)
409−return 10
409+return 0xa
410end
410end
411local co = coroutine.create(co_func)
411local co = coroutine.create(co_func)
412local a,b,c = coroutine.resume(co,co)
412local a,b,c = coroutine.resume(co,co)
413−assert(a == true and b == 10 and c == 20)
413+assert(a == true and b == 0xa and c == 0x14)
414a,b=coroutine.resume(co,co)
414a,b=coroutine.resume(co,co)
415−assert(a == true and b == 23)
415+assert(a == true and b == 0x17)
416a,b=coroutine.resume(co,co)
416a,b=coroutine.resume(co,co)
417−assert(a == true and b == 10)
417+assert(a == true and b == 0xa)
418assert(coroutine.resume(co,co) == false)
418assert(coroutine.resume(co,co) == false)
419assert(coroutine.resume(co,co) == false)
419assert(coroutine.resume(co,co) == false)
420do
420do
@@ -429,7 +429,7 @@ A=coroutine.wrap(function ()
429local _ <close> = func2close(function ()
429local _ <close> = func2close(function ()
430X=true
430X=true
431end)
431end)
432−return pcall(A,1)
432+return pcall(A,0x1)
433end)
433end)
434st,res=A()
434st,res=A()
435assert(not st and string.find(res,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}") and X == true)
435assert(not st and string.find(res,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}") and X == true)
@@ -440,10 +440,10 @@ co=coroutine.wrap(function ()
440local x <close> = func2close(function ()
440local x <close> = func2close(function ()
441return pcall(co)
441return pcall(co)
442end)
442end)
443−error(111)
443+error(0x6f)
444end)
444end)
445local st,errobj = pcall(co)
445local st,errobj = pcall(co)
446−assert(not st and errobj == 111)
446+assert(not st and errobj == 0x6f)
447st,errobj=pcall(co)
447st,errobj=pcall(co)
448assert(not st and string.find(errobj,"\u{64}\u{65}\u{61}\u{64}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}"))
448assert(not st and string.find(errobj,"\u{64}\u{65}\u{61}\u{64}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}"))
449end
449end
@@ -454,10 +454,10 @@ end)
454co2=coroutine.wrap(function ()
454co2=coroutine.wrap(function ()
455assert(coroutine.status(co1) == "\u{6e}\u{6f}\u{72}\u{6d}\u{61}\u{6c}")
455assert(coroutine.status(co1) == "\u{6e}\u{6f}\u{72}\u{6d}\u{61}\u{6c}")
456assert(not coroutine.resume(co1))
456assert(not coroutine.resume(co1))
457−coroutine.yield(3)
457+coroutine.yield(0x3)
458end)
458end)
459a,b=coroutine.resume(co1)
459a,b=coroutine.resume(co1)
460−assert(a and b == 3)
460+assert(a and b == 0x3)
461assert(coroutine.status(co1) == "\u{64}\u{65}\u{61}\u{64}")
461assert(coroutine.status(co1) == "\u{64}\u{65}\u{61}\u{64}")
462a=function (a)
462a=function (a)
463coroutine.wrap(a)(a)
463coroutine.wrap(a)(a)
@@ -465,18 +465,18 @@ end
465assert(not pcall(a,a))
465assert(not pcall(a,a))
466a=nil
466a=nil
467local x = coroutine.create(function ()
467local x = coroutine.create(function ()
468−local a = 10
468+local a = 0xa
469_G.F=function ()
469_G.F=function ()
470−a=a + 1
470+a=a + 0x1
471;
471;
472return a
472return a
473end
473end
474error("\u{78}")
474error("\u{78}")
475end)
475end)
476assert(not coroutine.resume(x))
476assert(not coroutine.resume(x))
477−assert(not coroutine.resume(x,1,1,1,1,1,1,1))
477+assert(not coroutine.resume(x,0x1,0x1,0x1,0x1,0x1,0x1,0x1))
478−assert(_G.F() == 11)
478+assert(_G.F() == 0xb)
479−assert(_G.F() == 12)
479+assert(_G.F() == 0xc)
480_G.F=nil
480_G.F=nil
481if not T then
481if not T then
482(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{41}\u{50}\u{49}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
482(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{41}\u{50}\u{49}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
@@ -486,28 +486,28 @@ local turn
486local function fact
486local function fact
487(t,x)
487(t,x)
488assert(turn == t)
488assert(turn == t)
489−if x == 0 then
489+if x == 0x0 then
490−return 1
490+return 0x1
491else
491else
492−return x * fact(t,x - 1)
492+return x * fact(t,x - 0x1)
493end
493end
494end
494end
495−local A,B = 0,0
495+local A,B = 0x0,0x0
496local x = coroutine.create(function ()
496local x = coroutine.create(function ()
497−T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",2)
497+T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",0x2)
498−A=fact("\u{41}",6)
498+A=fact("\u{41}",0x6)
499end)
499end)
500local y = coroutine.create(function ()
500local y = coroutine.create(function ()
501−T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",3)
501+T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",0x3)
502−B=fact("\u{42}",7)
502+B=fact("\u{42}",0x7)
503end)
503end)
504−while A == 0 or B == 0 do
504+while A == 0x0 or B == 0x0 do
505−if A == 0 then
505+if A == 0x0 then
506turn="\u{41}"
506turn="\u{41}"
507;
507;
508assert(T.resume(x))
508assert(T.resume(x))
509end
509end
510−if B == 0 then
510+if B == 0x0 then
511turn="\u{42}"
511turn="\u{42}"
512;
512;
513assert(T.resume(y))
513assert(T.resume(y))
@@ -515,7 +515,7 @@ end
515debug.traceback(x)
515debug.traceback(x)
516debug.traceback(y)
516debug.traceback(y)
517end
517end
518−assert(B // A == 7)
518+assert(B // A == 0x7)
519do
519do
520local done
520local done
521local function test
521local function test
@@ -523,54 +523,54 @@ local function test
523done=false
523done=false
524return coroutine.wrap(function ()
524return coroutine.wrap(function ()
525local a = {}
525local a = {}
526−for i = 1, n
526+for i = 0x1, n
527do
527do
528a[i]=i
528a[i]=i
529end
529end
530−T.sethook("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",1)
530+T.sethook("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",0x1)
531local a1 = {table.unpack(a)}
531local a1 = {table.unpack(a)}
532assert(# a1 == n)
532assert(# a1 == n)
533−for i = 1, n
533+for i = 0x1, n
534do
534do
535assert(a[i] == i)
535assert(a[i] == i)
536end
536end
537done=true
537done=true
538end)
538end)
539end
539end
540−local co = test(0)
540+local co = test(0x0)
541;
541;
542while not done do
542while not done do
543−co(30)
543+co(0x1e)
544end
544end
545−co=test(1)
545+co=test(0x1)
546;
546;
547while not done do
547while not done do
548−co(20,10)
548+co(0x14,0xa)
549end
549end
550−co=test(3)
550+co=test(0x3)
551;
551;
552while not done do
552while not done do
553co()
553co()
554end
554end
555−co=test(100)
555+co=test(0x64)
556;
556;
557while not done do
557while not done do
558co()
558co()
559end
559end
560end
560end
561−local line = debug.getinfo(1,"\u{6c}").currentline + 2
561+local line = debug.getinfo(0x1,"\u{6c}").currentline + 0x2
562local function foo
562local function foo
563()
563()
564−local x = 10
564+local x = 0xa
565−x=x + 10
565+x=x + 0xa
566_G.XX=x
566_G.XX=x
567end
567end
568local co = coroutine.wrap(function ()
568local co = coroutine.wrap(function ()
569−T.sethook("\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{58}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","\u{6c}",0)
569+T.sethook("\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{58}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","\u{6c}",0x0)
570;
570;
571foo()
571foo()
572;
572;
573−return 10
573+return 0xa
574end)
574end)
575_G.XX=nil
575_G.XX=nil
576;
576;
@@ -583,51 +583,51 @@ _G.X=nil
583;
583;
584co()
584co()
585;
585;
586−assert(_G.X == line + 1)
586+assert(_G.X == line + 0x1)
587_G.X=nil
587_G.X=nil
588;
588;
589co()
589co()
590;
590;
591−assert(_G.X == line + 2 and _G.XX == nil)
591+assert(_G.X == line + 0x2 and _G.XX == nil)
592_G.X=nil
592_G.X=nil
593;
593;
594co()
594co()
595;
595;
596−assert(_G.X == line + 3 and _G.XX == 20)
596+assert(_G.X == line + 0x3 and _G.XX == 0x14)
597−assert(co() == 10)
597+assert(co() == 0xa)
598_G.X=nil
598_G.X=nil
599co=coroutine.wrap(function ()
599co=coroutine.wrap(function ()
600−T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",1)
600+T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",0x1)
601;
601;
602foo()
602foo()
603;
603;
604−return 10
604+return 0xa
605end)
605end)
606_G.XX=nil
606_G.XX=nil
607;
607;
608−local c = 0
608+local c = 0x0
609repeat
609repeat
610−c=c + 1
610+c=c + 0x1
611;
611;
612local a = co()
612local a = co()
613−until a == 10
613+until a == 0xa
614−assert(_G.XX == 20 and c >= 5)
614+assert(_G.XX == 0x14 and c >= 0x5)
615co=coroutine.wrap(function ()
615co=coroutine.wrap(function ()
616−T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",2)
616+T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","",0x2)
617;
617;
618foo()
618foo()
619;
619;
620−return 10
620+return 0xa
621end)
621end)
622_G.XX=nil
622_G.XX=nil
623;
623;
624−local c = 0
624+local c = 0x0
625repeat
625repeat
626−c=c + 1
626+c=c + 0x1
627;
627;
628local a = co()
628local a = co()
629−until a == 10
629+until a == 0xa
630−assert(_G.XX == 20 and c >= 5)
630+assert(_G.XX == 0x14 and c >= 0x5)
631_G.X=nil
631_G.X=nil
632;
632;
633_G.XX=nil
633_G.XX=nil
@@ -637,29 +637,29 @@ T.sethook("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{30}","\u{6c}")
637local b = a
637local b = a
638return ...
638return ...
639end)
639end)
640−assert(coroutine.resume(c,1,2,3))
640+assert(coroutine.resume(c,0x1,0x2,0x3))
641−local n,v = debug.getlocal(c,0,1)
641+local n,v = debug.getlocal(c,0x0,0x1)
642−assert(n == "\u{61}" and v == 1 and debug.getlocal(c,0,2) ~= "\u{62}")
642+assert(n == "\u{61}" and v == 0x1 and debug.getlocal(c,0x0,0x2) ~= "\u{62}")
643−assert(debug.setlocal(c,0,1,10))
643+assert(debug.setlocal(c,0x0,0x1,0xa))
644−local t = debug.getinfo(c,0)
644+local t = debug.getinfo(c,0x0)
645−assert(t.currentline == t.linedefined + 2)
645+assert(t.currentline == t.linedefined + 0x2)
646−assert(not debug.getinfo(c,1))
646+assert(not debug.getinfo(c,0x1))
647assert(coroutine.resume(c))
647assert(coroutine.resume(c))
648−local n,v = debug.getlocal(c,0,2)
648+local n,v = debug.getlocal(c,0x0,0x2)
649−assert(n == "\u{62}" and v == 10)
649+assert(n == "\u{62}" and v == 0xa)
650v={coroutine.resume(c)}
650v={coroutine.resume(c)}
651−assert(v[1] == true and v[2] == 2 and v[3] == 3 and v[4] == undef)
651+assert(v[0x1] == true and v[0x2] == 0x2 and v[0x3] == 0x3 and v[0x4] == undef)
652assert(not coroutine.resume(c))
652assert(not coroutine.resume(c))
653end
653end
654do
654do
655local c = coroutine.create(function ()
655local c = coroutine.create(function ()
656−T.testC("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{31}",10,20)
656+T.testC("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{31}",0xa,0x14)
657end)
657end)
658local a,b = coroutine.resume(c)
658local a,b = coroutine.resume(c)
659−assert(a and b == 20)
659+assert(a and b == 0x14)
660−assert(debug.getinfo(c,0).linedefined == - 1)
660+assert(debug.getinfo(c,0x0).linedefined == - 0x1)
661−a,b=debug.getlocal(c,0,2)
661+a,b=debug.getlocal(c,0x0,0x2)
662−assert(b == 10)
662+assert(b == 0xa)
663end
663end
664print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{41}\u{50}\u{49}")
664print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{41}\u{50}\u{49}")
665assert(T.testC("\u{20}\u{20}\u{20}\u{20}\u{6e}\u{65}\u{77}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{62}\u{6f}\u{64}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{61}\u{20}\u{61}\u{20}\u{61}\u{27}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{30}\u{20}\u{33}\u{20}\u{32}\u{20}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{73}\u{20}\u{74}\u{6f}\u{20}\u{6e}\u{65}\u{77}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{31}\u{2c}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{20}\u{30}\u{20}\u{30}\u{20}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}\u{20}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{74}\u{6f}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{58}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{59}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{62}\u{6f}\u{64}\u{79}\u{20}\u{28}\u{74}\u{6f}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{61}\u{67}\u{61}\u{69}\u{6e}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{62}\u{20}\u{62}\u{20}\u{62}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{30}\u{20}\u{33}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{31}\u{2c}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{61}\u{67}\u{61}\u{69}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{20}\u{30}\u{20}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{a}\u{20}\u{20}",function (...)
665assert(T.testC("\u{20}\u{20}\u{20}\u{20}\u{6e}\u{65}\u{77}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{72}\u{65}\u{61}\u{74}\u{65}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{62}\u{6f}\u{64}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{61}\u{20}\u{61}\u{20}\u{61}\u{27}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{30}\u{20}\u{33}\u{20}\u{32}\u{20}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{73}\u{20}\u{74}\u{6f}\u{20}\u{6e}\u{65}\u{77}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{31}\u{2c}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{20}\u{30}\u{20}\u{30}\u{20}\u{20}\u{20}\u{23}\u{20}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}\u{20}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{74}\u{6f}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{58}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{59}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{62}\u{6f}\u{64}\u{79}\u{20}\u{28}\u{74}\u{6f}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{61}\u{67}\u{61}\u{69}\u{6e}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{62}\u{20}\u{62}\u{20}\u{62}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{30}\u{20}\u{33}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{31}\u{2c}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{61}\u{67}\u{61}\u{69}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{20}\u{30}\u{20}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{a}\u{20}\u{20}",function (...)
@@ -671,9 +671,9 @@ C=coroutine.create(function ()
671return T.testC("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{33}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",C)
671return T.testC("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{33}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",C)
672end)
672end)
673local a,b,c,d = coroutine.resume(C)
673local a,b,c,d = coroutine.resume(C)
674−assert(a == true and string.find(b,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}") and c == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and d == 4)
674+assert(a == true and string.find(b,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}") and c == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and d == 0x4)
675a,b,c,d=T.testC("\u{20}\u{20}\u{20}\u{20}\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{33}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{34}")
675a,b,c,d=T.testC("\u{20}\u{20}\u{20}\u{20}\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{2d}\u{33}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{34}")
676−assert(a == coroutine.running() and string.find(b,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}") and c == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and d == 4)
676+assert(a == coroutine.running() and string.find(b,"\u{6e}\u{6f}\u{6e}\u{25}\u{2d}\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}") and c == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and d == 0x4)
677local state = T.newstate()
677local state = T.newstate()
678assert(T.testC(state,"\u{6e}\u{65}\u{77}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{3b}\u{20}\u{69}\u{73}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
678assert(T.testC(state,"\u{6e}\u{65}\u{77}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{3b}\u{20}\u{69}\u{73}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
679assert(not T.testC(state,"\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{3b}\u{20}\u{69}\u{73}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
679assert(not T.testC(state,"\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{3b}\u{20}\u{69}\u{73}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"))
@@ -681,7 +681,7 @@ T.testC(state,"\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{30}")
681T.loadlib(state)
681T.loadlib(state)
682assert(T.doremote(state,"\u{20}\u{20}\u{20}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{27}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{58}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{78}\u{29}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{78}\u{2c}\u{20}\u{27}\u{42}\u{42}\u{27}\u{29}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{43}\u{43}\u{27}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{6f}\u{6b}\u{27}"))
682assert(T.doremote(state,"\u{20}\u{20}\u{20}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{27}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{58}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{78}\u{29}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{78}\u{2c}\u{20}\u{27}\u{42}\u{42}\u{27}\u{29}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{43}\u{43}\u{27}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{6f}\u{6b}\u{27}"))
683local t = table.pack(T.testC(state,"\u{20}\u{20}\u{20}\u{20}\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{58}\u{58}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{58}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{62}\u{6f}\u{64}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{41}\u{41}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{72}\u{67}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{31}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{27}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{27}\u{20}\u{73}\u{68}\u{61}\u{64}\u{6f}\u{77}\u{73}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{54}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{6f}\u{70}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{42}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{65}\u{64}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{41}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{66}\u{69}\u{73}\u{74}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{65}\u{64}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{35}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{72}\u{67}\u{20}\u{28}\u{6e}\u{6f}\u{69}\u{73}\u{65}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{31}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{65}\u{6e}\u{64}\u{73}\u{2c}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{69}\u{73}\u{20}\u{62}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}\u{20}\u{20}"))
683local t = table.pack(T.testC(state,"\u{20}\u{20}\u{20}\u{20}\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{58}\u{58}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{58}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{62}\u{6f}\u{64}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{41}\u{41}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{72}\u{67}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{31}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{27}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{27}\u{20}\u{73}\u{68}\u{61}\u{64}\u{6f}\u{77}\u{73}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{54}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{6f}\u{70}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{42}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{65}\u{64}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{73}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{41}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{66}\u{69}\u{73}\u{74}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{65}\u{64}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{61}\u{77}\u{67}\u{65}\u{74}\u{69}\u{20}\u{52}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{35}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{72}\u{67}\u{20}\u{28}\u{6e}\u{6f}\u{69}\u{73}\u{65}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{31}\u{20}\u{31}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{65}\u{6e}\u{64}\u{73}\u{2c}\u{20}\u{70}\u{72}\u{65}\u{76}\u{69}\u{6f}\u{75}\u{73}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{69}\u{73}\u{20}\u{62}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}\u{20}\u{20}"))
684−assert(t.n == 4 and t[2] == "\u{58}\u{58}" and t[3] == "\u{43}\u{43}" and t[4] == "\u{4f}\u{4b}")
684+assert(t.n == 0x4 and t[0x2] == "\u{58}\u{58}" and t[0x3] == "\u{43}\u{43}" and t[0x4] == "\u{4f}\u{4b}")
685assert(T.doremote(state,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{54}") == "\u{32}")
685assert(T.doremote(state,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{54}") == "\u{32}")
686assert(T.doremote(state,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{41}") == "\u{41}\u{41}")
686assert(T.doremote(state,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{41}") == "\u{41}\u{41}")
687assert(T.doremote(state,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{42}") == "\u{42}\u{42}")
687assert(T.doremote(state,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{42}") == "\u{42}\u{42}")
@@ -689,21 +689,21 @@ T.closestate(state)
689print("\u{2b}")
689print("\u{2b}")
690end
690end
691_G.TO_SURVIVE=coroutine.wrap(function ()
691_G.TO_SURVIVE=coroutine.wrap(function ()
692−local a = 10
692+local a = 0xa
693local x = function ()
693local x = function ()
694−a=a + 1
694+a=a + 0x1
695end
695end
696coroutine.yield()
696coroutine.yield()
697end)
697end)
698_G.TO_SURVIVE()
698_G.TO_SURVIVE()
699if not _soft then
699if not _soft then
700−local lim = 1000000
700+local lim = 0xf4240
701−local t = {lim - 10,lim - 5,lim - 1,lim,lim + 1,lim + 5}
701+local t = {lim - 0xa,lim - 0x5,lim - 0x1,lim,lim + 0x1,lim + 0x5}
702−for i = 1, # t
702+for i = 0x1, # t
703do
703do
704local j = t[i]
704local j = t[i]
705local co = coroutine.create(function ()
705local co = coroutine.create(function ()
706−return table.unpack({},1,j)
706+return table.unpack({},0x1,j)
707end)
707end)
708local r,msg = coroutine.resume(co)
708local r,msg = coroutine.resume(co)
709assert(j < lim or not r)
709assert(j < lim or not r)
@@ -731,7 +731,7 @@ return val(a) < val(b)
731end,["\u{5f}\u{5f}\u{6c}\u{65}"] = function (a,b)
731end,["\u{5f}\u{5f}\u{6c}\u{65}"] = function (a,b)
732coroutine.yield(nil,"\u{6c}\u{65}")
732coroutine.yield(nil,"\u{6c}\u{65}")
733;
733;
734−return a - b <= 0
734+return a - b <= 0x0
735end,["\u{5f}\u{5f}\u{61}\u{64}\u{64}"] = function (a,b)
735end,["\u{5f}\u{5f}\u{61}\u{64}\u{64}"] = function (a,b)
736coroutine.yield(nil,"\u{61}\u{64}\u{64}")
736coroutine.yield(nil,"\u{61}\u{64}\u{64}")
737;
737;
@@ -804,12 +804,12 @@ local function new
804(x)
804(x)
805return setmetatable({["\u{78}"] = x,["\u{6b}"] = {}},mt)
805return setmetatable({["\u{78}"] = x,["\u{6b}"] = {}},mt)
806end
806end
807−local a = new(10)
807+local a = new(0xa)
808−local b = new(12)
808+local b = new(0xc)
809local c = new("\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
809local c = new("\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
810local function run
810local function run
811(f,t)
811(f,t)
812−local i = 1
812+local i = 0x1
813local c = coroutine.wrap(f)
813local c = coroutine.wrap(f)
814while true do
814while true do
815local res,stat = c()
815local res,stat = c()
@@ -819,7 +819,7 @@ assert(t[i] == undef)
819return res,t
819return res,t
820end
820end
821assert(stat == t[i])
821assert(stat == t[i])
822−i=i + 1
822+i=i + 0x1
823end
823end
824end
824end
825assert(run(function ()
825assert(run(function ()
@@ -845,110 +845,110 @@ end
845end,{"\u{65}\u{71}"}) == "\u{7e}\u{3d}")
845end,{"\u{65}\u{71}"}) == "\u{7e}\u{3d}")
846assert(run(function ()
846assert(run(function ()
847return a & b + a
847return a & b + a
848−end,{"\u{61}\u{64}\u{64}","\u{62}\u{61}\u{6e}\u{64}"}) == 2)
848+end,{"\u{61}\u{64}\u{64}","\u{62}\u{61}\u{6e}\u{64}"}) == 0x2)
849assert(run(function ()
849assert(run(function ()
850−return 1 + a
850+return 0x1 + a
851−end,{"\u{61}\u{64}\u{64}"}) == 11)
851+end,{"\u{61}\u{64}\u{64}"}) == 0xb)
852assert(run(function ()
852assert(run(function ()
853−return a - 25
853+return a - 0x19
854−end,{"\u{73}\u{75}\u{62}"}) == - 15)
854+end,{"\u{73}\u{75}\u{62}"}) == - 0xf)
855assert(run(function ()
855assert(run(function ()
856−return 2 * a
856+return 0x2 * a
857−end,{"\u{6d}\u{75}\u{6c}"}) == 20)
857+end,{"\u{6d}\u{75}\u{6c}"}) == 0x14)
858assert(run(function ()
858assert(run(function ()
859−return a ^ 2
859+return a ^ 0x2
860−end,{"\u{70}\u{6f}\u{77}"}) == 100)
860+end,{"\u{70}\u{6f}\u{77}"}) == 0x64)
861assert(run(function ()
861assert(run(function ()
862−return a / 2
862+return a / 0x2
863−end,{"\u{64}\u{69}\u{76}"}) == 5)
863+end,{"\u{64}\u{69}\u{76}"}) == 0x5)
864assert(run(function ()
864assert(run(function ()
865−return a % 6
865+return a % 0x6
866−end,{"\u{6d}\u{6f}\u{64}"}) == 4)
866+end,{"\u{6d}\u{6f}\u{64}"}) == 0x4)
867assert(run(function ()
867assert(run(function ()
868−return a // 3
868+return a // 0x3
869−end,{"\u{69}\u{64}\u{69}\u{76}"}) == 3)
869+end,{"\u{69}\u{64}\u{69}\u{76}"}) == 0x3)
870assert(run(function ()
870assert(run(function ()
871return a + b
871return a + b
872−end,{"\u{61}\u{64}\u{64}"}) == 22)
872+end,{"\u{61}\u{64}\u{64}"}) == 0x16)
873assert(run(function ()
873assert(run(function ()
874return a - b
874return a - b
875−end,{"\u{73}\u{75}\u{62}"}) == - 2)
875+end,{"\u{73}\u{75}\u{62}"}) == - 0x2)
876assert(run(function ()
876assert(run(function ()
877return a * b
877return a * b
878−end,{"\u{6d}\u{75}\u{6c}"}) == 120)
878+end,{"\u{6d}\u{75}\u{6c}"}) == 0x78)
879assert(run(function ()
879assert(run(function ()
880return a ^ b
880return a ^ b
881−end,{"\u{70}\u{6f}\u{77}"}) == 10 ^ 12)
881+end,{"\u{70}\u{6f}\u{77}"}) == 0xa ^ 0xc)
882assert(run(function ()
882assert(run(function ()
883return a / b
883return a / b
884−end,{"\u{64}\u{69}\u{76}"}) == 10 / 12)
884+end,{"\u{64}\u{69}\u{76}"}) == 0xa / 0xc)
885assert(run(function ()
885assert(run(function ()
886return a % b
886return a % b
887−end,{"\u{6d}\u{6f}\u{64}"}) == 10)
887+end,{"\u{6d}\u{6f}\u{64}"}) == 0xa)
888assert(run(function ()
888assert(run(function ()
889return a // b
889return a // b
890−end,{"\u{69}\u{64}\u{69}\u{76}"}) == 0)
890+end,{"\u{69}\u{64}\u{69}\u{76}"}) == 0x0)
891−local a1000 = new(1000)
891+local a1000 = new(0x3e8)
892assert(run(function ()
892assert(run(function ()
893−return a1000 + 1000
893+return a1000 + 0x3e8
894−end,{"\u{61}\u{64}\u{64}"}) == 2000)
894+end,{"\u{61}\u{64}\u{64}"}) == 0x7d0)
895assert(run(function ()
895assert(run(function ()
896−return a1000 - 25000
896+return a1000 - 0x61a8
897−end,{"\u{73}\u{75}\u{62}"}) == - 24000)
897+end,{"\u{73}\u{75}\u{62}"}) == - 0x5dc0)
898assert(run(function ()
898assert(run(function ()
899−return 2000 * a
899+return 0x7d0 * a
900−end,{"\u{6d}\u{75}\u{6c}"}) == 20000)
900+end,{"\u{6d}\u{75}\u{6c}"}) == 0x4e20)
901assert(run(function ()
901assert(run(function ()
902−return a1000 / 1000
902+return a1000 / 0x3e8
903−end,{"\u{64}\u{69}\u{76}"}) == 1)
903+end,{"\u{64}\u{69}\u{76}"}) == 0x1)
904assert(run(function ()
904assert(run(function ()
905−return a1000 % 600
905+return a1000 % 0x258
906−end,{"\u{6d}\u{6f}\u{64}"}) == 400)
906+end,{"\u{6d}\u{6f}\u{64}"}) == 0x190)
907assert(run(function ()
907assert(run(function ()
908−return a1000 // 500
908+return a1000 // 0x1f4
909−end,{"\u{69}\u{64}\u{69}\u{76}"}) == 2)
909+end,{"\u{69}\u{64}\u{69}\u{76}"}) == 0x2)
910assert(run(function ()
910assert(run(function ()
911return a % b
911return a % b
912−end,{"\u{6d}\u{6f}\u{64}"}) == 10)
912+end,{"\u{6d}\u{6f}\u{64}"}) == 0xa)
913assert(run(function ()
913assert(run(function ()
914return ~ a & b
914return ~ a & b
915−end,{"\u{62}\u{6e}\u{6f}\u{74}","\u{62}\u{61}\u{6e}\u{64}"}) == ~ 10 & 12)
915+end,{"\u{62}\u{6e}\u{6f}\u{74}","\u{62}\u{61}\u{6e}\u{64}"}) == ~ 0xa & 0xc)
916assert(run(function ()
916assert(run(function ()
917return a | b
917return a | b
918−end,{"\u{62}\u{6f}\u{72}"}) == 10 | 12)
918+end,{"\u{62}\u{6f}\u{72}"}) == 0xa | 0xc)
919assert(run(function ()
919assert(run(function ()
920return a ~ b
920return a ~ b
921−end,{"\u{62}\u{78}\u{6f}\u{72}"}) == 10 ~ 12)
921+end,{"\u{62}\u{78}\u{6f}\u{72}"}) == 0xa ~ 0xc)
922assert(run(function ()
922assert(run(function ()
923return a << b
923return a << b
924−end,{"\u{73}\u{68}\u{6c}"}) == 10 << 12)
924+end,{"\u{73}\u{68}\u{6c}"}) == 0xa << 0xc)
925assert(run(function ()
925assert(run(function ()
926return a >> b
926return a >> b
927−end,{"\u{73}\u{68}\u{72}"}) == 10 >> 12)
927+end,{"\u{73}\u{68}\u{72}"}) == 0xa >> 0xc)
928assert(run(function ()
928assert(run(function ()
929−return 10 & b
929+return 0xa & b
930−end,{"\u{62}\u{61}\u{6e}\u{64}"}) == 10 & 12)
930+end,{"\u{62}\u{61}\u{6e}\u{64}"}) == 0xa & 0xc)
931assert(run(function ()
931assert(run(function ()
932−return a | 2
932+return a | 0x2
933−end,{"\u{62}\u{6f}\u{72}"}) == 10 | 2)
933+end,{"\u{62}\u{6f}\u{72}"}) == 0xa | 0x2)
934assert(run(function ()
934assert(run(function ()
935−return a ~ 2
935+return a ~ 0x2
936−end,{"\u{62}\u{78}\u{6f}\u{72}"}) == 10 ~ 2)
936+end,{"\u{62}\u{78}\u{6f}\u{72}"}) == 0xa ~ 0x2)
937assert(run(function ()
937assert(run(function ()
938−return a >> 2
938+return a >> 0x2
939−end,{"\u{73}\u{68}\u{72}"}) == 10 >> 2)
939+end,{"\u{73}\u{68}\u{72}"}) == 0xa >> 0x2)
940assert(run(function ()
940assert(run(function ()
941−return 1 >> a
941+return 0x1 >> a
942−end,{"\u{73}\u{68}\u{72}"}) == 1 >> 10)
942+end,{"\u{73}\u{68}\u{72}"}) == 0x1 >> 0xa)
943assert(run(function ()
943assert(run(function ()
944−return a << 2
944+return a << 0x2
945−end,{"\u{73}\u{68}\u{6c}"}) == 10 << 2)
945+end,{"\u{73}\u{68}\u{6c}"}) == 0xa << 0x2)
946assert(run(function ()
946assert(run(function ()
947−return 1 << a
947+return 0x1 << a
948−end,{"\u{73}\u{68}\u{6c}"}) == 1 << 10)
948+end,{"\u{73}\u{68}\u{6c}"}) == 0x1 << 0xa)
949assert(run(function ()
949assert(run(function ()
950−return 2 ~ a
950+return 0x2 ~ a
951−end,{"\u{62}\u{78}\u{6f}\u{72}"}) == 2 ~ 10)
951+end,{"\u{62}\u{78}\u{6f}\u{72}"}) == 0x2 ~ 0xa)
952assert(run(function ()
952assert(run(function ()
953return a .. b
953return a .. b
954end,{"\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"}) == "\u{31}\u{30}\u{31}\u{32}")
954end,{"\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"}) == "\u{31}\u{30}\u{31}\u{32}")
@@ -960,10 +960,10 @@ return "\u{61}" .. "\u{62}" .. a .. "\u{63}" .. c .. b .. "\u{78}"
960end,{"\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}","\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}","\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"}) == "\u{61}\u{62}\u{31}\u{30}\u{63}\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{31}\u{32}\u{78}")
960end,{"\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}","\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}","\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"}) == "\u{61}\u{62}\u{31}\u{30}\u{63}\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{31}\u{32}\u{78}")
961do
961do
962local mt1 = {["\u{5f}\u{5f}\u{6c}\u{65}"] = function (a,b)
962local mt1 = {["\u{5f}\u{5f}\u{6c}\u{65}"] = function (a,b)
963−coroutine.yield(10)
963+coroutine.yield(0xa)
964return (val(a) <= val(b))
964return (val(a) <= val(b))
965end,["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
965end,["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
966−coroutine.yield(10)
966+coroutine.yield(0xa)
967return val(a) < val(b)
967return val(a) < val(b)
968end}
968end}
969local mt2 = {["\u{5f}\u{5f}\u{6c}\u{74}"] = mt1.__lt,["\u{5f}\u{5f}\u{6c}\u{65}"] = mt1.__le}
969local mt2 = {["\u{5f}\u{5f}\u{6c}\u{74}"] = mt1.__lt,["\u{5f}\u{5f}\u{6c}\u{65}"] = mt1.__le}
@@ -973,19 +973,19 @@ local co = coroutine.wrap(f)
973local res
973local res
974repeat
974repeat
975res=co()
975res=co()
976−until res ~= 10
976+until res ~= 0xa
977return res
977return res
978end
978end
979local function test
979local function test
980()
980()
981−local a1 = setmetatable({["\u{78}"] = 1},mt1)
981+local a1 = setmetatable({["\u{78}"] = 0x1},mt1)
982−local a2 = setmetatable({["\u{78}"] = 2},mt2)
982+local a2 = setmetatable({["\u{78}"] = 0x2},mt2)
983assert(a1 < a2)
983assert(a1 < a2)
984assert(a1 <= a2)
984assert(a1 <= a2)
985−assert(1 < a2)
985+assert(0x1 < a2)
986−assert(1 <= a2)
986+assert(0x1 <= a2)
987−assert(2 > a1)
987+assert(0x2 > a1)
988−assert(2 >= a2)
988+assert(0x2 >= a2)
989return true
989return true
990end
990end
991run(test)
991run(test)
@@ -997,36 +997,36 @@ end,{"\u{6e}\u{69}\u{64}\u{78}","\u{69}\u{64}\u{78}"}) == print)
997do
997do
998local _ENV = _ENV
998local _ENV = _ENV
999f=function ()
999f=function ()
1000−AAA=BBB + 1
1000+AAA=BBB + 0x1
1001;
1001;
1002return AAA
1002return AAA
1003end
1003end
1004end
1004end
1005−local g = new(10)
1005+local g = new(0xa)
1006;
1006;
1007−g.k.BBB=10
1007+g.k.BBB=0xa
1008;
1008;
1009−debug.setupvalue(f,1,g)
1009+debug.setupvalue(f,0x1,g)
1010−assert(run(f,{"\u{69}\u{64}\u{78}","\u{6e}\u{69}\u{64}\u{78}","\u{69}\u{64}\u{78}"}) == 11)
1010+assert(run(f,{"\u{69}\u{64}\u{78}","\u{6e}\u{69}\u{64}\u{78}","\u{69}\u{64}\u{78}"}) == 0xb)
1011−assert(g.k.AAA == 11)
1011+assert(g.k.AAA == 0xb)
1012print("\u{2b}")
1012print("\u{2b}")
1013print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{73}\u{20}\u{69}\u{6e}\u{73}\u{69}\u{64}\u{65}\u{20}\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{69}\u{74}\u{65}\u{72}\u{61}\u{74}\u{6f}\u{72}\u{73}")
1013print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{73}\u{20}\u{69}\u{6e}\u{73}\u{69}\u{64}\u{65}\u{20}\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{69}\u{74}\u{65}\u{72}\u{61}\u{74}\u{6f}\u{72}\u{73}")
1014local f = function (s,i)
1014local f = function (s,i)
1015−if i % 2 == 0 then
1015+if i % 0x2 == 0x0 then
1016coroutine.yield(nil,"\u{66}\u{6f}\u{72}")
1016coroutine.yield(nil,"\u{66}\u{6f}\u{72}")
1017end
1017end
1018if i < s then
1018if i < s then
1019−return i + 1
1019+return i + 0x1
1020end
1020end
1021end
1021end
1022assert(run(function ()
1022assert(run(function ()
1023−local s = 0
1023+local s = 0x0
1024−for i in f,4,0
1024+for i in f,0x4,0x0
1025do
1025do
1026s=s + i
1026s=s + i
1027end
1027end
1028return s
1028return s
1029−end,{"\u{66}\u{6f}\u{72}","\u{66}\u{6f}\u{72}","\u{66}\u{6f}\u{72}"}) == 10)
1029+end,{"\u{66}\u{6f}\u{72}","\u{66}\u{6f}\u{72}","\u{66}\u{6f}\u{72}"}) == 0xa)
1030if T == nil then
1030if T == nil then
1031(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{41}\u{50}\u{49}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
1031(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{20}\u{41}\u{50}\u{49}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
1032print("\u{4f}\u{4b}")
1032print("\u{4f}\u{4b}")
@@ -1042,35 +1042,35 @@ return T.testC(table.unpack(x))
1042end)
1042end)
1043end
1043end
1044local a = {apico("\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{63}\u{6f}\u{64}\u{65}\u{a}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{30}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}\u{20}\u{28}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{72}\u{72}\u{69}\u{76}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{29}\u{a}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{73}\u{74}\u{61}\u{63}\u{6b}\u{6d}\u{61}\u{72}\u{6b}",error)()}
1044local a = {apico("\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{63}\u{6f}\u{64}\u{65}\u{a}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{30}\u{20}\u{32}\u{3b}\u{a}\u{20}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}\u{20}\u{28}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{72}\u{72}\u{69}\u{76}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{29}\u{a}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}","\u{73}\u{74}\u{61}\u{63}\u{6b}\u{6d}\u{61}\u{72}\u{6b}",error)()}
1045−assert(# a == 4 and a[3] == "\u{73}\u{74}\u{61}\u{63}\u{6b}\u{6d}\u{61}\u{72}\u{6b}" and a[4] == "\u{65}\u{72}\u{72}\u{6f}\u{72}\u{63}\u{6f}\u{64}\u{65}" and _G.status == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and _G.ctx == 2)
1045+assert(# a == 0x4 and a[0x3] == "\u{73}\u{74}\u{61}\u{63}\u{6b}\u{6d}\u{61}\u{72}\u{6b}" and a[0x4] == "\u{65}\u{72}\u{72}\u{6f}\u{72}\u{63}\u{6f}\u{64}\u{65}" and _G.status == "\u{45}\u{52}\u{52}\u{52}\u{55}\u{4e}" and _G.ctx == 0x2)
1046local co = apico("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}\u{3b}",coroutine.yield,"\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{63}\u{74}\u{78}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{30}\u{20}\u{34}\u{3b}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}","\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{63}\u{74}\u{78}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}")
1046local co = apico("\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{32}\u{20}\u{33}\u{3b}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}\u{3b}",coroutine.yield,"\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{63}\u{74}\u{78}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{3b}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{30}\u{20}\u{34}\u{3b}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}","\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{63}\u{74}\u{78}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}")
1047−assert(co() == 10)
1047+assert(co() == 0xa)
1048−assert(co(20,30) == "\u{61}")
1048+assert(co(0x14,0x1e) == "\u{61}")
1049a={co()}
1049a={co()}
1050−assert(# a == 10 and a[2] == coroutine.yield and a[5] == 20 and a[6] == 30 and a[7] == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and a[8] == 3 and a[9] == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and a[10] == 4)
1050+assert(# a == 0xa and a[0x2] == coroutine.yield and a[0x5] == 0x14 and a[0x6] == 0x1e and a[0x7] == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and a[0x8] == 0x3 and a[0x9] == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and a[0xa] == 0x4)
1051assert(not pcall(co))
1051assert(not pcall(co))
1052f=T.makeCfunc("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{35}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{31}\u{3b}")
1052f=T.makeCfunc("\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{35}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{31}\u{3b}")
1053co=coroutine.wrap(function ()
1053co=coroutine.wrap(function ()
1054−assert(f() == 23)
1054+assert(f() == 0x17)
1055;
1055;
1056−assert(f() == 23)
1056+assert(f() == 0x17)
1057;
1057;
1058−return 10
1058+return 0xa
1059end)
1059end)
1060−assert(co(23,16) == 5)
1060+assert(co(0x17,0x10) == 0x5)
1061−assert(co(23,16) == 5)
1061+assert(co(0x17,0x10) == 0x5)
1062−assert(co(23,16) == 10)
1062+assert(co(0x17,0x10) == 0xa)
1063−f=T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{32}\u{a}\u{9}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{9}\u{31}\u{20}\u{55}\u{32}\u{a}\u{9}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}","\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{9}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{33}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{63}\u{63}\u{65}\u{73}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{73}\u{69}\u{64}\u{65}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{34}\u{a}\u{9}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}",23,"\u{68}\u{75}\u{75}")
1063+f=T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{32}\u{a}\u{9}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{9}\u{31}\u{20}\u{55}\u{32}\u{a}\u{9}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}","\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{9}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{33}\u{20}\u{20}\u{20}\u{23}\u{20}\u{61}\u{63}\u{63}\u{65}\u{73}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{73}\u{69}\u{64}\u{65}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{34}\u{a}\u{9}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}",0x17,"\u{68}\u{75}\u{75}")
1064x=coroutine.wrap(f)
1064x=coroutine.wrap(f)
1065−assert(x() == 102)
1065+assert(x() == 0x66)
1066−eqtab({x()},{23,"\u{68}\u{75}\u{75}"})
1066+eqtab({x()},{0x17,"\u{68}\u{75}\u{75}"})
1067f=T.makeCfunc("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{61}\u{27}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{32}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{32}\u{3b}\u{20}")
1067f=T.makeCfunc("\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{61}\u{27}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{32}\u{3b}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{32}\u{3b}\u{20}")
1068a,b,c,d=T.testC("\u{6e}\u{65}\u{77}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{30}\u{20}\u{33}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{33}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{20}\u{30}\u{20}\u{30}\u{3b}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{33}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{34}\u{3b}\u{20}",f)
1068a,b,c,d=T.testC("\u{6e}\u{65}\u{77}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{30}\u{20}\u{33}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{33}\u{20}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{78}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{33}\u{20}\u{30}\u{20}\u{30}\u{3b}\u{20}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{65}\u{20}\u{33}\u{20}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{34}\u{3b}\u{20}",f)
1069−assert(a == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and b == "\u{61}" and c == 102 and d == "\u{4f}\u{4b}")
1069+assert(a == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and b == "\u{61}" and c == 0x66 and d == "\u{4f}\u{4b}")
1070−local count = 3
1070+local count = 0x3
1071f=T.makeCfunc("\u{20}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{33}\u{3b}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{3b}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{20}\u{28}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{20}\u{69}\u{73}\u{20}\u{27}\u{66}\u{27}\u{20}\u{6f}\u{72}\u{20}\u{27}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{27}\u{29}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{73}\u{69}\u{6e}\u{67}\u{6c}\u{65}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{32}\u{3b}\u{20}\u{20}\u{20}\u{23}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{6f}\u{66}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{a}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{2d}\u{31}\u{20}\u{2e}\u{3b}\u{9}\u{9}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{9}\u{9}\u{23}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{61}\u{72}\u{72}\u{69}\u{76}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{a}","\u{20}\u{20}\u{23}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{34}\u{9}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{6c}\u{6c}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}\u{a}",function ()
1071f=T.makeCfunc("\u{20}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{31}\u{3b}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{55}\u{33}\u{3b}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{67}\u{65}\u{74}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{30}\u{20}\u{31}\u{3b}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{74}\u{20}\u{20}\u{28}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{20}\u{69}\u{73}\u{20}\u{27}\u{66}\u{27}\u{20}\u{6f}\u{72}\u{20}\u{27}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{27}\u{29}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{73}\u{69}\u{6e}\u{67}\u{6c}\u{65}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{32}\u{3b}\u{20}\u{20}\u{20}\u{23}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{6f}\u{66}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{a}\u{20}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{31}\u{20}\u{2d}\u{31}\u{20}\u{2e}\u{3b}\u{9}\u{9}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{9}\u{9}\u{23}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{61}\u{72}\u{72}\u{69}\u{76}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{a}","\u{20}\u{20}\u{23}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{a}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{33}\u{34}\u{9}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{6c}\u{6c}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}\u{a}",function ()
1072−count=count - 1
1072+count=count - 0x1
1073−if count == 0 then
1073+if count == 0x0 then
1074return coroutine.yield
1074return coroutine.yield
1075else
1075else
1076return f
1076return f
@@ -1081,7 +1081,7 @@ return f(nil)
1081end)
1081end)
1082assert(co() == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
1082assert(co() == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
1083a={co()}
1083a={co()}
1084−assert(# a == 3 and a[1] == a[2] and a[2] == a[3] and a[3] == 34)
1084+assert(# a == 0x3 and a[0x1] == a[0x2] and a[0x2] == a[0x3] and a[0x3] == 0x22)
1085local y
1085local y
1086co=coroutine.wrap(function (...)
1086co=coroutine.wrap(function (...)
1087return T.testC("\u{20}\u{23}\u{20}\u{69}\u{6e}\u{69}\u{74}\u{69}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{20}\u{31}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{31}\u{73}\u{74}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{20}\u{30}\u{20}\u{33}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{32}\u{6e}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{20}\u{30}\u{20}\u{34}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{33}\u{74}\u{68}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{36}\u{20}\u{20}\u{20}\u{23}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{68}\u{69}\u{63}\u{68}\u{20}\u{69}\u{73}\u{20}\u{6c}\u{61}\u{73}\u{74}\u{20}\u{61}\u{72}\u{67}\u{2e}\u{20}\u{74}\u{6f}\u{20}\u{27}\u{74}\u{65}\u{73}\u{74}\u{43}\u{27}\u{20}\u{68}\u{65}\u{72}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{32}\u{20}\u{30}\u{20}\u{30}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{74}\u{68}\u{72}\u{6f}\u{77}\u{20}\u{61}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{6f}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{9}\u{9}\u{23}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{36}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{63}\u{74}\u{78}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{32}\u{20}\u{32}\u{20}\u{35}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{74}\u{68}\u{72}\u{6f}\u{77}\u{20}\u{61}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6a}\u{75}\u{6d}\u{70}\u{20}\u{74}\u{6f}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{34}\u{74}\u{68}\u{20}\u{28}\u{61}\u{6e}\u{64}\u{20}\u{6c}\u{61}\u{73}\u{74}\u{29}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}",function (a,b)
1087return T.testC("\u{20}\u{23}\u{20}\u{69}\u{6e}\u{69}\u{74}\u{69}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{20}\u{31}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{31}\u{73}\u{74}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{20}\u{30}\u{20}\u{33}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{32}\u{6e}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{6b}\u{20}\u{30}\u{20}\u{34}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{33}\u{74}\u{68}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{36}\u{20}\u{20}\u{20}\u{23}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{68}\u{69}\u{63}\u{68}\u{20}\u{69}\u{73}\u{20}\u{6c}\u{61}\u{73}\u{74}\u{20}\u{61}\u{72}\u{67}\u{2e}\u{20}\u{74}\u{6f}\u{20}\u{27}\u{74}\u{65}\u{73}\u{74}\u{43}\u{27}\u{20}\u{68}\u{65}\u{72}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{32}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{32}\u{20}\u{30}\u{20}\u{30}\u{20}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{74}\u{68}\u{72}\u{6f}\u{77}\u{20}\u{61}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{6f}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{6f}\u{70}\u{20}\u{31}\u{9}\u{9}\u{23}\u{20}\u{72}\u{65}\u{6d}\u{6f}\u{76}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{36}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{73}\u{74}\u{61}\u{74}\u{75}\u{73}\u{3b}\u{20}\u{67}\u{65}\u{74}\u{67}\u{6c}\u{6f}\u{62}\u{61}\u{6c}\u{20}\u{63}\u{74}\u{78}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{63}\u{61}\u{6c}\u{6c}\u{6b}\u{20}\u{32}\u{20}\u{32}\u{20}\u{35}\u{20}\u{20}\u{23}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{74}\u{68}\u{72}\u{6f}\u{77}\u{20}\u{61}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6a}\u{75}\u{6d}\u{70}\u{20}\u{74}\u{6f}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}","\u{20}\u{20}\u{23}\u{20}\u{34}\u{74}\u{68}\u{20}\u{28}\u{61}\u{6e}\u{64}\u{20}\u{6c}\u{61}\u{73}\u{74}\u{29}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}",function (a,b)
@@ -1092,21 +1092,21 @@ y=b
1092error("\u{65}\u{72}\u{72}\u{6d}\u{73}\u{67}")
1092error("\u{65}\u{72}\u{72}\u{6d}\u{73}\u{67}")
1093end,...)
1093end,...)
1094end)
1094end)
1095−local a = {co(3,4,6)}
1095+local a = {co(0x3,0x4,0x6)}
1096−assert(a[1] == 6 and a[2] == undef)
1096+assert(a[0x1] == 0x6 and a[0x2] == undef)
1097a={co()}
1097a={co()}
1098;
1098;
1099−assert(a[1] == undef and _G.status == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and _G.ctx == 2)
1099+assert(a[0x1] == undef and _G.status == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and _G.ctx == 0x2)
1100a={co()}
1100a={co()}
1101;
1101;
1102−assert(a[1] == undef and _G.status == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and _G.ctx == 3)
1102+assert(a[0x1] == undef and _G.status == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and _G.ctx == 0x3)
1103−a={co(7,8)}
1103+a={co(0x7,0x8)}
1104;
1104;
1105−assert(type(a[1]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[2]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[3]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[4]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[5]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[6]) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
1105+assert(type(a[0x1]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[0x2]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[0x3]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[0x4]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[0x5]) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(a[0x6]) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
1106−assert(a[7] == 3 and a[8] == 4)
1106+assert(a[0x7] == 0x3 and a[0x8] == 0x4)
1107−assert(a[9] == 7 and a[10] == 8)
1107+assert(a[0x9] == 0x7 and a[0xa] == 0x8)
1108−assert(a[11]:find("\u{65}\u{72}\u{72}\u{6d}\u{73}\u{67}") and # a == 11)
1108+assert(a[0xb]:find("\u{65}\u{72}\u{72}\u{6d}\u{73}\u{67}") and # a == 0xb)
1109−assert(x == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and y == 4)
1109+assert(x == "\u{59}\u{49}\u{45}\u{4c}\u{44}" and y == 0x4)
1110assert(not pcall(co))
1110assert(not pcall(co))
1111_G.ctx=nil
1111_G.ctx=nil
1112_G.status=nil
1112_G.status=nil
@@ -1115,5 +1115,5 @@ local a = {pcall(pcall,pcall,pcall,pcall,pcall,pcall,pcall,error,"\u{68}\u{69}")
1115return pcall(assert,table.unpack(a))
1115return pcall(assert,table.unpack(a))
1116end)
1116end)
1117local a = {co()}
1117local a = {co()}
1118−assert(a[10] == "\u{68}\u{69}")
1118+assert(a[0xa] == "\u{68}\u{69}")
1119print("\u{4f}\u{4b}")
1119print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/cstack.lua+29−29
@@ -7,11 +7,11 @@ assert(not s and string.find(err,msg))
7end
7end
8do
8do
9print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{69}\u{6e}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{20}\u{68}\u{61}\u{6e}\u{64}\u{6c}\u{69}\u{6e}\u{67}")
9print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{69}\u{6e}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{20}\u{68}\u{61}\u{6e}\u{64}\u{6c}\u{69}\u{6e}\u{67}")
10−local count = 0
10+local count = 0x0
11local function loop
11local function loop
12(x,y,z)
12(x,y,z)
13−count=count + 1
13+count=count + 0x1
14−return 1 + loop(x,y,z)
14+return 0x1 + loop(x,y,z)
15end
15end
16tracegc.stop()
16tracegc.stop()
17local res,msg = xpcall(loop,loop)
17local res,msg = xpcall(loop,loop)
@@ -27,25 +27,25 @@ local s = string.rep("\u{61}",size)
27local p = string.rep("\u{2e}\u{3f}",size)
27local p = string.rep("\u{2e}\u{3f}",size)
28return string.match(s,p)
28return string.match(s,p)
29end
29end
30−local m = f(80)
30+local m = f(0x50)
31−assert(# m == 80)
31+assert(# m == 0x50)
32−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{63}\u{6f}\u{6d}\u{70}\u{6c}\u{65}\u{78}",f,2000)
32+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{63}\u{6f}\u{6d}\u{70}\u{6c}\u{65}\u{78}",f,0x7d0)
33end
33end
34do
34do
35print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{2d}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{69}\u{6e}\u{20}\u{72}\u{65}\u{63}\u{75}\u{72}\u{73}\u{69}\u{76}\u{65}\u{20}\u{27}\u{67}\u{73}\u{75}\u{62}\u{27}")
35print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{2d}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{69}\u{6e}\u{20}\u{72}\u{65}\u{63}\u{75}\u{72}\u{73}\u{69}\u{76}\u{65}\u{20}\u{27}\u{67}\u{73}\u{75}\u{62}\u{27}")
36−local count = 0
36+local count = 0x0
37local function foo
37local function foo
38()
38()
39−count=count + 1
39+count=count + 0x1
40string.gsub("\u{61}","\u{2e}",foo)
40string.gsub("\u{61}","\u{2e}",foo)
41end
41end
42checkerror("\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",foo)
42checkerror("\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",foo)
43print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\u{20}",count)
43print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\u{20}",count)
44print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{2d}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{69}\u{6e}\u{20}\u{72}\u{65}\u{63}\u{75}\u{72}\u{73}\u{69}\u{76}\u{65}\u{20}\u{27}\u{67}\u{73}\u{75}\u{62}\u{27}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
44print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{2d}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{69}\u{6e}\u{20}\u{72}\u{65}\u{63}\u{75}\u{72}\u{73}\u{69}\u{76}\u{65}\u{20}\u{27}\u{67}\u{73}\u{75}\u{62}\u{27}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
45−local count = 0
45+local count = 0x0
46local t = setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = foo})
46local t = setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = foo})
47foo=function ()
47foo=function ()
48−count=count + 1
48+count=count + 0x1
49string.gsub("\u{61}","\u{2e}",t)
49string.gsub("\u{61}","\u{2e}",t)
50end
50end
51checkerror("\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",foo)
51checkerror("\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",foo)
@@ -53,15 +53,15 @@ print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\
53end
53end
54do
54do
55print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{73}\u{69}\u{64}\u{65}\u{20}\u{64}\u{65}\u{65}\u{70}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}")
55print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{73}\u{69}\u{64}\u{65}\u{20}\u{64}\u{65}\u{65}\u{70}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}")
56−local count = 0
56+local count = 0x0
57−local lim = 1000
57+local lim = 0x3e8
58local function stack
58local function stack
59(n)
59(n)
60−if n > 0 then
60+if n > 0x0 then
61−return stack(n - 1) + 1
61+return stack(n - 0x1) + 0x1
62else
62else
63coroutine.wrap(function ()
63coroutine.wrap(function ()
64−count=count + 1
64+count=count + 0x1
65stack(lim)
65stack(lim)
66end)()
66end)()
67end
67end
@@ -73,15 +73,15 @@ assert(not st and msg == "\u{6f}\u{6b}")
73print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\u{20}",count)
73print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\u{20}",count)
74end
74end
75do
75do
76−local count = 0
76+local count = 0x0
77print("\u{63}\u{68}\u{61}\u{69}\u{6e}\u{20}\u{6f}\u{66}\u{20}\u{27}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{27}")
77print("\u{63}\u{68}\u{61}\u{69}\u{6e}\u{20}\u{6f}\u{66}\u{20}\u{27}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{27}")
78local coro = false
78local coro = false
79−for i = 1, 1000
79+for i = 0x1, 0x3e8
80do
80do
81local previous = coro
81local previous = coro
82coro=coroutine.create(function ()
82coro=coroutine.create(function ()
83local cc <close> = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function ()
83local cc <close> = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function ()
84−count=count + 1
84+count=count + 0x1
85if previous then
85if previous then
86assert(coroutine.close(previous))
86assert(coroutine.close(previous))
87end
87end
@@ -96,14 +96,14 @@ print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\
96end
96end
97do
97do
98print("\u{6e}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{69}\u{6e}\u{67}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{65}\u{64}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}")
98print("\u{6e}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6d}\u{69}\u{6e}\u{67}\u{20}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{65}\u{64}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}")
99−local count = 0
99+local count = 0x0
100local function body
100local function body
101()
101()
102coroutine.yield()
102coroutine.yield()
103local f = coroutine.wrap(body)
103local f = coroutine.wrap(body)
104f()
104f()
105;
105;
106−count=count + 1
106+count=count + 0x1
107f()
107f()
108end
108end
109local f = coroutine.wrap(body)
109local f = coroutine.wrap(body)
@@ -113,11 +113,11 @@ print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\
113end
113end
114do
114do
115print("\u{6e}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}\u{72}\u{65}\u{63}\u{6f}\u{76}\u{65}\u{72}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{73}")
115print("\u{6e}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}\u{72}\u{65}\u{63}\u{6f}\u{76}\u{65}\u{72}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{73}")
116−local count = 0
116+local count = 0x0
117local function foo
117local function foo
118()
118()
119−count=count + 1
119+count=count + 0x1
120−pcall(1)
120+pcall(0x1)
121coroutine.wrap(foo)()
121coroutine.wrap(foo)()
122end
122end
123checkerror("\u{43}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",foo)
123checkerror("\u{43}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",foo)
@@ -125,15 +125,15 @@ print("\u{66}\u{69}\u{6e}\u{61}\u{6c}\u{20}\u{63}\u{6f}\u{75}\u{6e}\u{74}\u{3a}\
125end
125end
126if T then
126if T then
127print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{72}\u{65}\u{63}\u{6f}\u{76}\u{65}\u{72}\u{79}")
127print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{72}\u{65}\u{63}\u{6f}\u{76}\u{65}\u{72}\u{79}")
128−local N = 0
128+local N = 0x0
129−local LIM = - 1
129+local LIM = - 0x1
130local stack1
130local stack1
131local dummy
131local dummy
132local function err
132local function err
133(msg)
133(msg)
134assert(string.find(msg,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
134assert(string.find(msg,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
135local _,stacknow = T.stacklevel()
135local _,stacknow = T.stacklevel()
136−assert(stacknow == stack1 + 200)
136+assert(stacknow == stack1 + 0xc8)
137end
137end
138local function f
138local function f
139()
139()
@@ -144,7 +144,7 @@ local _,stacknow = T.stacklevel()
144assert(stacknow == stack1)
144assert(stacknow == stack1)
145return
145return
146end
146end
147−N=N + 1
147+N=N + 0x1
148f()
148f()
149end
149end
150local topB,sizeB
150local topB,sizeB
@@ -154,10 +154,10 @@ tracegc.stop()
154xpcall(f,err)
154xpcall(f,err)
155tracegc.start()
155tracegc.start()
156topA,sizeA=T.stacklevel()
156topA,sizeA=T.stacklevel()
157−assert(topA == topB and sizeA < sizeB * 2)
157+assert(topA == topB and sizeA < sizeB * 0x2)
158print(string.format("\u{6d}\u{61}\u{78}\u{69}\u{6d}\u{75}\u{6d}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{3a}\u{20}\u{25}\u{64}",stack1))
158print(string.format("\u{6d}\u{61}\u{78}\u{69}\u{6d}\u{75}\u{6d}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{3a}\u{20}\u{25}\u{64}",stack1))
159LIM=N
159LIM=N
160−N=0
160+N=0x0
161tracegc.stop()
161tracegc.stop()
162f()
162f()
163tracegc.start()
163tracegc.start()
zod/luau/res/lua/cycled/db.lua+295−295
@@ -5,17 +5,17 @@ return assert(load(s))()
5end
5end
6print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{6c}\u{69}\u{62}\u{72}\u{61}\u{72}\u{79}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{69}\u{6f}\u{6e}")
6print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{6c}\u{69}\u{62}\u{72}\u{61}\u{72}\u{79}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{69}\u{6f}\u{6e}")
7do
7do
8−local a = 1
8+local a = 0x1
9end
9end
10assert(not debug.gethook())
10assert(not debug.gethook())
11−local testline = 19
11+local testline = 0x13
12local function test
12local function test
13(s,l,p)
13(s,l,p)
14collectgarbage()
14collectgarbage()
15local function f
15local function f
16(event,line)
16(event,line)
17assert(event == "\u{6c}\u{69}\u{6e}\u{65}")
17assert(event == "\u{6c}\u{69}\u{6e}\u{65}")
18−local l = table.remove(l,1)
18+local l = table.remove(l,0x1)
19if p then
19if p then
20print(l,line)
20print(l,line)
21end
21end
@@ -26,26 +26,26 @@ debug.sethook(f,"\u{6c}")
26load(s)()
26load(s)()
27;
27;
28debug.sethook()
28debug.sethook()
29−assert(# l == 0)
29+assert(# l == 0x0)
30end
30end
31do
31do
32assert(not pcall(debug.getinfo,print,"\u{58}"))
32assert(not pcall(debug.getinfo,print,"\u{58}"))
33−assert(not pcall(debug.getinfo,0,"\u{3e}"))
33+assert(not pcall(debug.getinfo,0x0,"\u{3e}"))
34−assert(not debug.getinfo(1000))
34+assert(not debug.getinfo(0x3e8))
35−assert(not debug.getinfo(- 1))
35+assert(not debug.getinfo(- 0x1))
36local a = debug.getinfo(print)
36local a = debug.getinfo(print)
37assert(a.what == "\u{43}" and a.short_src == "\u{5b}\u{43}\u{5d}")
37assert(a.what == "\u{43}" and a.short_src == "\u{5b}\u{43}\u{5d}")
38a=debug.getinfo(print,"\u{4c}")
38a=debug.getinfo(print,"\u{4c}")
39assert(a.activelines == nil)
39assert(a.activelines == nil)
40local b = debug.getinfo(test,"\u{53}\u{66}\u{4c}")
40local b = debug.getinfo(test,"\u{53}\u{66}\u{4c}")
41−assert(b.name == nil and b.what == "\u{4c}\u{75}\u{61}" and b.linedefined == testline and b.lastlinedefined == b.linedefined + 10 and b.func == test and not string.find(b.short_src,"\u{25}\u{5b}"))
41+assert(b.name == nil and b.what == "\u{4c}\u{75}\u{61}" and b.linedefined == testline and b.lastlinedefined == b.linedefined + 0xa and b.func == test and not string.find(b.short_src,"\u{25}\u{5b}"))
42−assert(b.activelines[b.linedefined + 1] and b.activelines[b.lastlinedefined])
42+assert(b.activelines[b.linedefined + 0x1] and b.activelines[b.lastlinedefined])
43−assert(not b.activelines[b.linedefined] and not b.activelines[b.lastlinedefined + 1])
43+assert(not b.activelines[b.linedefined] and not b.activelines[b.lastlinedefined + 0x1])
44end
44end
45do
45do
46local func = load(string.dump(load("\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{31}\u{30}\u{29}"),true))
46local func = load(string.dump(load("\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{31}\u{30}\u{29}"),true))
47local actl = debug.getinfo(func,"\u{4c}").activelines
47local actl = debug.getinfo(func,"\u{4c}").activelines
48−assert(# actl == 0)
48+assert(# actl == 0x0)
49end
49end
50local a = "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{20}\u{28}\u{29}\u{20}\u{65}\u{6e}\u{64}"
50local a = "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{20}\u{28}\u{29}\u{20}\u{65}\u{6e}\u{64}"
51local function dostring
51local function dostring
@@ -54,9 +54,9 @@ return load(s,x)()
54end
54end
55dostring(a)
55dostring(a)
56assert(debug.getinfo(f).short_src == string.format("\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{25}\u{73}\u{22}\u{5d}",a))
56assert(debug.getinfo(f).short_src == string.format("\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{25}\u{73}\u{22}\u{5d}",a))
57−dostring(a .. string.format("\u{3b}\u{20}\u{25}\u{73}\u{a}\u{3d}\u{31}",string.rep("\u{70}",400)))
57+dostring(a .. string.format("\u{3b}\u{20}\u{25}\u{73}\u{a}\u{3d}\u{31}",string.rep("\u{70}",0x190)))
58assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{25}\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{5b}\u{5e}\u{a}\u{5d}\u{2a}\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{22}\u{25}\u{5d}\u{24}"))
58assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{25}\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{5b}\u{5e}\u{a}\u{5d}\u{2a}\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{22}\u{25}\u{5d}\u{24}"))
59−dostring(a .. string.format("\u{3b}\u{20}\u{25}\u{73}\u{3d}\u{31}",string.rep("\u{70}",400)))
59+dostring(a .. string.format("\u{3b}\u{20}\u{25}\u{73}\u{3d}\u{31}",string.rep("\u{70}",0x190)))
60assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{25}\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{5b}\u{5e}\u{a}\u{5d}\u{2a}\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{22}\u{25}\u{5d}\u{24}"))
60assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{25}\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{5b}\u{5e}\u{a}\u{5d}\u{2a}\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{22}\u{25}\u{5d}\u{24}"))
61dostring("\u{a}" .. a)
61dostring("\u{a}" .. a)
62assert(debug.getinfo(f).short_src == "\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{2e}\u{2e}\u{2e}\u{22}\u{5d}")
62assert(debug.getinfo(f).short_src == "\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{2e}\u{2e}\u{2e}\u{22}\u{5d}")
@@ -64,11 +64,11 @@ dostring(a,"")
64assert(debug.getinfo(f).short_src == "\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{22}\u{5d}")
64assert(debug.getinfo(f).short_src == "\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{22}\u{5d}")
65dostring(a,"\u{40}\u{78}\u{75}\u{78}\u{75}")
65dostring(a,"\u{40}\u{78}\u{75}\u{78}\u{75}")
66assert(debug.getinfo(f).short_src == "\u{78}\u{75}\u{78}\u{75}")
66assert(debug.getinfo(f).short_src == "\u{78}\u{75}\u{78}\u{75}")
67−dostring(a,"\u{40}" .. string.rep("\u{70}",1000) .. "\u{74}")
67+dostring(a,"\u{40}" .. string.rep("\u{70}",0x3e8) .. "\u{74}")
68assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{70}\u{2a}\u{74}\u{24}"))
68assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{70}\u{2a}\u{74}\u{24}"))
69dostring(a,"\u{3d}\u{78}\u{75}\u{78}\u{75}")
69dostring(a,"\u{3d}\u{78}\u{75}\u{78}\u{75}")
70assert(debug.getinfo(f).short_src == "\u{78}\u{75}\u{78}\u{75}")
70assert(debug.getinfo(f).short_src == "\u{78}\u{75}\u{78}\u{75}")
71−dostring(a,string.format("\u{3d}\u{25}\u{73}",string.rep("\u{78}",500)))
71+dostring(a,string.format("\u{3d}\u{25}\u{73}",string.rep("\u{78}",0x1f4)))
72assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{78}\u{2a}\u{24}"))
72assert(string.find(debug.getinfo(f).short_src,"\u{5e}\u{78}\u{2a}\u{24}"))
73dostring(a,"\u{3d}")
73dostring(a,"\u{3d}")
74assert(debug.getinfo(f).short_src == "")
74assert(debug.getinfo(f).short_src == "")
@@ -76,94 +76,94 @@ _G.a=nil
76;
76;
77_G.f=nil
77_G.f=nil
78;
78;
79−_G[string.rep("\u{70}",400)]=nil
79+_G[string.rep("\u{70}",0x190)]=nil
80repeat
80repeat
81local g = {["\u{78}"] = function ()
81local g = {["\u{78}"] = function ()
82−local a = debug.getinfo(2)
82+local a = debug.getinfo(0x2)
83assert(a.name == "\u{66}" and a.namewhat == "\u{6c}\u{6f}\u{63}\u{61}\u{6c}")
83assert(a.name == "\u{66}" and a.namewhat == "\u{6c}\u{6f}\u{63}\u{61}\u{6c}")
84−a=debug.getinfo(1)
84+a=debug.getinfo(0x1)
85assert(a.name == "\u{78}" and a.namewhat == "\u{66}\u{69}\u{65}\u{6c}\u{64}")
85assert(a.name == "\u{78}" and a.namewhat == "\u{66}\u{69}\u{65}\u{6c}\u{64}")
86return "\u{78}\u{69}\u{78}\u{69}"
86return "\u{78}\u{69}\u{78}\u{69}"
87end}
87end}
88local f = function ()
88local f = function ()
89−return 1 + 1 and (not 1 or g.x())
89+return 0x1 + 0x1 and (not 0x1 or g.x())
90end
90end
91assert(f() == "\u{78}\u{69}\u{78}\u{69}")
91assert(f() == "\u{78}\u{69}\u{78}\u{69}")
92g=debug.getinfo(f)
92g=debug.getinfo(f)
93assert(g.what == "\u{4c}\u{75}\u{61}" and g.func == f and g.namewhat == "" and not g.name)
93assert(g.what == "\u{4c}\u{75}\u{61}" and g.func == f and g.namewhat == "" and not g.name)
94function f(x,name)
94function f(x,name)
95name=name or "\u{66}"
95name=name or "\u{66}"
96−local a = debug.getinfo(1)
96+local a = debug.getinfo(0x1)
97assert(a.name == name and a.namewhat == "\u{6c}\u{6f}\u{63}\u{61}\u{6c}")
97assert(a.name == name and a.namewhat == "\u{6c}\u{6f}\u{63}\u{61}\u{6c}")
98return x
98return x
99end
99end
100−if 3 > 4 then
100+if 0x3 > 0x4 then
101break
101break
102end
102end
103;
103;
104f()
104f()
105−if 3 < 4 then
105+if 0x3 < 0x4 then
106−a=1
106+a=0x1
107else
107else
108break
108break
109end
109end
110;
110;
111f()
111f()
112−while 1 do
112+while 0x1 do
113−local x = 10
113+local x = 0xa
114;
114;
115break
115break
116end
116end
117;
117;
118f()
118f()
119−local b = 1
119+local b = 0x1
120−if 3 > 4 then
120+if 0x3 > 0x4 then
121−return math.sin(1)
121+return math.sin(0x1)
122end
122end
123;
123;
124f()
124f()
125−a=3 < 4
125+a=0x3 < 0x4
126;
126;
127f()
127f()
128−a=3 < 4 or 1
128+a=0x3 < 0x4 or 0x1
129;
129;
130f()
130f()
131repeat
131repeat
132−local x = 20
132+local x = 0x14
133;
133;
134−if 4 > 3 then
134+if 0x4 > 0x3 then
135f()
135f()
136else
136else
137break
137break
138end
138end
139;
139;
140f()
140f()
141−until 1
141+until 0x1
142g={}
142g={}
143−f(g).x=f(2) and f(10) + f(9)
143+f(g).x=f(0x2) and f(0xa) + f(0x9)
144−assert(g.x == f(19))
144+assert(g.x == f(0x13))
145function g(x)
145function g(x)
146if not x then
146if not x then
147−return 3
147+return 0x3
148end
148end
149return (x("\u{61}","\u{78}"))
149return (x("\u{61}","\u{78}"))
150end
150end
151assert(g(f) == "\u{61}")
151assert(g(f) == "\u{61}")
152−until 1
152+until 0x1
153−test("\u{69}\u{66}\u{a}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}\u{a}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{31}\u{a}\u{65}\u{6c}\u{73}\u{65}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{32}\u{a}\u{65}\u{6e}\u{64}\u{a}",{2,3,4,7})
153+test("\u{69}\u{66}\u{a}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}\u{a}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{31}\u{a}\u{65}\u{6c}\u{73}\u{65}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{32}\u{a}\u{65}\u{6e}\u{64}\u{a}",{0x2,0x3,0x4,0x7})
154−test("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{28}\u{29}\u{a}\u{65}\u{6e}\u{64}\u{a}\u{66}\u{6f}\u{6f}\u{28}\u{29}\u{a}\u{41}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{41}\u{20}\u{3d}\u{20}\u{32}\u{a}\u{41}\u{20}\u{3d}\u{20}\u{33}\u{a}",{2,3,2,4,5,6})
154+test("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{28}\u{29}\u{a}\u{65}\u{6e}\u{64}\u{a}\u{66}\u{6f}\u{6f}\u{28}\u{29}\u{a}\u{41}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{41}\u{20}\u{3d}\u{20}\u{32}\u{a}\u{41}\u{20}\u{3d}\u{20}\u{33}\u{a}",{0x2,0x3,0x2,0x4,0x5,0x6})
155_G.A=nil
155_G.A=nil
156−test("\u{2d}\u{2d}\u{a}\u{69}\u{66}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{31}\u{a}\u{65}\u{6c}\u{73}\u{65}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{32}\u{a}\u{65}\u{6e}\u{64}\u{a}",{2,5,6})
156+test("\u{2d}\u{2d}\u{a}\u{69}\u{66}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{31}\u{a}\u{65}\u{6c}\u{73}\u{65}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{32}\u{a}\u{65}\u{6e}\u{64}\u{a}",{0x2,0x5,0x6})
157−test("\u{61}\u{3d}\u{31}\u{a}\u{72}\u{65}\u{70}\u{65}\u{61}\u{74}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{31}\u{a}\u{75}\u{6e}\u{74}\u{69}\u{6c}\u{20}\u{61}\u{3d}\u{3d}\u{33}\u{a}",{1,3,4,3,4})
157+test("\u{61}\u{3d}\u{31}\u{a}\u{72}\u{65}\u{70}\u{65}\u{61}\u{74}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{31}\u{a}\u{75}\u{6e}\u{74}\u{69}\u{6c}\u{20}\u{61}\u{3d}\u{3d}\u{33}\u{a}",{0x1,0x3,0x4,0x3,0x4})
158−test("\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{a}\u{65}\u{6e}\u{64}\u{a}",{2})
158+test("\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{a}\u{65}\u{6e}\u{64}\u{a}",{0x2})
159−test("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{a}\u{61}\u{3d}\u{31}\u{a}\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{61}\u{3c}\u{3d}\u{33}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{31}\u{a}\u{65}\u{6e}\u{64}\u{a}",{1,2,3,4,3,4,3,4,3,5})
159+test("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{a}\u{61}\u{3d}\u{31}\u{a}\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{61}\u{3c}\u{3d}\u{33}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{31}\u{a}\u{65}\u{6e}\u{64}\u{a}",{0x1,0x2,0x3,0x4,0x3,0x4,0x3,0x4,0x3,0x5})
160−test("\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{69}\u{66}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}\u{a}\u{20}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{62}\u{72}\u{65}\u{61}\u{6b}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{65}\u{6e}\u{64}\u{a}\u{61}\u{3d}\u{31}",{1,2,3,6})
160+test("\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{69}\u{66}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{73}\u{69}\u{6e}\u{28}\u{31}\u{29}\u{a}\u{20}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{62}\u{72}\u{65}\u{61}\u{6b}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{65}\u{6e}\u{64}\u{a}\u{61}\u{3d}\u{31}",{0x1,0x2,0x3,0x6})
161−test("\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{33}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{69}\u{a}\u{65}\u{6e}\u{64}\u{a}",{1,2,1,2,1,2,1,3})
161+test("\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{33}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{69}\u{a}\u{65}\u{6e}\u{64}\u{a}",{0x1,0x2,0x1,0x2,0x1,0x2,0x1,0x3})
162−test("\u{66}\u{6f}\u{72}\u{20}\u{69}\u{2c}\u{76}\u{20}\u{69}\u{6e}\u{20}\u{70}\u{61}\u{69}\u{72}\u{73}\u{7b}\u{27}\u{61}\u{27}\u{2c}\u{27}\u{62}\u{27}\u{7d}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{28}\u{69}\u{29}\u{20}\u{2e}\u{2e}\u{20}\u{76}\u{a}\u{65}\u{6e}\u{64}\u{a}",{1,2,1,2,1,3})
162+test("\u{66}\u{6f}\u{72}\u{20}\u{69}\u{2c}\u{76}\u{20}\u{69}\u{6e}\u{20}\u{70}\u{61}\u{69}\u{72}\u{73}\u{7b}\u{27}\u{61}\u{27}\u{2c}\u{27}\u{62}\u{27}\u{7d}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{3d}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{28}\u{69}\u{29}\u{20}\u{2e}\u{2e}\u{20}\u{76}\u{a}\u{65}\u{6e}\u{64}\u{a}",{0x1,0x2,0x1,0x2,0x1,0x3})
163−test("\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{34}\u{20}\u{64}\u{6f}\u{20}\u{61}\u{3d}\u{31}\u{20}\u{65}\u{6e}\u{64}",{1,1,1,1})
163+test("\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{34}\u{20}\u{64}\u{6f}\u{20}\u{61}\u{3d}\u{31}\u{20}\u{65}\u{6e}\u{64}",{0x1,0x1,0x1,0x1})
164_G.a=nil
164_G.a=nil
165do
165do
166−local a = {1,2,3,10,124,125,126,127,128,129,130,255,256,257,500,1000}
166+local a = {0x1,0x2,0x3,0xa,0x7c,0x7d,0x7e,0x7f,0x80,0x81,0x82,0xff,0x100,0x101,0x1f4,0x3e8}
167local s = "\u{20}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{7b}\u{31}\u{30}\u{7d}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{62}\u{5b}\u{31}\u{5d}\u{20}\u{58}\u{20}\u{2b}\u{20}\u{59}\u{20}\u{62}\u{5b}\u{31}\u{5d}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{34}\u{a}\u{20}\u{20}"
167local s = "\u{20}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{7b}\u{31}\u{30}\u{7d}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{62}\u{5b}\u{31}\u{5d}\u{20}\u{58}\u{20}\u{2b}\u{20}\u{59}\u{20}\u{62}\u{5b}\u{31}\u{5d}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{34}\u{a}\u{20}\u{20}"
168for _,i in ipairs(a)
168for _,i in ipairs(a)
169do
169do
@@ -172,7 +172,7 @@ for _,j in ipairs(a)
172do
172do
173subs.Y=string.rep("\u{a}",j)
173subs.Y=string.rep("\u{a}",j)
174local s = string.gsub(s,"\u{5b}\u{58}\u{59}\u{5d}",subs)
174local s = string.gsub(s,"\u{5b}\u{58}\u{59}\u{5d}",subs)
175−test(s,{1,2 + i,2 + i + j,2 + i,2 + i + j,3 + i + j})
175+test(s,{0x1,0x2 + i,0x2 + i + j,0x2 + i,0x2 + i + j,0x3 + i + j})
176end
176end
177end
177end
178end
178end
@@ -190,138 +190,138 @@ end
190assert(next(t.activelines) == nil)
190assert(next(t.activelines) == nil)
191end
191end
192checkactivelines(function (...)
192checkactivelines(function (...)
193−local a = 20
193+local a = 0x14
194−local b = 30
194+local b = 0x1e
195−end,{4,6,8})
195+end,{0x4,0x6,0x8})
196checkactivelines(function (a)
196checkactivelines(function (a)
197−local a = 20
197+local a = 0x14
198−local b = 30
198+local b = 0x1e
199−end,{3,4,6})
199+end,{0x3,0x4,0x6})
200checkactivelines(function (a,b, ...)
200checkactivelines(function (a,b, ...)
201
201
202−end,{0})
202+end,{0x0})
203checkactivelines(function (a,b)
203checkactivelines(function (a,b)
204
204
205−end,{1})
205+end,{0x1})
206−for _,n in pairs({0,1,2,10,50,100,1000,10000})
206+for _,n in pairs({0x0,0x1,0x2,0xa,0x32,0x64,0x3e8,0x2710})
207do
207do
208−checkactivelines(load(string.format("\u{25}\u{73}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",string.rep("\u{a}",n))),{n + 1})
208+checkactivelines(load(string.format("\u{25}\u{73}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",string.rep("\u{a}",n))),{n + 0x1})
209end
209end
210end
210end
211print("\u{2b}")
211print("\u{2b}")
212−assert(not pcall(debug.getlocal,20,1))
212+assert(not pcall(debug.getlocal,0x14,0x1))
213−assert(not pcall(debug.setlocal,- 1,1,10))
213+assert(not pcall(debug.setlocal,- 0x1,0x1,0xa))
214local function foo
214local function foo
215(a,b, ...)
215(a,b, ...)
216local d,e
216local d,e
217end
217end
218local co = coroutine.create(foo)
218local co = coroutine.create(foo)
219−assert(debug.getlocal(foo,1) == "\u{61}")
219+assert(debug.getlocal(foo,0x1) == "\u{61}")
220−assert(debug.getlocal(foo,2) == "\u{62}")
220+assert(debug.getlocal(foo,0x2) == "\u{62}")
221−assert(not debug.getlocal(foo,3))
221+assert(not debug.getlocal(foo,0x3))
222−assert(debug.getlocal(co,foo,1) == "\u{61}")
222+assert(debug.getlocal(co,foo,0x1) == "\u{61}")
223−assert(debug.getlocal(co,foo,2) == "\u{62}")
223+assert(debug.getlocal(co,foo,0x2) == "\u{62}")
224−assert(not debug.getlocal(co,foo,3))
224+assert(not debug.getlocal(co,foo,0x3))
225−assert(not debug.getlocal(print,1))
225+assert(not debug.getlocal(print,0x1))
226local function foo
226local function foo
227()
227()
228−return (debug.getlocal(1,- 1))
228+return (debug.getlocal(0x1,- 0x1))
229end
229end
230−assert(not foo(10))
230+assert(not foo(0xa))
231local function foo
231local function foo
232(a, ...)
232(a, ...)
233local t = table.pack(...)
233local t = table.pack(...)
234−for i = 1, t.n
234+for i = 0x1, t.n
235do
235do
236−local n,v = debug.getlocal(1,- i)
236+local n,v = debug.getlocal(0x1,- i)
237assert(n == "\u{28}\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{29}" and v == t[i])
237assert(n == "\u{28}\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{29}" and v == t[i])
238end
238end
239−assert(not debug.getlocal(1,- (t.n + 1)))
239+assert(not debug.getlocal(0x1,- (t.n + 0x1)))
240−assert(not debug.setlocal(1,- (t.n + 1),30))
240+assert(not debug.setlocal(0x1,- (t.n + 0x1),0x1e))
241−if t.n > 0 then
241+if t.n > 0x0 then
242(function (x)
242(function (x)
243−assert(debug.setlocal(2,- 1,x) == "\u{28}\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{29}")
243+assert(debug.setlocal(0x2,- 0x1,x) == "\u{28}\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{29}")
244−assert(debug.setlocal(2,- t.n,x) == "\u{28}\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{29}")
244+assert(debug.setlocal(0x2,- t.n,x) == "\u{28}\u{76}\u{61}\u{72}\u{61}\u{72}\u{67}\u{29}")
245−end)(430)
245+end)(0x1ae)
246−assert(... == 430)
246+assert(... == 0x1ae)
247end
247end
248end
248end
249foo()
249foo()
250foo(print)
250foo(print)
251−foo(200,3,4)
251+foo(0xc8,0x3,0x4)
252local a = {}
252local a = {}
253−for i = 1, (_soft and 100 or 1000)
253+for i = 0x1, (_soft and 0x64 or 0x3e8)
254do
254do
255a[i]=i
255a[i]=i
256end
256end
257foo(table.unpack(a))
257foo(table.unpack(a))
258do
258do
259assert(not debug.gethook())
259assert(not debug.gethook())
260−local count = 0
260+local count = 0x0
261local function f
261local function f
262()
262()
263−assert(debug.getinfo(1).namewhat == "\u{68}\u{6f}\u{6f}\u{6b}")
263+assert(debug.getinfo(0x1).namewhat == "\u{68}\u{6f}\u{6f}\u{6b}")
264local sndline = string.match(debug.traceback(),"\u{a}\u{28}\u{2e}\u{2d}\u{29}\u{a}")
264local sndline = string.match(debug.traceback(),"\u{a}\u{28}\u{2e}\u{2d}\u{29}\u{a}")
265assert(string.find(sndline,"\u{68}\u{6f}\u{6f}\u{6b}"))
265assert(string.find(sndline,"\u{68}\u{6f}\u{6f}\u{6b}"))
266−count=count + 1
266+count=count + 0x1
267end
267end
268debug.sethook(f,"\u{6c}")
268debug.sethook(f,"\u{6c}")
269−local a = 0
269+local a = 0x0
270_ENV.a=a
270_ENV.a=a
271−a=1
271+a=0x1
272debug.sethook()
272debug.sethook()
273−assert(count == 4)
273+assert(count == 0x4)
274end
274end
275_ENV.a=nil
275_ENV.a=nil
276assert(getmetatable(debug.getregistry()._HOOKKEY).__mode == "\u{6b}")
276assert(getmetatable(debug.getregistry()._HOOKKEY).__mode == "\u{6b}")
277a={}
277a={}
278;
278;
279local L = nil
279local L = nil
280−local glob = 1
280+local glob = 0x1
281local oldglob = glob
281local oldglob = glob
282debug.sethook(function (e,l)
282debug.sethook(function (e,l)
283collectgarbage()
283collectgarbage()
284local f,m,c = debug.gethook()
284local f,m,c = debug.gethook()
285−assert(m == "\u{63}\u{72}\u{6c}" and c == 0)
285+assert(m == "\u{63}\u{72}\u{6c}" and c == 0x0)
286if e == "\u{6c}\u{69}\u{6e}\u{65}" then
286if e == "\u{6c}\u{69}\u{6e}\u{65}" then
287if glob ~= oldglob then
287if glob ~= oldglob then
288−L=l - 1
288+L=l - 0x1
289oldglob=glob
289oldglob=glob
290end
290end
291elseif e == "\u{63}\u{61}\u{6c}\u{6c}" then
291elseif e == "\u{63}\u{61}\u{6c}\u{6c}" then
292−local f = debug.getinfo(2,"\u{66}").func
292+local f = debug.getinfo(0x2,"\u{66}").func
293−a[f]=1
293+a[f]=0x1
294else
294else
295assert(e == "\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}")
295assert(e == "\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}")
296end
296end
297end,"\u{63}\u{72}\u{6c}")
297end,"\u{63}\u{72}\u{6c}")
298function f(a,b)
298function f(a,b)
299collectgarbage()
299collectgarbage()
300−local _,x = debug.getlocal(1,1)
300+local _,x = debug.getlocal(0x1,0x1)
301−local _,y = debug.getlocal(1,2)
301+local _,y = debug.getlocal(0x1,0x2)
302assert(x == a and y == b)
302assert(x == a and y == b)
303−assert(debug.setlocal(2,3,"\u{70}\u{65}\u{72}\u{61}") == "\u{41}\u{41}" .. "\u{41}\u{41}")
303+assert(debug.setlocal(0x2,0x3,"\u{70}\u{65}\u{72}\u{61}") == "\u{41}\u{41}" .. "\u{41}\u{41}")
304−assert(debug.setlocal(2,4,"\u{6d}\u{61}\u{6e}\u{67}\u{61}") == "\u{42}")
304+assert(debug.setlocal(0x2,0x4,"\u{6d}\u{61}\u{6e}\u{67}\u{61}") == "\u{42}")
305−x=debug.getinfo(2)
305+x=debug.getinfo(0x2)
306−assert(x.func == g and x.what == "\u{4c}\u{75}\u{61}" and x.name == "\u{67}" and x.nups == 2 and string.find(x.source,"\u{5e}\u{40}\u{2e}\u{2a}\u{64}\u{62}\u{25}\u{2e}\u{6c}\u{75}\u{61}\u{24}"))
306+assert(x.func == g and x.what == "\u{4c}\u{75}\u{61}" and x.name == "\u{67}" and x.nups == 0x2 and string.find(x.source,"\u{5e}\u{40}\u{2e}\u{2a}\u{64}\u{62}\u{25}\u{2e}\u{6c}\u{75}\u{61}\u{24}"))
307−glob=glob + 1
307+glob=glob + 0x1
308−assert(debug.getinfo(1,"\u{6c}").currentline == L + 1)
308+assert(debug.getinfo(0x1,"\u{6c}").currentline == L + 0x1)
309−assert(debug.getinfo(1,"\u{6c}").currentline == L + 2)
309+assert(debug.getinfo(0x1,"\u{6c}").currentline == L + 0x2)
310end
310end
311function foo()
311function foo()
312−glob=glob + 1
312+glob=glob + 0x1
313−assert(debug.getinfo(1,"\u{6c}").currentline == L + 1)
313+assert(debug.getinfo(0x1,"\u{6c}").currentline == L + 0x1)
314end
314end
315;
315;
316foo()
316foo()
317local _ = "\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}" .. "\u{a}"
317local _ = "\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}" .. "\u{a}"
318−assert(debug.getinfo(1,"\u{6c}").currentline == L + 11)
318+assert(debug.getinfo(0x1,"\u{6c}").currentline == L + 0xb)
319function g(...)
319function g(...)
320local arg = {...}
320local arg = {...}
321do
321do
322local a,b,c
322local a,b,c
323;
323;
324−a=math.sin(40)
324+a=math.sin(0x28)
325;
325;
326end
326end
327local feijao
327local feijao
@@ -329,65 +329,65 @@ local AAAA,B = "\u{78}\u{75}\u{78}\u{75}","\u{61}\u{62}\u{61}\u{63}\u{61}\u{74}\
329f(AAAA,B)
329f(AAAA,B)
330assert(AAAA == "\u{70}\u{65}\u{72}\u{61}" and B == "\u{6d}\u{61}\u{6e}\u{67}\u{61}")
330assert(AAAA == "\u{70}\u{65}\u{72}\u{61}" and B == "\u{6d}\u{61}\u{6e}\u{67}\u{61}")
331do
331do
332−local B = 13
332+local B = 0xd
333−local x,y = debug.getlocal(1,5)
333+local x,y = debug.getlocal(0x1,0x5)
334−assert(x == "\u{42}" and y == 13)
334+assert(x == "\u{42}" and y == 0xd)
335end
335end
336end
336end
337g()
337g()
338assert(a[f] and a[g] and a[assert] and a[debug.getlocal] and not a[print])
338assert(a[f] and a[g] and a[assert] and a[debug.getlocal] and not a[print])
339−local n,v = debug.getlocal(0,1)
339+local n,v = debug.getlocal(0x0,0x1)
340−assert(v == 0 and n == "\u{28}\u{43}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
340+assert(v == 0x0 and n == "\u{28}\u{43}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
341−local n,v = debug.getlocal(0,2)
341+local n,v = debug.getlocal(0x0,0x2)
342−assert(v == 2 and n == "\u{28}\u{43}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
342+assert(v == 0x2 and n == "\u{28}\u{43}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
343−assert(not debug.getlocal(0,3))
343+assert(not debug.getlocal(0x0,0x3))
344−assert(not debug.getlocal(0,0))
344+assert(not debug.getlocal(0x0,0x0))
345function f()
345function f()
346−assert(select(2,debug.getlocal(2,3)) == 1)
346+assert(select(0x2,debug.getlocal(0x2,0x3)) == 0x1)
347−assert(not debug.getlocal(2,4))
347+assert(not debug.getlocal(0x2,0x4))
348−debug.setlocal(2,3,10)
348+debug.setlocal(0x2,0x3,0xa)
349−return 20
349+return 0x14
350end
350end
351function g(a,b)
351function g(a,b)
352−return (a + 1) + f()
352+return (a + 0x1) + f()
353end
353end
354−assert(g(0,0) == 30)
354+assert(g(0x0,0x0) == 0x1e)
355_G.f,_G.g=nil
355_G.f,_G.g=nil
356debug.sethook(nil)
356debug.sethook(nil)
357;
357;
358assert(not debug.gethook())
358assert(not debug.gethook())
359do
359do
360−assert(not debug.setuservalue(io.stdin,10))
360+assert(not debug.setuservalue(io.stdin,0xa))
361−local a,b = debug.getuservalue(io.stdin,10)
361+local a,b = debug.getuservalue(io.stdin,0xa)
362assert(a == nil and not b)
362assert(a == nil and not b)
363end
363end
364do
364do
365local function f
365local function f
366(...)
366(...)
367−return 3,...
367+return 0x3,...
368end
368end
369−local count = 0
369+local count = 0x0
370local a = {}
370local a = {}
371−for i = 1, 100
371+for i = 0x1, 0x64
372do
372do
373a[i]=i
373a[i]=i
374end
374end
375debug.sethook(function ()
375debug.sethook(function ()
376−count=count + 1
376+count=count + 0x1
377−end,"",1)
377+end,"",0x1)
378local t = {table.unpack(a)}
378local t = {table.unpack(a)}
379−assert(# t == 100)
379+assert(# t == 0x64)
380−t={table.unpack(a,1,3)}
380+t={table.unpack(a,0x1,0x3)}
381−assert(# t == 3)
381+assert(# t == 0x3)
382−t={f(table.unpack(a,1,30))}
382+t={f(table.unpack(a,0x1,0x1e))}
383−assert(# t == 31)
383+assert(# t == 0x1f)
384end
384end
385local function collectlocals
385local function collectlocals
386(level)
386(level)
387local tab = {}
387local tab = {}
388−for i = 1, math.huge
388+for i = 0x1, math.huge
389do
389do
390−local n,v = debug.getlocal(level + 1,i)
390+local n,v = debug.getlocal(level + 0x1,i)
391if not (n and string.find(n,"\u{5e}\u{5b}\u{61}\u{2d}\u{7a}\u{41}\u{2d}\u{5a}\u{30}\u{2d}\u{39}\u{5f}\u{5d}\u{2b}\u{24}")) then
391if not (n and string.find(n,"\u{5e}\u{5b}\u{61}\u{2d}\u{7a}\u{41}\u{2d}\u{5a}\u{30}\u{2d}\u{39}\u{5f}\u{5d}\u{2b}\u{24}")) then
392break
392break
393end
393end
@@ -400,25 +400,25 @@ a={}
400function a:f(a,b, ...)
400function a:f(a,b, ...)
401local arg = {...}
401local arg = {...}
402;
402;
403−local c = 13
403+local c = 0xd
404end
404end
405debug.sethook(function (e)
405debug.sethook(function (e)
406assert(e == "\u{63}\u{61}\u{6c}\u{6c}")
406assert(e == "\u{63}\u{61}\u{6c}\u{6c}")
407dostring("\u{58}\u{58}\u{20}\u{3d}\u{20}\u{31}\u{32}")
407dostring("\u{58}\u{58}\u{20}\u{3d}\u{20}\u{31}\u{32}")
408assert(not pcall(load("\u{61}\u{3d}\u{27}\u{6a}\u{6f}\u{61}\u{6f}\u{27}\u{2b}\u{31}")))
408assert(not pcall(load("\u{61}\u{3d}\u{27}\u{6a}\u{6f}\u{61}\u{6f}\u{27}\u{2b}\u{31}")))
409debug.sethook(function (e,l)
409debug.sethook(function (e,l)
410−assert(debug.getinfo(2,"\u{6c}").currentline == l)
410+assert(debug.getinfo(0x2,"\u{6c}").currentline == l)
411local f,m,c = debug.gethook()
411local f,m,c = debug.gethook()
412assert(e == "\u{6c}\u{69}\u{6e}\u{65}")
412assert(e == "\u{6c}\u{69}\u{6e}\u{65}")
413−assert(m == "\u{6c}" and c == 0)
413+assert(m == "\u{6c}" and c == 0x0)
414debug.sethook(nil)
414debug.sethook(nil)
415assert(not X)
415assert(not X)
416−X=collectlocals(2)
416+X=collectlocals(0x2)
417end,"\u{6c}")
417end,"\u{6c}")
418end,"\u{63}")
418end,"\u{63}")
419−a:f(1,2,3,4,5)
419+a:f(0x1,0x2,0x3,0x4,0x5)
420−assert(X.self == a and X.a == 1 and X.b == 2 and X.c == nil)
420+assert(X.self == a and X.a == 0x1 and X.b == 0x2 and X.c == nil)
421−assert(XX == 12)
421+assert(XX == 0xc)
422assert(not debug.gethook())
422assert(not debug.gethook())
423_G.XX=nil
423_G.XX=nil
424do
424do
@@ -428,15 +428,15 @@ local function foo
428do
428do
429local x,y,z
429local x,y,z
430end
430end
431−local c,d = 10,20
431+local c,d = 0xa,0x14
432return
432return
433end
433end
434local function aux
434local function aux
435()
435()
436−if debug.getinfo(2).name == "\u{66}\u{6f}\u{6f}" then
436+if debug.getinfo(0x2).name == "\u{66}\u{6f}\u{6f}" then
437X=true
437X=true
438−local tab = {["\u{61}"] = 100,["\u{62}"] = 200,["\u{63}"] = 10,["\u{64}"] = 20}
438+local tab = {["\u{61}"] = 0x64,["\u{62}"] = 0xc8,["\u{63}"] = 0xa,["\u{64}"] = 0x14}
439−for n,v in pairs(collectlocals(2))
439+for n,v in pairs(collectlocals(0x2))
440do
440do
441assert(tab[n] == v)
441assert(tab[n] == v)
442tab[n]=undef
442tab[n]=undef
@@ -446,7 +446,7 @@ end
446end
446end
447debug.sethook(aux,"\u{72}")
447debug.sethook(aux,"\u{72}")
448;
448;
449−foo(100,200)
449+foo(0x64,0xc8)
450;
450;
451debug.sethook()
451debug.sethook()
452assert(X)
452assert(X)
@@ -454,7 +454,7 @@ end
454local function eqseq
454local function eqseq
455(t1,t2)
455(t1,t2)
456assert(# t1 == # t2)
456assert(# t1 == # t2)
457−for i = 1, # t1
457+for i = 0x1, # t1
458do
458do
459assert(t1[i] == t2[i])
459assert(t1[i] == t2[i])
460end
460end
@@ -468,12 +468,12 @@ local function hook
468if not on then
468if not on then
469return
469return
470end
470end
471−local ar = debug.getinfo(2,"\u{72}\u{75}\u{53}")
471+local ar = debug.getinfo(0x2,"\u{72}\u{75}\u{53}")
472local t = {}
472local t = {}
473−for i = ar.ftransfer, ar.ftransfer + ar.ntransfer - 1
473+for i = ar.ftransfer, ar.ftransfer + ar.ntransfer - 0x1
474do
474do
475−local _,v = debug.getlocal(2,i)
475+local _,v = debug.getlocal(0x2,i)
476−t[# t + 1]=v
476+t[# t + 0x1]=v
477end
477end
478if event == "\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}" then
478if event == "\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}" then
479out=t
479out=t
@@ -484,20 +484,20 @@ end
484debug.sethook(hook,"\u{63}\u{72}")
484debug.sethook(hook,"\u{63}\u{72}")
485on=true
485on=true
486;
486;
487−math.sin(3)
487+math.sin(0x3)
488;
488;
489on=false
489on=false
490−eqseq(inp,{3})
490+eqseq(inp,{0x3})
491;
491;
492−eqseq(out,{math.sin(3)})
492+eqseq(out,{math.sin(0x3)})
493on=true
493on=true
494;
494;
495−select(2,10,20,30,40)
495+select(0x2,0xa,0x14,0x1e,0x28)
496;
496;
497on=false
497on=false
498−eqseq(inp,{2,10,20,30,40})
498+eqseq(inp,{0x2,0xa,0x14,0x1e,0x28})
499;
499;
500−eqseq(out,{20,30,40})
500+eqseq(out,{0x14,0x1e,0x28})
501local function foo
501local function foo
502(a, ...)
502(a, ...)
503return ...
503return ...
@@ -506,20 +506,20 @@ local function foo1
506()
506()
507on=not on
507on=not on
508;
508;
509−return foo(20,10,0)
509+return foo(0x14,0xa,0x0)
510end
510end
511foo1()
511foo1()
512;
512;
513on=false
513on=false
514−eqseq(inp,{20})
514+eqseq(inp,{0x14})
515;
515;
516−eqseq(out,{10,0})
516+eqseq(out,{0xa,0x0})
517debug.sethook()
517debug.sethook()
518end
518end
519local function getupvalues
519local function getupvalues
520(f)
520(f)
521local t = {}
521local t = {}
522−local i = 1
522+local i = 0x1
523while true do
523while true do
524local name,value = debug.getupvalue(f,i)
524local name,value = debug.getupvalue(f,i)
525if not name then
525if not name then
@@ -527,11 +527,11 @@ break
527end
527end
528assert(not t[name])
528assert(not t[name])
529t[name]=value
529t[name]=value
530−i=i + 1
530+i=i + 0x1
531end
531end
532return t
532return t
533end
533end
534−local a,b,c = 1,2,3
534+local a,b,c = 0x1,0x2,0x3
535local function foo1
535local function foo1
536(a)
536(a)
537b=a
537b=a
@@ -544,67 +544,67 @@ a=x
544;
544;
545return c + b
545return c + b
546end
546end
547−assert(not debug.getupvalue(foo1,3))
547+assert(not debug.getupvalue(foo1,0x3))
548−assert(not debug.getupvalue(foo1,0))
548+assert(not debug.getupvalue(foo1,0x0))
549−assert(not debug.setupvalue(foo1,3,"\u{78}\u{75}\u{78}\u{75}"))
549+assert(not debug.setupvalue(foo1,0x3,"\u{78}\u{75}\u{78}\u{75}"))
550local t = getupvalues(foo1)
550local t = getupvalues(foo1)
551−assert(t.a == nil and t.b == 2 and t.c == 3)
551+assert(t.a == nil and t.b == 0x2 and t.c == 0x3)
552t=getupvalues(foo2)
552t=getupvalues(foo2)
553−assert(t.a == 1 and t.b == 2 and t.c == 3)
553+assert(t.a == 0x1 and t.b == 0x2 and t.c == 0x3)
554−assert(debug.setupvalue(foo1,1,"\u{78}\u{75}\u{78}\u{75}") == "\u{62}")
554+assert(debug.setupvalue(foo1,0x1,"\u{78}\u{75}\u{78}\u{75}") == "\u{62}")
555−assert(({debug.getupvalue(foo2,3)})[2] == "\u{78}\u{75}\u{78}\u{75}")
555+assert(({debug.getupvalue(foo2,0x3)})[0x2] == "\u{78}\u{75}\u{78}\u{75}")
556−assert(debug.getupvalue(string.gmatch("\u{78}","\u{78}"),1) == "")
556+assert(debug.getupvalue(string.gmatch("\u{78}","\u{78}"),0x1) == "")
557−local a = 0
557+local a = 0x0
558debug.sethook(function (e)
558debug.sethook(function (e)
559−a=a + 1
559+a=a + 0x1
560−end,"",1)
560+end,"",0x1)
561−a=0
561+a=0x0
562;
562;
563−for i = 1, 1000
563+for i = 0x1, 0x3e8
564do
564do
565
565
566end
566end
567;
567;
568−assert(1000 < a and a < 1012)
568+assert(0x3e8 < a and a < 0x3f4)
569debug.sethook(function (e)
569debug.sethook(function (e)
570−a=a + 1
570+a=a + 0x1
571−end,"",4)
571+end,"",0x4)
572−a=0
572+a=0x0
573;
573;
574−for i = 1, 1000
574+for i = 0x1, 0x3e8
575do
575do
576
576
577end
577end
578;
578;
579−assert(250 < a and a < 255)
579+assert(0xfa < a and a < 0xff)
580local f,m,c = debug.gethook()
580local f,m,c = debug.gethook()
581−assert(m == "" and c == 4)
581+assert(m == "" and c == 0x4)
582debug.sethook(function (e)
582debug.sethook(function (e)
583−a=a + 1
583+a=a + 0x1
584−end,"",4000)
584+end,"",0xfa0)
585−a=0
585+a=0x0
586;
586;
587−for i = 1, 1000
587+for i = 0x1, 0x3e8
588do
588do
589
589
590end
590end
591;
591;
592−assert(a == 0)
592+assert(a == 0x0)
593do
593do
594−debug.sethook(print,"",2 ^ 24 - 1)
594+debug.sethook(print,"",0x2 ^ 0x18 - 0x1)
595local f,m,c = debug.gethook()
595local f,m,c = debug.gethook()
596−assert(({debug.gethook()})[3] == 2 ^ 24 - 1)
596+assert(({debug.gethook()})[0x3] == 0x2 ^ 0x18 - 0x1)
597end
597end
598debug.sethook()
598debug.sethook()
599local g,g1
599local g,g1
600local function f
600local function f
601(x)
601(x)
602if x then
602if x then
603−assert(debug.getinfo(1,"\u{53}").what == "\u{4c}\u{75}\u{61}")
603+assert(debug.getinfo(0x1,"\u{53}").what == "\u{4c}\u{75}\u{61}")
604−assert(debug.getinfo(1,"\u{74}").istailcall == true)
604+assert(debug.getinfo(0x1,"\u{74}").istailcall == true)
605−local tail = debug.getinfo(2)
605+local tail = debug.getinfo(0x2)
606assert(tail.func == g1 and tail.istailcall == true)
606assert(tail.func == g1 and tail.istailcall == true)
607−assert(debug.getinfo(3,"\u{53}").what == "\u{6d}\u{61}\u{69}\u{6e}")
607+assert(debug.getinfo(0x3,"\u{53}").what == "\u{6d}\u{61}\u{69}\u{6e}")
608print("\u{2b}")
608print("\u{2b}")
609end
609end
610end
610end
@@ -628,57 +628,57 @@ end,"\u{63}\u{72}")
628h(false)
628h(false)
629debug.sethook()
629debug.sethook()
630local res = {"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}","\u{63}\u{61}\u{6c}\u{6c}","\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}","\u{63}\u{61}\u{6c}\u{6c}","\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}","\u{63}\u{61}\u{6c}\u{6c}"}
630local res = {"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}","\u{63}\u{61}\u{6c}\u{6c}","\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}","\u{63}\u{61}\u{6c}\u{6c}","\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}","\u{63}\u{61}\u{6c}\u{6c}"}
631−for i = 1, # res
631+for i = 0x1, # res
632do
632do
633−assert(res[i] == table.remove(b,1))
633+assert(res[i] == table.remove(b,0x1))
634end
634end
635−b=0
635+b=0x0
636debug.sethook(function (e)
636debug.sethook(function (e)
637if e == "\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}" then
637if e == "\u{74}\u{61}\u{69}\u{6c}\u{20}\u{63}\u{61}\u{6c}\u{6c}" then
638−b=b + 1
638+b=b + 0x1
639−assert(debug.getinfo(2,"\u{74}").istailcall == true)
639+assert(debug.getinfo(0x2,"\u{74}").istailcall == true)
640else
640else
641−assert(debug.getinfo(2,"\u{74}").istailcall == false)
641+assert(debug.getinfo(0x2,"\u{74}").istailcall == false)
642end
642end
643end,"\u{63}")
643end,"\u{63}")
644h(false)
644h(false)
645debug.sethook()
645debug.sethook()
646−assert(b == 2)
646+assert(b == 0x2)
647−local lim = _soft and 3000 or 30000
647+local lim = _soft and 0xbb8 or 0x7530
648local function foo
648local function foo
649(x)
649(x)
650−if x == 0 then
650+if x == 0x0 then
651−assert(debug.getinfo(2).what == "\u{6d}\u{61}\u{69}\u{6e}")
651+assert(debug.getinfo(0x2).what == "\u{6d}\u{61}\u{69}\u{6e}")
652−local info = debug.getinfo(1)
652+local info = debug.getinfo(0x1)
653assert(info.istailcall == true and info.func == foo)
653assert(info.istailcall == true and info.func == foo)
654else
654else
655−return foo(x - 1)
655+return foo(x - 0x1)
656end
656end
657end
657end
658foo(lim)
658foo(lim)
659print("\u{2b}")
659print("\u{2b}")
660co=load("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{41}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{a}")
660co=load("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{41}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{a}")
661−local a = 0
661+local a = 0x0
662debug.sethook(function (e,l)
662debug.sethook(function (e,l)
663−if l == 3 then
663+if l == 0x3 then
664−a=a + 1
664+a=a + 0x1
665;
665;
666−assert(debug.getlocal(2,1) == "\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
666+assert(debug.getlocal(0x2,0x1) == "\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
667−elseif l == 4 then
667+elseif l == 0x4 then
668−a=a + 1
668+a=a + 0x1
669;
669;
670−assert(debug.getlocal(2,1) == "\u{41}")
670+assert(debug.getlocal(0x2,0x1) == "\u{41}")
671end
671end
672end,"\u{6c}")
672end,"\u{6c}")
673co()
673co()
674debug.sethook()
674debug.sethook()
675−assert(a == 2)
675+assert(a == 0x2)
676assert(debug.traceback(print) == print)
676assert(debug.traceback(print) == print)
677−assert(debug.traceback(print,4) == print)
677+assert(debug.traceback(print,0x4) == print)
678−assert(string.find(debug.traceback("\u{68}\u{69}",4),"\u{5e}\u{68}\u{69}\u{a}"))
678+assert(string.find(debug.traceback("\u{68}\u{69}",0x4),"\u{5e}\u{68}\u{69}\u{a}"))
679assert(string.find(debug.traceback("\u{68}\u{69}"),"\u{5e}\u{68}\u{69}\u{a}"))
679assert(string.find(debug.traceback("\u{68}\u{69}"),"\u{5e}\u{68}\u{69}\u{a}"))
680assert(not string.find(debug.traceback("\u{68}\u{69}"),"\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{27}"))
680assert(not string.find(debug.traceback("\u{68}\u{69}"),"\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{27}"))
681−assert(string.find(debug.traceback("\u{68}\u{69}",0),"\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{27}"))
681+assert(string.find(debug.traceback("\u{68}\u{69}",0x0),"\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{27}"))
682assert(string.find(debug.traceback(),"\u{5e}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{3a}\u{a}"))
682assert(string.find(debug.traceback(),"\u{5e}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{3a}\u{a}"))
683do
683do
684local st,msg = (function ()
684local st,msg = (function ()
@@ -687,51 +687,51 @@ end)()(debug.traceback)
687assert(st == true and string.find(msg,"\u{70}\u{63}\u{61}\u{6c}\u{6c}"))
687assert(st == true and string.find(msg,"\u{70}\u{63}\u{61}\u{6c}\u{6c}"))
688end
688end
689local t = debug.getinfo(print,"\u{75}")
689local t = debug.getinfo(print,"\u{75}")
690−assert(t.isvararg == true and t.nparams == 0 and t.nups == 0)
690+assert(t.isvararg == true and t.nparams == 0x0 and t.nups == 0x0)
691t=debug.getinfo(function (a,b,c)
691t=debug.getinfo(function (a,b,c)
692
692
693end,"\u{75}")
693end,"\u{75}")
694−assert(t.isvararg == false and t.nparams == 3 and t.nups == 0)
694+assert(t.isvararg == false and t.nparams == 0x3 and t.nups == 0x0)
695t=debug.getinfo(function (a,b, ...)
695t=debug.getinfo(function (a,b, ...)
696return t[a]
696return t[a]
697end,"\u{75}")
697end,"\u{75}")
698−assert(t.isvararg == true and t.nparams == 2 and t.nups == 1)
698+assert(t.isvararg == true and t.nparams == 0x2 and t.nups == 0x1)
699−t=debug.getinfo(1)
699+t=debug.getinfo(0x1)
700−assert(t.isvararg == true and t.nparams == 0 and t.nups == 1 and debug.getupvalue(t.func,1) == "\u{5f}\u{45}\u{4e}\u{56}")
700+assert(t.isvararg == true and t.nparams == 0x0 and t.nups == 0x1 and debug.getupvalue(t.func,0x1) == "\u{5f}\u{45}\u{4e}\u{56}")
701t=debug.getinfo(math.sin)
701t=debug.getinfo(math.sin)
702−assert(t.isvararg == true and t.nparams == 0 and t.nups == 0)
702+assert(t.isvararg == true and t.nparams == 0x0 and t.nups == 0x0)
703t=debug.getinfo(string.gmatch("\u{61}\u{62}\u{63}","\u{61}"))
703t=debug.getinfo(string.gmatch("\u{61}\u{62}\u{63}","\u{61}"))
704−assert(t.isvararg == true and t.nparams == 0 and t.nups > 0)
704+assert(t.isvararg == true and t.nparams == 0x0 and t.nups > 0x0)
705local function checktraceback
705local function checktraceback
706(co,p,level)
706(co,p,level)
707local tb = debug.traceback(co,nil,level)
707local tb = debug.traceback(co,nil,level)
708−local i = 0
708+local i = 0x0
709for l in string.gmatch(tb,"\u{5b}\u{5e}\u{a}\u{5d}\u{2b}\u{a}\u{3f}")
709for l in string.gmatch(tb,"\u{5b}\u{5e}\u{a}\u{5d}\u{2b}\u{a}\u{3f}")
710do
710do
711−assert(i == 0 or string.find(l,p[i]))
711+assert(i == 0x0 or string.find(l,p[i]))
712−i=i + 1
712+i=i + 0x1
713end
713end
714assert(p[i] == undef)
714assert(p[i] == undef)
715end
715end
716local function f
716local function f
717(n)
717(n)
718−if n > 0 then
718+if n > 0x0 then
719−f(n - 1)
719+f(n - 0x1)
720else
720else
721coroutine.yield()
721coroutine.yield()
722end
722end
723end
723end
724local co = coroutine.create(f)
724local co = coroutine.create(f)
725−coroutine.resume(co,3)
725+coroutine.resume(co,0x3)
726checktraceback(co,{"\u{79}\u{69}\u{65}\u{6c}\u{64}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"})
726checktraceback(co,{"\u{79}\u{69}\u{65}\u{6c}\u{64}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"})
727−checktraceback(co,{"\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"},1)
727+checktraceback(co,{"\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"},0x1)
728−checktraceback(co,{"\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"},2)
728+checktraceback(co,{"\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}","\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"},0x2)
729−checktraceback(co,{"\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"},4)
729+checktraceback(co,{"\u{64}\u{62}\u{2e}\u{6c}\u{75}\u{61}"},0x4)
730−checktraceback(co,{},40)
730+checktraceback(co,{},0x28)
731co=coroutine.create(function (x)
731co=coroutine.create(function (x)
732−local a = 1
732+local a = 0x1
733−coroutine.yield(debug.getinfo(1,"\u{6c}"))
733+coroutine.yield(debug.getinfo(0x1,"\u{6c}"))
734−coroutine.yield(debug.getinfo(1,"\u{6c}").currentline)
734+coroutine.yield(debug.getinfo(0x1,"\u{6c}").currentline)
735return a
735return a
736end)
736end)
737local tr = {}
737local tr = {}
@@ -741,67 +741,67 @@ table.insert(tr,l)
741end
741end
742end
742end
743debug.sethook(co,foo,"\u{6c}\u{63}\u{72}")
743debug.sethook(co,foo,"\u{6c}\u{63}\u{72}")
744−local _,l = coroutine.resume(co,10)
744+local _,l = coroutine.resume(co,0xa)
745−local x = debug.getinfo(co,1,"\u{6c}\u{66}\u{4c}\u{53}")
745+local x = debug.getinfo(co,0x1,"\u{6c}\u{66}\u{4c}\u{53}")
746assert(x.currentline == l.currentline and x.activelines[x.currentline])
746assert(x.currentline == l.currentline and x.activelines[x.currentline])
747assert(type(x.func) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
747assert(type(x.func) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
748−for i = x.linedefined + 1, x.lastlinedefined
748+for i = x.linedefined + 0x1, x.lastlinedefined
749do
749do
750assert(x.activelines[i])
750assert(x.activelines[i])
751x.activelines[i]=undef
751x.activelines[i]=undef
752end
752end
753assert(next(x.activelines) == nil)
753assert(next(x.activelines) == nil)
754−assert(not debug.getinfo(co,2))
754+assert(not debug.getinfo(co,0x2))
755−local a,b = debug.getlocal(co,1,1)
755+local a,b = debug.getlocal(co,0x1,0x1)
756−assert(a == "\u{78}" and b == 10)
756+assert(a == "\u{78}" and b == 0xa)
757−a,b=debug.getlocal(co,1,2)
757+a,b=debug.getlocal(co,0x1,0x2)
758−assert(a == "\u{61}" and b == 1)
758+assert(a == "\u{61}" and b == 0x1)
759−debug.setlocal(co,1,2,"\u{68}\u{69}")
759+debug.setlocal(co,0x1,0x2,"\u{68}\u{69}")
760assert(debug.gethook(co) == foo)
760assert(debug.gethook(co) == foo)
761−assert(# tr == 2 and tr[1] == l.currentline - 1 and tr[2] == l.currentline)
761+assert(# tr == 0x2 and tr[0x1] == l.currentline - 0x1 and tr[0x2] == l.currentline)
762a,b,c=pcall(coroutine.resume,co)
762a,b,c=pcall(coroutine.resume,co)
763−assert(a and b and c == l.currentline + 1)
763+assert(a and b and c == l.currentline + 0x1)
764checktraceback(co,{"\u{79}\u{69}\u{65}\u{6c}\u{64}","\u{69}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{3c}"})
764checktraceback(co,{"\u{79}\u{69}\u{65}\u{6c}\u{64}","\u{69}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{3c}"})
765a,b=coroutine.resume(co)
765a,b=coroutine.resume(co)
766assert(a and b == "\u{68}\u{69}")
766assert(a and b == "\u{68}\u{69}")
767−assert(# tr == 4 and tr[4] == l.currentline + 2)
767+assert(# tr == 0x4 and tr[0x4] == l.currentline + 0x2)
768assert(debug.gethook(co) == foo)
768assert(debug.gethook(co) == foo)
769assert(not debug.gethook())
769assert(not debug.gethook())
770checktraceback(co,{})
770checktraceback(co,{})
771co=coroutine.create(function (x)
771co=coroutine.create(function (x)
772local a,b = coroutine.yield(x)
772local a,b = coroutine.yield(x)
773−assert(a == 100 and b == nil)
773+assert(a == 0x64 and b == nil)
774return x
774return x
775end)
775end)
776−a,b=coroutine.resume(co,10)
776+a,b=coroutine.resume(co,0xa)
777−assert(a and b == 10)
777+assert(a and b == 0xa)
778−a,b=debug.getlocal(co,1,1)
778+a,b=debug.getlocal(co,0x1,0x1)
779−assert(a == "\u{78}" and b == 10)
779+assert(a == "\u{78}" and b == 0xa)
780−assert(not debug.getlocal(co,1,5))
780+assert(not debug.getlocal(co,0x1,0x5))
781−assert(debug.setlocal(co,1,1,30) == "\u{78}")
781+assert(debug.setlocal(co,0x1,0x1,0x1e) == "\u{78}")
782−assert(not debug.setlocal(co,1,5,40))
782+assert(not debug.setlocal(co,0x1,0x5,0x28))
783−a,b=coroutine.resume(co,100)
783+a,b=coroutine.resume(co,0x64)
784−assert(a and b == 30)
784+assert(a and b == 0x1e)
785function f(i)
785function f(i)
786−if i == 0 then
786+if i == 0x0 then
787error(i)
787error(i)
788else
788else
789coroutine.yield()
789coroutine.yield()
790;
790;
791−f(i - 1)
791+f(i - 0x1)
792end
792end
793end
793end
794co=coroutine.create(function (x)
794co=coroutine.create(function (x)
795f(x)
795f(x)
796end)
796end)
797−a,b=coroutine.resume(co,3)
797+a,b=coroutine.resume(co,0x3)
798t={"\u{27}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{27}","\u{27}\u{66}\u{27}","\u{69}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{3c}"}
798t={"\u{27}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{27}","\u{27}\u{66}\u{27}","\u{69}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{3c}"}
799while coroutine.status(co) == "\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}" do
799while coroutine.status(co) == "\u{73}\u{75}\u{73}\u{70}\u{65}\u{6e}\u{64}\u{65}\u{64}" do
800checktraceback(co,t)
800checktraceback(co,t)
801a,b=coroutine.resume(co)
801a,b=coroutine.resume(co)
802−table.insert(t,2,"\u{27}\u{66}\u{27}")
802+table.insert(t,0x2,"\u{27}\u{66}\u{27}")
803end
803end
804−t[1]="\u{27}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{27}"
804+t[0x1]="\u{27}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{27}"
805checktraceback(co,t)
805checktraceback(co,t)
806local function g
806local function g
807(x)
807(x)
@@ -812,20 +812,20 @@ local function f
812debug.sethook(function ()
812debug.sethook(function ()
813
813
814end,"\u{6c}")
814end,"\u{6c}")
815−for j = 1, 1000
815+for j = 0x1, 0x3e8
816do
816do
817g(i + j)
817g(i + j)
818end
818end
819end
819end
820local co = coroutine.wrap(f)
820local co = coroutine.wrap(f)
821−co(10)
821+co(0xa)
822pcall(co)
822pcall(co)
823pcall(co)
823pcall(co)
824assert(type(debug.getregistry()) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
824assert(type(debug.getregistry()) == "\u{74}\u{61}\u{62}\u{6c}\u{65}")
825local a = {}
825local a = {}
826local function f
826local function f
827(t)
827(t)
828−local info = debug.getinfo(1)
828+local info = debug.getinfo(0x1)
829;
829;
830assert(info.namewhat == "\u{6d}\u{65}\u{74}\u{61}\u{6d}\u{65}\u{74}\u{68}\u{6f}\u{64}")
830assert(info.namewhat == "\u{6d}\u{65}\u{74}\u{61}\u{6d}\u{65}\u{74}\u{68}\u{6f}\u{64}")
831a.op=info.name
831a.op=info.name
@@ -833,21 +833,21 @@ return info.name
833end
833end
834setmetatable(a,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = f,["\u{5f}\u{5f}\u{61}\u{64}\u{64}"] = f,["\u{5f}\u{5f}\u{64}\u{69}\u{76}"] = f,["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}"] = f,["\u{5f}\u{5f}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"] = f,["\u{5f}\u{5f}\u{70}\u{6f}\u{77}"] = f,["\u{5f}\u{5f}\u{6d}\u{75}\u{6c}"] = f,["\u{5f}\u{5f}\u{69}\u{64}\u{69}\u{76}"] = f,["\u{5f}\u{5f}\u{75}\u{6e}\u{6d}"] = f,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = f,["\u{5f}\u{5f}\u{73}\u{75}\u{62}"] = f,["\u{5f}\u{5f}\u{73}\u{68}\u{6c}"] = f,["\u{5f}\u{5f}\u{73}\u{68}\u{72}"] = f,["\u{5f}\u{5f}\u{62}\u{6f}\u{72}"] = f,["\u{5f}\u{5f}\u{62}\u{78}\u{6f}\u{72}"] = f,["\u{5f}\u{5f}\u{65}\u{71}"] = f,["\u{5f}\u{5f}\u{6c}\u{65}"] = f,["\u{5f}\u{5f}\u{6c}\u{74}"] = f,["\u{5f}\u{5f}\u{75}\u{6e}\u{6d}"] = f,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = f,["\u{5f}\u{5f}\u{62}\u{61}\u{6e}\u{64}"] = f,["\u{5f}\u{5f}\u{62}\u{6e}\u{6f}\u{74}"] = f})
834setmetatable(a,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = f,["\u{5f}\u{5f}\u{61}\u{64}\u{64}"] = f,["\u{5f}\u{5f}\u{64}\u{69}\u{76}"] = f,["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}"] = f,["\u{5f}\u{5f}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"] = f,["\u{5f}\u{5f}\u{70}\u{6f}\u{77}"] = f,["\u{5f}\u{5f}\u{6d}\u{75}\u{6c}"] = f,["\u{5f}\u{5f}\u{69}\u{64}\u{69}\u{76}"] = f,["\u{5f}\u{5f}\u{75}\u{6e}\u{6d}"] = f,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = f,["\u{5f}\u{5f}\u{73}\u{75}\u{62}"] = f,["\u{5f}\u{5f}\u{73}\u{68}\u{6c}"] = f,["\u{5f}\u{5f}\u{73}\u{68}\u{72}"] = f,["\u{5f}\u{5f}\u{62}\u{6f}\u{72}"] = f,["\u{5f}\u{5f}\u{62}\u{78}\u{6f}\u{72}"] = f,["\u{5f}\u{5f}\u{65}\u{71}"] = f,["\u{5f}\u{5f}\u{6c}\u{65}"] = f,["\u{5f}\u{5f}\u{6c}\u{74}"] = f,["\u{5f}\u{5f}\u{75}\u{6e}\u{6d}"] = f,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = f,["\u{5f}\u{5f}\u{62}\u{61}\u{6e}\u{64}"] = f,["\u{5f}\u{5f}\u{62}\u{6e}\u{6f}\u{74}"] = f})
835local b = setmetatable({},getmetatable(a))
835local b = setmetatable({},getmetatable(a))
836−assert(a[3] == "\u{69}\u{6e}\u{64}\u{65}\u{78}" and a ^ 3 == "\u{70}\u{6f}\u{77}" and a .. a == "\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}")
836+assert(a[0x3] == "\u{69}\u{6e}\u{64}\u{65}\u{78}" and a ^ 0x3 == "\u{70}\u{6f}\u{77}" and a .. a == "\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}")
837−assert(a / 3 == "\u{64}\u{69}\u{76}" and 3 % a == "\u{6d}\u{6f}\u{64}")
837+assert(a / 0x3 == "\u{64}\u{69}\u{76}" and 0x3 % a == "\u{6d}\u{6f}\u{64}")
838−assert(a + 3 == "\u{61}\u{64}\u{64}" and 3 - a == "\u{73}\u{75}\u{62}" and a * 3 == "\u{6d}\u{75}\u{6c}" and - a == "\u{75}\u{6e}\u{6d}" and # a == "\u{6c}\u{65}\u{6e}" and a & 3 == "\u{62}\u{61}\u{6e}\u{64}")
838+assert(a + 0x3 == "\u{61}\u{64}\u{64}" and 0x3 - a == "\u{73}\u{75}\u{62}" and a * 0x3 == "\u{6d}\u{75}\u{6c}" and - a == "\u{75}\u{6e}\u{6d}" and # a == "\u{6c}\u{65}\u{6e}" and a & 0x3 == "\u{62}\u{61}\u{6e}\u{64}")
839−assert(a + 30000 == "\u{61}\u{64}\u{64}" and a - 3.0 == "\u{73}\u{75}\u{62}" and a * 3.0 == "\u{6d}\u{75}\u{6c}" and - a == "\u{75}\u{6e}\u{6d}" and # a == "\u{6c}\u{65}\u{6e}" and a & 3 == "\u{62}\u{61}\u{6e}\u{64}")
839+assert(a + 0x7530 == "\u{61}\u{64}\u{64}" and a - 3.0 == "\u{73}\u{75}\u{62}" and a * 3.0 == "\u{6d}\u{75}\u{6c}" and - a == "\u{75}\u{6e}\u{6d}" and # a == "\u{6c}\u{65}\u{6e}" and a & 0x3 == "\u{62}\u{61}\u{6e}\u{64}")
840−assert(a | 3 == "\u{62}\u{6f}\u{72}" and 3 ~ a == "\u{62}\u{78}\u{6f}\u{72}" and a << 3 == "\u{73}\u{68}\u{6c}" and a >> 1 == "\u{73}\u{68}\u{72}")
840+assert(a | 0x3 == "\u{62}\u{6f}\u{72}" and 0x3 ~ a == "\u{62}\u{78}\u{6f}\u{72}" and a << 0x3 == "\u{73}\u{68}\u{6c}" and a >> 0x1 == "\u{73}\u{68}\u{72}")
841assert(a == b and a.op == "\u{65}\u{71}")
841assert(a == b and a.op == "\u{65}\u{71}")
842assert(a >= b and a.op == "\u{6c}\u{65}")
842assert(a >= b and a.op == "\u{6c}\u{65}")
843assert("\u{78}" >= a and a.op == "\u{6c}\u{65}")
843assert("\u{78}" >= a and a.op == "\u{6c}\u{65}")
844assert(a > b and a.op == "\u{6c}\u{74}")
844assert(a > b and a.op == "\u{6c}\u{74}")
845−assert(a > 10 and a.op == "\u{6c}\u{74}")
845+assert(a > 0xa and a.op == "\u{6c}\u{74}")
846assert(~ a == "\u{62}\u{6e}\u{6f}\u{74}")
846assert(~ a == "\u{62}\u{6e}\u{6f}\u{74}")
847do
847do
848local function f
848local function f
849()
849()
850−assert(debug.getinfo(1).name == "\u{66}\u{6f}\u{72}\u{20}\u{69}\u{74}\u{65}\u{72}\u{61}\u{74}\u{6f}\u{72}")
850+assert(debug.getinfo(0x1).name == "\u{66}\u{6f}\u{72}\u{20}\u{69}\u{74}\u{65}\u{72}\u{61}\u{74}\u{6f}\u{72}")
851end
851end
852for i in f
852for i in f
853do
853do
@@ -857,7 +857,7 @@ end
857do
857do
858local name = nil
858local name = nil
859setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
859setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
860−local t = debug.getinfo(1)
860+local t = debug.getinfo(0x1)
861assert(t.namewhat == "\u{6d}\u{65}\u{74}\u{61}\u{6d}\u{65}\u{74}\u{68}\u{6f}\u{64}")
861assert(t.namewhat == "\u{6d}\u{65}\u{74}\u{61}\u{6d}\u{65}\u{74}\u{68}\u{6f}\u{64}")
862name=t.name
862name=t.name
863end})
863end})
@@ -870,14 +870,14 @@ do
870print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{73}")
870print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{73}")
871local function countlines
871local function countlines
872(s)
872(s)
873−return select(2,string.gsub(s,"\u{a}",""))
873+return select(0x2,string.gsub(s,"\u{a}",""))
874end
874end
875local function deep
875local function deep
876(lvl,n)
876(lvl,n)
877−if lvl == 0 then
877+if lvl == 0x0 then
878return (debug.traceback("\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}",n))
878return (debug.traceback("\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}",n))
879else
879else
880−return (deep(lvl - 1,n))
880+return (deep(lvl - 0x1,n))
881end
881end
882end
882end
883local function checkdeep
883local function checkdeep
@@ -885,19 +885,19 @@ local function checkdeep
885local s = deep(total,start)
885local s = deep(total,start)
886local rest = string.match(s,"\u{5e}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{a}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{3a}\u{a}\u{28}\u{2e}\u{2a}\u{29}\u{24}")
886local rest = string.match(s,"\u{5e}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{a}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{3a}\u{a}\u{28}\u{2e}\u{2a}\u{29}\u{24}")
887local cl = countlines(rest)
887local cl = countlines(rest)
888−assert(cl <= 10 + 11 + 1)
888+assert(cl <= 0xa + 0xb + 0x1)
889local brk = string.find(rest,"\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{9}\u{25}\u{28}\u{73}\u{6b}\u{69}\u{70}")
889local brk = string.find(rest,"\u{25}\u{2e}\u{25}\u{2e}\u{25}\u{2e}\u{9}\u{25}\u{28}\u{73}\u{6b}\u{69}\u{70}")
890if brk then
890if brk then
891−local rest1 = string.sub(rest,1,brk)
891+local rest1 = string.sub(rest,0x1,brk)
892local rest2 = string.sub(rest,brk,# rest)
892local rest2 = string.sub(rest,brk,# rest)
893−assert(countlines(rest1) == 10 and countlines(rest2) == 11)
893+assert(countlines(rest1) == 0xa and countlines(rest2) == 0xb)
894else
894else
895−assert(cl == total - start + 2)
895+assert(cl == total - start + 0x2)
896end
896end
897end
897end
898−for d = 1, 51, 10
898+for d = 0x1, 0x33, 0xa
899do
899do
900−for l = 1, d
900+for l = 0x1, d
901do
901do
902coroutine.wrap(checkdeep)(d,l)
902coroutine.wrap(checkdeep)(d,l)
903end
903end
@@ -906,12 +906,12 @@ end
906print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{6f}\u{6e}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}")
906print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{6f}\u{6e}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}")
907local prog = "\u{2d}\u{2d}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{65}\u{64}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{73}\u{74}\u{72}\u{69}\u{70}\u{29}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{27}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{32}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{61}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{6e}\u{2c}\u{20}\u{76}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{28}\u{31}\u{2c}\u{20}\u{31}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{76}\u{20}\u{3d}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{29}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{75}\u{6e}\u{6b}\u{6f}\u{77}\u{6e}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{62}\u{75}\u{74}\u{20}\u{6b}\u{6e}\u{6f}\u{77}\u{6e}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{6e}\u{2c}\u{20}\u{76}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{28}\u{31}\u{2c}\u{20}\u{32}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{76}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{32}\u{29}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{75}\u{6e}\u{6b}\u{6f}\u{77}\u{6e}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{62}\u{75}\u{74}\u{20}\u{6b}\u{6e}\u{6f}\u{77}\u{6e}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{a}\u{2d}\u{2d}\u{20}\u{61}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{61}\u{6e}\u{20}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{6e}\u{2c}\u{20}\u{76}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{28}\u{66}\u{2c}\u{20}\u{31}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{6e}\u{6f}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{29}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{76}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{32}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{73}\u{65}\u{74}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{28}\u{66}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{31}\u{33}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{6e}\u{6f}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{29}\u{22}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{33}\u{29}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{74}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{66}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{2e}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3e}\u{20}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{6c}\u{61}\u{73}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3d}\u{3d}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{5f}\u{73}\u{72}\u{63}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{3f}\u{22}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{31}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{31}\u{29}\u{a}\u{a}\u{74}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{66}\u{2c}\u{20}\u{22}\u{4c}\u{22}\u{29}\u{2e}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{6c}\u{69}\u{6e}\u{65}\u{73}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{65}\u{78}\u{74}\u{28}\u{74}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{29}\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{61}\u{72}\u{65}\u{20}\u{65}\u{6d}\u{70}\u{74}\u{79}\u{a}\u{a}\u{2d}\u{2d}\u{20}\u{64}\u{75}\u{6d}\u{70}\u{2f}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}\u{a}\u{66}\u{20}\u{3d}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{64}\u{75}\u{6d}\u{70}\u{28}\u{66}\u{29}\u{29}\u{a}\u{a}\u{74}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{66}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{2e}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3e}\u{20}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{6c}\u{61}\u{73}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3d}\u{3d}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{5f}\u{73}\u{72}\u{63}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{3f}\u{22}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{31}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{31}\u{29}\u{a}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{a}"
907local prog = "\u{2d}\u{2d}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{20}\u{74}\u{6f}\u{20}\u{62}\u{65}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{65}\u{64}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{73}\u{74}\u{72}\u{69}\u{70}\u{29}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{27}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{32}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{61}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{6e}\u{2c}\u{20}\u{76}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{28}\u{31}\u{2c}\u{20}\u{31}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{76}\u{20}\u{3d}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{29}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{75}\u{6e}\u{6b}\u{6f}\u{77}\u{6e}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{62}\u{75}\u{74}\u{20}\u{6b}\u{6e}\u{6f}\u{77}\u{6e}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{6e}\u{2c}\u{20}\u{76}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{28}\u{31}\u{2c}\u{20}\u{32}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{76}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{32}\u{29}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{75}\u{6e}\u{6b}\u{6f}\u{77}\u{6e}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{62}\u{75}\u{74}\u{20}\u{6b}\u{6e}\u{6f}\u{77}\u{6e}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{a}\u{2d}\u{2d}\u{20}\u{61}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{61}\u{6e}\u{20}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{6e}\u{2c}\u{20}\u{76}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{28}\u{66}\u{2c}\u{20}\u{31}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{6e}\u{6f}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{29}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{76}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{32}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{73}\u{65}\u{74}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{28}\u{66}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{31}\u{33}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{28}\u{6e}\u{6f}\u{20}\u{6e}\u{61}\u{6d}\u{65}\u{29}\u{22}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{33}\u{29}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{74}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{66}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{2e}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3e}\u{20}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{6c}\u{61}\u{73}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3d}\u{3d}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{5f}\u{73}\u{72}\u{63}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{3f}\u{22}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{31}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{31}\u{29}\u{a}\u{a}\u{74}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{66}\u{2c}\u{20}\u{22}\u{4c}\u{22}\u{29}\u{2e}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{6c}\u{69}\u{6e}\u{65}\u{73}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{65}\u{78}\u{74}\u{28}\u{74}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{29}\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{61}\u{72}\u{65}\u{20}\u{65}\u{6d}\u{70}\u{74}\u{79}\u{a}\u{a}\u{2d}\u{2d}\u{20}\u{64}\u{75}\u{6d}\u{70}\u{2f}\u{6c}\u{6f}\u{61}\u{64}\u{20}\u{61}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{69}\u{6e}\u{66}\u{6f}\u{a}\u{66}\u{20}\u{3d}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{64}\u{75}\u{6d}\u{70}\u{28}\u{66}\u{29}\u{29}\u{a}\u{a}\u{74}\u{20}\u{3d}\u{20}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{66}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{2e}\u{6e}\u{61}\u{6d}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3e}\u{20}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{6c}\u{61}\u{73}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{3d}\u{3d}\u{20}\u{74}\u{2e}\u{6c}\u{69}\u{6e}\u{65}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}\u{20}\u{61}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{2e}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{5f}\u{73}\u{72}\u{63}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{3f}\u{22}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{31}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{31}\u{29}\u{a}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{a}"
908local f = assert(load(string.dump(load(prog),true)))
908local f = assert(load(string.dump(load(prog),true)))
909−assert(f() == 13)
909+assert(f() == 0xd)
910do
910do
911local function foo
911local function foo
912()
912()
913−local a = 1
913+local a = 0x1
914−local b = 2
914+local b = 0x2
915return b
915return b
916end
916end
917local s = load(string.dump(foo,true))
917local s = load(string.dump(foo,true))
@@ -920,28 +920,28 @@ debug.sethook(function (e,l)
920assert(e == "\u{6c}\u{69}\u{6e}\u{65}")
920assert(e == "\u{6c}\u{69}\u{6e}\u{65}")
921line=l
921line=l
922end,"\u{6c}")
922end,"\u{6c}")
923−assert(s() == 2)
923+assert(s() == 0x2)
924;
924;
925debug.sethook(nil)
925debug.sethook(nil)
926assert(line == nil)
926assert(line == nil)
927end
927end
928do
928do
929local prog = "\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{78}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{79}\u{29}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{20}\u{2b}\u{20}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}"
929local prog = "\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{78}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{79}\u{29}\u{20}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{20}\u{2b}\u{20}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}"
930−local name = string.rep("\u{78}",1000)
930+local name = string.rep("\u{78}",0x3e8)
931local p = assert(load(prog,name))
931local p = assert(load(prog,name))
932local c = string.dump(p)
932local c = string.dump(p)
933−assert(# c > 1000 and # c < 2000)
933+assert(# c > 0x3e8 and # c < 0x7d0)
934local f = assert(load(c))
934local f = assert(load(c))
935local g = f()
935local g = f()
936−local h = g(3)
936+local h = g(0x3)
937−assert(h(5) == 8)
937+assert(h(0x5) == 0x8)
938assert(debug.getinfo(f).source == name and debug.getinfo(g).source == name and debug.getinfo(h).source == name)
938assert(debug.getinfo(f).source == name and debug.getinfo(g).source == name and debug.getinfo(h).source == name)
939local c = string.dump(p,true)
939local c = string.dump(p,true)
940−assert(# c < 500)
940+assert(# c < 0x1f4)
941local f = assert(load(c))
941local f = assert(load(c))
942local g = f()
942local g = f()
943−local h = g(30)
943+local h = g(0x1e)
944−assert(h(50) == 80)
944+assert(h(0x32) == 0x50)
945assert(debug.getinfo(f).source == "\u{3d}\u{3f}" and debug.getinfo(g).source == "\u{3d}\u{3f}" and debug.getinfo(h).source == "\u{3d}\u{3f}")
945assert(debug.getinfo(f).source == "\u{3d}\u{3f}" and debug.getinfo(g).source == "\u{3d}\u{3f}" and debug.getinfo(h).source == "\u{3d}\u{3f}")
946end
946end
947print("\u{4f}\u{4b}")
947print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/errors.lua+88−88
@@ -23,7 +23,7 @@ local m = doit(prog)
23if debug then
23if debug then
24print(m,msg)
24print(m,msg)
25end
25end
26−assert(string.find(m,msg,1,true))
26+assert(string.find(m,msg,0x1,true))
27end
27end
28local function checksyntax
28local function checksyntax
29(prog,extra,token,line)
29(prog,extra,token,line)
@@ -34,7 +34,7 @@ end
34token=string.gsub(token,"\u{28}\u{25}\u{70}\u{29}","\u{25}\u{25}\u{25}\u{31}")
34token=string.gsub(token,"\u{28}\u{25}\u{70}\u{29}","\u{25}\u{25}\u{25}\u{31}")
35local pt = string.format("\u{5e}\u{25}\u{25}\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{2e}\u{2a}\u{22}\u{25}\u{25}\u{5d}\u{3a}\u{25}\u{64}\u{3a}\u{20}\u{2e}\u{2d}\u{20}\u{6e}\u{65}\u{61}\u{72}\u{20}\u{25}\u{73}\u{24}",line,token)
35local pt = string.format("\u{5e}\u{25}\u{25}\u{5b}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{22}\u{2e}\u{2a}\u{22}\u{25}\u{25}\u{5d}\u{3a}\u{25}\u{64}\u{3a}\u{20}\u{2e}\u{2d}\u{20}\u{6e}\u{65}\u{61}\u{72}\u{20}\u{25}\u{73}\u{24}",line,token)
36assert(string.find(msg,pt))
36assert(string.find(msg,pt))
37−assert(string.find(msg,msg,1,true))
37+assert(string.find(msg,msg,0x1,true))
38end
38end
39assert(doit("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{27}\u{68}\u{69}\u{27}\u{2c}\u{20}\u{30}\u{29}") == "\u{68}\u{69}")
39assert(doit("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{27}\u{68}\u{69}\u{27}\u{2c}\u{20}\u{30}\u{29}") == "\u{68}\u{69}")
40assert(doit("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{29}") == nil)
40assert(doit("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{29}") == nil)
@@ -49,35 +49,35 @@ assert(doit("\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6e}\u{69}\u{6c}\u{29}"
49assert(doit("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{20}\u{28}\u{2e}\u{2e}\u{2e}\u{20}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{65}\u{6e}\u{64}"))
49assert(doit("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{20}\u{28}\u{2e}\u{2e}\u{2e}\u{20}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{65}\u{6e}\u{64}"))
50assert(doit("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{20}\u{28}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{65}\u{6e}\u{64}"))
50assert(doit("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{20}\u{28}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{65}\u{6e}\u{64}"))
51assert(doit("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{74}\u{3d}\u{7b}\u{7d}\u{3b}\u{20}\u{74}\u{20}\u{3d}\u{20}\u{74}\u{5b}\u{23}\u{74}\u{5d}\u{20}\u{2b}\u{20}\u{31}"))
51assert(doit("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{74}\u{3d}\u{7b}\u{7d}\u{3b}\u{20}\u{74}\u{20}\u{3d}\u{20}\u{74}\u{5b}\u{23}\u{74}\u{5d}\u{20}\u{2b}\u{20}\u{31}"))
52−checksyntax("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{34}\u{a}\u{a}","\u{27}\u{7d}\u{27}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{28}\u{74}\u{6f}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{27}\u{7b}\u{27}\u{20}\u{61}\u{74}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{31}\u{29}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}",3)
52+checksyntax("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{34}\u{a}\u{a}","\u{27}\u{7d}\u{27}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{28}\u{74}\u{6f}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{27}\u{7b}\u{27}\u{20}\u{61}\u{74}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{31}\u{29}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}",0x3)
53do
53do
54local function checksyntax
54local function checksyntax
55(prog,msg,line)
55(prog,msg,line)
56local st,err = load(prog)
56local st,err = load(prog)
57assert(string.find(err,"\u{6c}\u{69}\u{6e}\u{65}\u{20}" .. line))
57assert(string.find(err,"\u{6c}\u{69}\u{6e}\u{65}\u{20}" .. line))
58−assert(string.find(err,msg,1,true))
58+assert(string.find(err,msg,0x1,true))
59end
59end
60−checksyntax("\u{20}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{41}\u{3a}\u{3a}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{41}\u{3a}\u{3a}\u{a}\u{20}\u{20}","\u{6c}\u{61}\u{62}\u{65}\u{6c}\u{20}\u{27}\u{41}\u{27}\u{20}\u{61}\u{6c}\u{72}\u{65}\u{61}\u{64}\u{79}\u{20}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}",1)
60+checksyntax("\u{20}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{41}\u{3a}\u{3a}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{41}\u{3a}\u{3a}\u{a}\u{20}\u{20}","\u{6c}\u{61}\u{62}\u{65}\u{6c}\u{20}\u{27}\u{41}\u{27}\u{20}\u{61}\u{6c}\u{72}\u{65}\u{61}\u{64}\u{79}\u{20}\u{64}\u{65}\u{66}\u{69}\u{6e}\u{65}\u{64}",0x1)
61−checksyntax("\u{20}\u{20}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{41}\u{a}\u{20}\u{20}\u{20}\u{20}\u{64}\u{6f}\u{20}\u{3a}\u{3a}\u{41}\u{3a}\u{3a}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}","\u{6e}\u{6f}\u{20}\u{76}\u{69}\u{73}\u{69}\u{62}\u{6c}\u{65}\u{20}\u{6c}\u{61}\u{62}\u{65}\u{6c}\u{20}\u{27}\u{41}\u{27}",2)
61+checksyntax("\u{20}\u{20}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{41}\u{a}\u{20}\u{20}\u{20}\u{20}\u{64}\u{6f}\u{20}\u{3a}\u{3a}\u{41}\u{3a}\u{3a}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}","\u{6e}\u{6f}\u{20}\u{76}\u{69}\u{73}\u{69}\u{62}\u{6c}\u{65}\u{20}\u{6c}\u{61}\u{62}\u{65}\u{6c}\u{20}\u{27}\u{41}\u{27}",0x2)
62end
62end
63if not T then
63if not T then
64(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{43}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
64(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{43}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
65else
65else
66print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}")
66print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}")
67local a = {}
67local a = {}
68−for i = 1, 10000
68+for i = 0x1, 0x2710
69do
69do
70a[i]=true
70a[i]=true
71end
71end
72collectgarbage()
72collectgarbage()
73−T.totalmem(T.totalmem() + 10000)
73+T.totalmem(T.totalmem() + 0x2710)
74local st,msg = pcall(function ()
74local st,msg = pcall(function ()
75−for i = 1, 100000
75+for i = 0x1, 0x186a0
76do
76do
77a[i]=tostring(i)
77a[i]=tostring(i)
78end
78end
79end)
79end)
80−T.totalmem(0)
80+T.totalmem(0x0)
81assert(not st and msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}" .. "\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
81assert(not st and msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}" .. "\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
82local res = T.testC("\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{31}\u{36}\u{20}\u{65}\u{6c}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{20}\u{6f}\u{6e}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{6b}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{34}\u{20}\u{72}\u{65}\u{6d}\u{61}\u{69}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{6c}\u{6f}\u{74}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{78}\u{75}\u{78}\u{75}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}\u{20}\u{20}")
82local res = T.testC("\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{70}\u{75}\u{73}\u{68}\u{20}\u{31}\u{36}\u{20}\u{65}\u{6c}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{20}\u{6f}\u{6e}\u{20}\u{74}\u{68}\u{65}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{6b}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{34}\u{20}\u{72}\u{65}\u{6d}\u{61}\u{69}\u{6e}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{6c}\u{6f}\u{74}\u{73}\u{a}\u{20}\u{20}\u{20}\u{20}\u{74}\u{72}\u{61}\u{63}\u{65}\u{62}\u{61}\u{63}\u{6b}\u{20}\u{78}\u{75}\u{78}\u{75}\u{20}\u{31}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}\u{20}\u{20}")
83assert(string.find(res,"\u{78}\u{75}\u{78}\u{75}\u{2e}\u{2d}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}"))
83assert(string.find(res,"\u{78}\u{75}\u{78}\u{75}\u{2e}\u{2d}\u{6d}\u{61}\u{69}\u{6e}\u{20}\u{63}\u{68}\u{75}\u{6e}\u{6b}"))
@@ -168,36 +168,36 @@ if T then
168local x = setmetatable({},{["\u{5f}\u{5f}\u{6e}\u{61}\u{6d}\u{65}"] = "\u{54}\u{41}\u{42}\u{4c}\u{45}"})
168local x = setmetatable({},{["\u{5f}\u{5f}\u{6e}\u{61}\u{6d}\u{65}"] = "\u{54}\u{41}\u{42}\u{4c}\u{45}"})
169assert(T.testC("\u{4c}\u{74}\u{6f}\u{6c}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",x) == tostring(x))
169assert(T.testC("\u{4c}\u{74}\u{6f}\u{6c}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}",x) == tostring(x))
170local a,b = T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{4c}\u{74}\u{6f}\u{6c}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",x)
170local a,b = T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{4c}\u{74}\u{6f}\u{6c}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}",x)
171−assert(a == 10 and b == tostring(x))
171+assert(a == 0xa and b == tostring(x))
172setmetatable(x,{["\u{5f}\u{5f}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}"] = function (o)
172setmetatable(x,{["\u{5f}\u{5f}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}"] = function (o)
173assert(o == x)
173assert(o == x)
174return "\u{41}\u{42}\u{43}"
174return "\u{41}\u{42}\u{43}"
175end})
175end})
176local a,b,c = T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{4c}\u{74}\u{6f}\u{6c}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
176local a,b,c = T.testC("\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{31}\u{30}\u{3b}\u{20}\u{4c}\u{74}\u{6f}\u{6c}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{32}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{33}",x)
177−assert(a == x and b == 10 and c == "\u{41}\u{42}\u{43}")
177+assert(a == x and b == 0xa and c == "\u{41}\u{42}\u{43}")
178end
178end
179end
179end
180checkmessage("\u{28}\u{69}\u{6f}\u{2e}\u{77}\u{72}\u{69}\u{74}\u{65}\u{20}\u{6f}\u{72}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{29}\u{7b}\u{7d}","\u{69}\u{6f}\u{2e}\u{77}\u{72}\u{69}\u{74}\u{65}")
180checkmessage("\u{28}\u{69}\u{6f}\u{2e}\u{77}\u{72}\u{69}\u{74}\u{65}\u{20}\u{6f}\u{72}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{29}\u{7b}\u{7d}","\u{69}\u{6f}\u{2e}\u{77}\u{72}\u{69}\u{74}\u{65}")
181checkmessage("\u{28}\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{67}\u{61}\u{72}\u{62}\u{61}\u{67}\u{65}\u{20}\u{6f}\u{72}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{29}\u{7b}\u{7d}","\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{67}\u{61}\u{72}\u{62}\u{61}\u{67}\u{65}")
181checkmessage("\u{28}\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{67}\u{61}\u{72}\u{62}\u{61}\u{67}\u{65}\u{20}\u{6f}\u{72}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{29}\u{7b}\u{7d}","\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{67}\u{61}\u{72}\u{62}\u{61}\u{67}\u{65}")
182do
182do
183local f = function (a)
183local f = function (a)
184−return a + 1
184+return a + 0x1
185end
185end
186f=assert(load(string.dump(f,true)))
186f=assert(load(string.dump(f,true)))
187−assert(f(3) == 4)
187+assert(f(0x3) == 0x4)
188checkerr("\u{5e}\u{25}\u{3f}\u{3a}\u{25}\u{2d}\u{31}\u{3a}",f,{})
188checkerr("\u{5e}\u{25}\u{3f}\u{3a}\u{25}\u{2d}\u{31}\u{3a}",f,{})
189f=function ()
189f=function ()
190local a
190local a
191;
191;
192a={}
192a={}
193;
193;
194−return a + 2
194+return a + 0x2
195end
195end
196f=assert(load(string.dump(f,true)))
196f=assert(load(string.dump(f,true)))
197checkerr("\u{5e}\u{25}\u{3f}\u{3a}\u{25}\u{2d}\u{31}\u{3a}\u{2e}\u{2a}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}",f)
197checkerr("\u{5e}\u{25}\u{3f}\u{3a}\u{25}\u{2d}\u{31}\u{3a}\u{2e}\u{2a}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}",f)
198end
198end
199local t = {}
199local t = {}
200−for i = 1, 1000
200+for i = 0x1, 0x3e8
201do
201do
202t[i]="\u{61}\u{61}\u{61}\u{20}\u{3d}\u{20}\u{78}" .. i
202t[i]="\u{61}\u{61}\u{61}\u{20}\u{3d}\u{20}\u{78}" .. i
203end
203end
@@ -236,20 +236,20 @@ end
236assert(string.find(f(),"\u{43}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
236assert(string.find(f(),"\u{43}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
237checkmessage("\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{29}","\u{6f}\u{75}\u{74}\u{73}\u{69}\u{64}\u{65}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}")
237checkmessage("\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{29}","\u{6f}\u{75}\u{74}\u{73}\u{69}\u{64}\u{65}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}")
238f=coroutine.wrap(function ()
238f=coroutine.wrap(function ()
239−table.sort({1,2,3},coroutine.yield)
239+table.sort({0x1,0x2,0x3},coroutine.yield)
240end)
240end)
241checkerr("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{61}\u{63}\u{72}\u{6f}\u{73}\u{73}",f)
241checkerr("\u{79}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{61}\u{63}\u{72}\u{6f}\u{73}\u{73}",f)
242−local idsize = 60 - 1
242+local idsize = 0x3c - 0x1
243local function checksize
243local function checksize
244(source)
244(source)
245local _,msg = load("\u{78}",source)
245local _,msg = load("\u{78}",source)
246msg=string.match(msg,"\u{5e}\u{28}\u{5b}\u{5e}\u{3a}\u{5d}\u{2a}\u{29}\u{3a}")
246msg=string.match(msg,"\u{5e}\u{28}\u{5b}\u{5e}\u{3a}\u{5d}\u{2a}\u{29}\u{3a}")
247assert(msg:len() <= idsize)
247assert(msg:len() <= idsize)
248end
248end
249−for i = 60 - 10, 60 + 10
249+for i = 0x3c - 0xa, 0x3c + 0xa
250do
250do
251checksize("\u{40}" .. string.rep("\u{78}",i))
251checksize("\u{40}" .. string.rep("\u{78}",i))
252−checksize(string.rep("\u{78}",i - 10))
252+checksize(string.rep("\u{78}",i - 0xa))
253checksize("\u{3d}" .. string.rep("\u{78}",i))
253checksize("\u{3d}" .. string.rep("\u{78}",i))
254end
254end
255local function lineerror
255local function lineerror
@@ -258,46 +258,46 @@ local err,msg = pcall(load(s))
258local line = tonumber(string.match(msg,"\u{3a}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{3a}"))
258local line = tonumber(string.match(msg,"\u{3a}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{3a}"))
259assert(line == l or (not line and not l))
259assert(line == l or (not line and not l))
260end
260end
261−lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{a}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{27}\u{61}\u{27}\u{20}\u{64}\u{6f}\u{20}\u{a}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{69}\u{29}\u{20}\u{a}\u{20}\u{65}\u{6e}\u{64}",2)
261+lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{a}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{27}\u{61}\u{27}\u{20}\u{64}\u{6f}\u{20}\u{a}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{69}\u{29}\u{20}\u{a}\u{20}\u{65}\u{6e}\u{64}",0x2)
262−lineerror("\u{a}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{a}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{6b}\u{2c}\u{76}\u{20}\u{69}\u{6e}\u{20}\u{33}\u{20}\u{a}\u{20}\u{64}\u{6f}\u{20}\u{a}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{6b}\u{29}\u{20}\u{a}\u{20}\u{65}\u{6e}\u{64}",3)
262+lineerror("\u{a}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{a}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{6b}\u{2c}\u{76}\u{20}\u{69}\u{6e}\u{20}\u{33}\u{20}\u{a}\u{20}\u{64}\u{6f}\u{20}\u{a}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{6b}\u{29}\u{20}\u{a}\u{20}\u{65}\u{6e}\u{64}",0x3)
263−lineerror("\u{a}\u{a}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{6b}\u{2c}\u{76}\u{20}\u{69}\u{6e}\u{20}\u{a}\u{20}\u{33}\u{20}\u{a}\u{20}\u{64}\u{6f}\u{20}\u{a}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{6b}\u{29}\u{20}\u{a}\u{20}\u{65}\u{6e}\u{64}",4)
263+lineerror("\u{a}\u{a}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{6b}\u{2c}\u{76}\u{20}\u{69}\u{6e}\u{20}\u{a}\u{20}\u{33}\u{20}\u{a}\u{20}\u{64}\u{6f}\u{20}\u{a}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{6b}\u{29}\u{20}\u{a}\u{20}\u{65}\u{6e}\u{64}",0x4)
264−lineerror("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{2e}\u{78}\u{2e}\u{79}\u{20}\u{28}\u{29}\u{a}\u{61}\u{3d}\u{61}\u{2b}\u{31}\u{a}\u{65}\u{6e}\u{64}",1)
264+lineerror("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{2e}\u{78}\u{2e}\u{79}\u{20}\u{28}\u{29}\u{a}\u{61}\u{3d}\u{61}\u{2b}\u{31}\u{a}\u{65}\u{6e}\u{64}",0x1)
265−lineerror("\u{61}\u{20}\u{3d}\u{20}\u{a}\u{61}\u{a}\u{2b}\u{a}\u{7b}\u{7d}",3)
265+lineerror("\u{61}\u{20}\u{3d}\u{20}\u{a}\u{61}\u{a}\u{2b}\u{a}\u{7b}\u{7d}",0x3)
266−lineerror("\u{61}\u{20}\u{3d}\u{20}\u{a}\u{33}\u{a}\u{2b}\u{a}\u{28}\u{a}\u{34}\u{a}\u{2f}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{29}",6)
266+lineerror("\u{61}\u{20}\u{3d}\u{20}\u{a}\u{33}\u{a}\u{2b}\u{a}\u{28}\u{a}\u{34}\u{a}\u{2f}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{29}",0x6)
267−lineerror("\u{61}\u{20}\u{3d}\u{20}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{a}\u{2b}\u{a}\u{28}\u{a}\u{34}\u{a}\u{2f}\u{a}\u{37}\u{29}",3)
267+lineerror("\u{61}\u{20}\u{3d}\u{20}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{a}\u{2b}\u{a}\u{28}\u{a}\u{34}\u{a}\u{2f}\u{a}\u{37}\u{29}",0x3)
268−lineerror("\u{61}\u{a}\u{3d}\u{a}\u{2d}\u{a}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{a}\u{3b}",3)
268+lineerror("\u{61}\u{a}\u{3d}\u{a}\u{2d}\u{a}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{a}\u{3b}",0x3)
269−lineerror("\u{61}\u{a}\u{28}\u{20}\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{3c}\u{3c}\u{a}\u{32}\u{33}\u{29}\u{a}",2)
269+lineerror("\u{61}\u{a}\u{28}\u{20}\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{3c}\u{3c}\u{a}\u{32}\u{33}\u{29}\u{a}",0x2)
270−lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{33}\u{7d}\u{a}\u{61}\u{a}\u{2e}\u{a}\u{78}\u{a}\u{28}\u{20}\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{3c}\u{3c}\u{a}\u{32}\u{33}\u{a}\u{29}\u{a}",5)
270+lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{33}\u{7d}\u{a}\u{61}\u{a}\u{2e}\u{a}\u{78}\u{a}\u{28}\u{20}\u{20}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{3c}\u{3c}\u{a}\u{32}\u{33}\u{a}\u{29}\u{a}",0x5)
271−lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{33}\u{7d}\u{a}\u{61}\u{a}\u{2e}\u{a}\u{78}\u{a}\u{28}\u{a}\u{32}\u{33}\u{20}\u{2b}\u{20}\u{61}\u{a}\u{29}\u{a}",6)
271+lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{33}\u{7d}\u{a}\u{61}\u{a}\u{2e}\u{a}\u{78}\u{a}\u{28}\u{a}\u{32}\u{33}\u{20}\u{2b}\u{20}\u{61}\u{a}\u{29}\u{a}",0x6)
272local p = "\u{20}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{67}\u{28}\u{29}\u{20}\u{66}\u{28}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{28}\u{78}\u{29}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{27}\u{61}\u{27}\u{2c}\u{20}\u{58}\u{58}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{67}\u{28}\u{29}\u{a}"
272local p = "\u{20}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{67}\u{28}\u{29}\u{20}\u{66}\u{28}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{28}\u{78}\u{29}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{27}\u{61}\u{27}\u{2c}\u{20}\u{58}\u{58}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{67}\u{28}\u{29}\u{a}"
273−XX=3
273+XX=0x3
274;
274;
275−lineerror((p),3)
275+lineerror((p),0x3)
276−XX=0
276+XX=0x0
277;
277;
278lineerror((p),false)
278lineerror((p),false)
279−XX=1
279+XX=0x1
280;
280;
281−lineerror((p),2)
281+lineerror((p),0x2)
282−XX=2
282+XX=0x2
283;
283;
284−lineerror((p),1)
284+lineerror((p),0x1)
285_G.XX,_G.g,_G.f=nil
285_G.XX,_G.g,_G.f=nil
286−lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{66}\u{61}\u{6c}\u{73}\u{65}\u{a}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{27}\u{74}\u{65}\u{73}\u{74}\u{27}\u{a}\u{65}\u{6e}\u{64}",3)
286+lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{66}\u{61}\u{6c}\u{73}\u{65}\u{a}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{27}\u{74}\u{65}\u{73}\u{74}\u{27}\u{a}\u{65}\u{6e}\u{64}",0x3)
287−lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{66}\u{61}\u{6c}\u{73}\u{65}\u{a}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{27}\u{74}\u{65}\u{73}\u{74}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{65}\u{6e}\u{64}",5)
287+lineerror("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{66}\u{61}\u{6c}\u{73}\u{65}\u{a}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{27}\u{74}\u{65}\u{73}\u{74}\u{27}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{65}\u{6e}\u{64}",0x5)
288−lineerror("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{30}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{63}\u{20}\u{3d}\u{20}\u{62}\u{20}\u{25}\u{20}\u{61}\u{a}",3)
288+lineerror("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{30}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{63}\u{20}\u{3d}\u{20}\u{62}\u{20}\u{25}\u{20}\u{61}\u{a}",0x3)
289do
289do
290−local s = string.format("\u{25}\u{73}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{5f}\u{41}\u{2e}\u{78}",string.rep("\u{a}",300))
290+local s = string.format("\u{25}\u{73}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{5f}\u{41}\u{2e}\u{78}",string.rep("\u{a}",0x12c))
291−lineerror(s,301)
291+lineerror(s,0x12d)
292end
292end
293if not _soft then
293if not _soft then
294collectgarbage()
294collectgarbage()
295print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}")
295print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}")
296−local C = 0
296+local C = 0x0
297−local l = debug.getinfo(1,"\u{6c}").currentline + 1
297+local l = debug.getinfo(0x1,"\u{6c}").currentline + 0x1
298local function auxy
298local function auxy
299()
299()
300−C=C + 1
300+C=C + 0x1
301;
301;
302auxy()
302auxy()
303end
303end
@@ -309,7 +309,7 @@ end
309local function checkstackmessage
309local function checkstackmessage
310(m)
310(m)
311print("\u{28}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}" .. C .. "\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}\u{29}")
311print("\u{28}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{61}\u{66}\u{74}\u{65}\u{72}\u{20}" .. C .. "\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}\u{29}")
312−C=0
312+C=0x0
313return (string.find(m,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
313return (string.find(m,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
314end
314end
315assert(checkstackmessage(doit("\u{59}\u{59}\u{28}\u{29}")))
315assert(checkstackmessage(doit("\u{59}\u{59}\u{28}\u{29}")))
@@ -319,12 +319,12 @@ _G.YY=nil
319local l1
319local l1
320local function g
320local function g
321(x)
321(x)
322−l1=debug.getinfo(x,"\u{6c}").currentline + 2
322+l1=debug.getinfo(x,"\u{6c}").currentline + 0x2
323collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
323collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
324auxy()
324auxy()
325collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
325collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
326end
326end
327−local _,stackmsg = xpcall(g,debug.traceback,1)
327+local _,stackmsg = xpcall(g,debug.traceback,0x1)
328print("\u{2b}")
328print("\u{2b}")
329local stack = {}
329local stack = {}
330for line in string.gmatch(stackmsg,"\u{5b}\u{5e}\u{a}\u{5d}\u{2a}")
330for line in string.gmatch(stackmsg,"\u{5b}\u{5e}\u{a}\u{5d}\u{2a}")
@@ -334,43 +334,43 @@ if curr then
334table.insert(stack,tonumber(curr))
334table.insert(stack,tonumber(curr))
335end
335end
336end
336end
337−local i = 1
337+local i = 0x1
338while stack[i] ~= l1 do
338while stack[i] ~= l1 do
339assert(stack[i] == l)
339assert(stack[i] == l)
340−i=i + 1
340+i=i + 0x1
341end
341end
342−assert(i > 15)
342+assert(i > 0xf)
343local res,msg = xpcall(error,error)
343local res,msg = xpcall(error,error)
344assert(not res and type(msg) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
344assert(not res and type(msg) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
345print("\u{2b}")
345print("\u{2b}")
346local function f
346local function f
347(x)
347(x)
348−if x == 0 then
348+if x == 0x0 then
349error("\u{61}\u{a}")
349error("\u{61}\u{a}")
350else
350else
351local aux = function ()
351local aux = function ()
352−return f(x - 1)
352+return f(x - 0x1)
353end
353end
354local a,b = xpcall(aux,aux)
354local a,b = xpcall(aux,aux)
355return a,b
355return a,b
356end
356end
357end
357end
358−f(3)
358+f(0x3)
359local function loop
359local function loop
360(x,y,z)
360(x,y,z)
361−return 1 + loop(x,y,z)
361+return 0x1 + loop(x,y,z)
362end
362end
363local res,msg = xpcall(loop,function (m)
363local res,msg = xpcall(loop,function (m)
364assert(string.find(m,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
364assert(string.find(m,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
365checkerr("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{68}\u{61}\u{6e}\u{64}\u{6c}\u{69}\u{6e}\u{67}",loop)
365checkerr("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{68}\u{61}\u{6e}\u{64}\u{6c}\u{69}\u{6e}\u{67}",loop)
366−assert(math.sin(0) == 0)
366+assert(math.sin(0x0) == 0x0)
367−return 15
367+return 0xf
368end)
368end)
369−assert(msg == 15)
369+assert(msg == 0xf)
370local f = function ()
370local f = function ()
371−for i = 999900, 1000000, 1
371+for i = 0xf41dc, 0xf4240, 0x1
372do
372do
373−table.unpack({},1,i)
373+table.unpack({},0x1,i)
374end
374end
375end
375end
376checkerr("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",f)
376checkerr("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",f)
@@ -399,7 +399,7 @@ res,msg=pcall(function ()
399assert(false)
399assert(false)
400end)
400end)
401local line = string.match(msg,"\u{25}\u{77}\u{2b}\u{25}\u{2e}\u{6c}\u{75}\u{61}\u{3a}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{3a}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{61}\u{69}\u{6c}\u{65}\u{64}\u{21}\u{24}")
401local line = string.match(msg,"\u{25}\u{77}\u{2b}\u{25}\u{2e}\u{6c}\u{75}\u{61}\u{3a}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{3a}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{61}\u{69}\u{6c}\u{65}\u{64}\u{21}\u{24}")
402−assert(tonumber(line) == debug.getinfo(1,"\u{6c}").currentline - 2)
402+assert(tonumber(line) == debug.getinfo(0x1,"\u{6c}").currentline - 0x2)
403res,msg=pcall(assert,false,t)
403res,msg=pcall(assert,false,t)
404assert(not res and msg == t)
404assert(not res and msg == t)
405res,msg=pcall(assert,nil,nil)
405res,msg=pcall(assert,nil,nil)
@@ -408,81 +408,81 @@ res,msg=pcall(assert)
408assert(not res and string.find(msg,"\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}"))
408assert(not res and string.find(msg,"\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}"))
409end
409end
410local a,b,c = xpcall(string.find,error,"\u{61}\u{6c}\u{6f}","\u{61}\u{6c}")
410local a,b,c = xpcall(string.find,error,"\u{61}\u{6c}\u{6f}","\u{61}\u{6c}")
411−assert(a and b == 1 and c == 2)
411+assert(a and b == 0x1 and c == 0x2)
412a,b,c=xpcall(string.find,function (x)
412a,b,c=xpcall(string.find,function (x)
413return {}
413return {}
414end,true,"\u{61}\u{6c}")
414end,true,"\u{61}\u{6c}")
415assert(not a and type(b) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and c == nil)
415assert(not a and type(b) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and c == nil)
416print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{6f}\u{6b}\u{65}\u{6e}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{73}")
416print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{6f}\u{6b}\u{65}\u{6e}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{73}")
417−checksyntax("\u{73}\u{79}\u{6e}\u{74}\u{61}\u{78}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}","","\u{65}\u{72}\u{72}\u{6f}\u{72}",1)
417+checksyntax("\u{73}\u{79}\u{6e}\u{74}\u{61}\u{78}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}","","\u{65}\u{72}\u{72}\u{6f}\u{72}",0x1)
418−checksyntax("\u{31}\u{2e}\u{30}\u{30}\u{30}","","\u{31}\u{2e}\u{30}\u{30}\u{30}",1)
418+checksyntax("\u{31}\u{2e}\u{30}\u{30}\u{30}","","\u{31}\u{2e}\u{30}\u{30}\u{30}",0x1)
419−checksyntax("\u{5b}\u{5b}\u{61}\u{5d}\u{5d}","","\u{5b}\u{5b}\u{61}\u{5d}\u{5d}",1)
419+checksyntax("\u{5b}\u{5b}\u{61}\u{5d}\u{5d}","","\u{5b}\u{5b}\u{61}\u{5d}\u{5d}",0x1)
420−checksyntax("\u{27}\u{61}\u{61}\u{27}","","\u{27}\u{61}\u{61}\u{27}",1)
420+checksyntax("\u{27}\u{61}\u{61}\u{27}","","\u{27}\u{61}\u{61}\u{27}",0x1)
421−checksyntax("\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{3c}\u{3c}\u{20}\u{64}\u{6f}\u{20}\u{65}\u{6e}\u{64}","","\u{3c}\u{3c}",1)
421+checksyntax("\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{3c}\u{3c}\u{20}\u{64}\u{6f}\u{20}\u{65}\u{6e}\u{64}","","\u{3c}\u{3c}",0x1)
422−checksyntax("\u{66}\u{6f}\u{72}\u{20}\u{3e}\u{3e}\u{20}\u{64}\u{6f}\u{20}\u{65}\u{6e}\u{64}","","\u{3e}\u{3e}",1)
422+checksyntax("\u{66}\u{6f}\u{72}\u{20}\u{3e}\u{3e}\u{20}\u{64}\u{6f}\u{20}\u{65}\u{6e}\u{64}","","\u{3e}\u{3e}",0x1)
423−checksyntax("\u{61}\u{1}\u{61}\u{20}\u{3d}\u{20}\u{31}","","\u{3c}\u{5c}\u{31}\u{3e}",1)
423+checksyntax("\u{61}\u{1}\u{61}\u{20}\u{3d}\u{20}\u{31}","","\u{3c}\u{5c}\u{31}\u{3e}",0x1)
424−checksyntax("\u{ff}\u{61}\u{20}\u{3d}\u{20}\u{31}","","\u{3c}\u{5c}\u{32}\u{35}\u{35}\u{3e}",1)
424+checksyntax("\u{ff}\u{61}\u{20}\u{3d}\u{20}\u{31}","","\u{3c}\u{5c}\u{32}\u{35}\u{35}\u{3e}",0x1)
425doit("\u{49}\u{20}\u{3d}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{28}\u{22}\u{61}\u{3d}\u{39}\u{2b}\u{22}\u{29}\u{3b}\u{20}\u{61}\u{61}\u{61}\u{3d}\u{33}")
425doit("\u{49}\u{20}\u{3d}\u{20}\u{6c}\u{6f}\u{61}\u{64}\u{28}\u{22}\u{61}\u{3d}\u{39}\u{2b}\u{22}\u{29}\u{3b}\u{20}\u{61}\u{61}\u{61}\u{3d}\u{33}")
426−assert(_G.aaa == 3 and not _G.I)
426+assert(_G.aaa == 0x3 and not _G.I)
427_G.I,_G.aaa=nil
427_G.I,_G.aaa=nil
428print("\u{2b}")
428print("\u{2b}")
429−local lim = 1000
429+local lim = 0x3e8
430if _soft then
430if _soft then
431−lim=100
431+lim=0x64
432end
432end
433−for i = 1, lim
433+for i = 0x1, lim
434do
434do
435doit("\u{61}\u{20}\u{3d}\u{20}")
435doit("\u{61}\u{20}\u{3d}\u{20}")
436doit("\u{61}\u{20}\u{3d}\u{20}\u{34}\u{2b}\u{6e}\u{69}\u{6c}")
436doit("\u{61}\u{20}\u{3d}\u{20}\u{34}\u{2b}\u{6e}\u{69}\u{6c}")
437end
437end
438local function testrep
438local function testrep
439(init,rep,close,repc,finalresult)
439(init,rep,close,repc,finalresult)
440−local s = init .. string.rep(rep,100) .. close .. string.rep(repc,100)
440+local s = init .. string.rep(rep,0x64) .. close .. string.rep(repc,0x64)
441local res,msg = load(s)
441local res,msg = load(s)
442assert(res)
442assert(res)
443if (finalresult) then
443if (finalresult) then
444assert(res() == finalresult)
444assert(res() == finalresult)
445end
445end
446−s=init .. string.rep(rep,500)
446+s=init .. string.rep(rep,0x1f4)
447local res,msg = load(s)
447local res,msg = load(s)
448assert(not res and (string.find(msg,"\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}") or string.find(msg,"\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}")))
448assert(not res and (string.find(msg,"\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}") or string.find(msg,"\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}")))
449end
449end
450testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3b}\u{20}\u{61}","\u{2c}\u{61}","\u{3d}\u{20}\u{31}","\u{2c}\u{31}")
450testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3b}\u{20}\u{61}","\u{2c}\u{61}","\u{3d}\u{20}\u{31}","\u{2c}\u{31}")
451testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3b}\u{20}\u{61}\u{3d}","\u{7b}","\u{30}","\u{7d}")
451testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3b}\u{20}\u{61}\u{3d}","\u{7b}","\u{30}","\u{7d}")
452−testrep("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{28}","\u{32}","\u{29}",2)
452+testrep("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{28}","\u{32}","\u{29}",0x2)
453testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{20}\u{28}\u{78}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{61}\u{28}","\u{32}\u{2e}\u{32}","\u{29}",2.2)
453testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{61}\u{20}\u{28}\u{78}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{20}\u{65}\u{6e}\u{64}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{61}\u{28}","\u{32}\u{2e}\u{32}","\u{29}",2.2)
454testrep("","\u{64}\u{6f}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
454testrep("","\u{64}\u{6f}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
455testrep("","\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{61}\u{20}\u{64}\u{6f}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
455testrep("","\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{61}\u{20}\u{64}\u{6f}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
456testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3b}\u{20}","\u{69}\u{66}\u{20}\u{61}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{65}\u{6c}\u{73}\u{65}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
456testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3b}\u{20}","\u{69}\u{66}\u{20}\u{61}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{65}\u{6c}\u{73}\u{65}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
457testrep("","\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{20}\u{28}\u{29}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
457testrep("","\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{20}\u{28}\u{29}\u{20}","","\u{20}\u{65}\u{6e}\u{64}")
458testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{27}\u{27}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{61}\u{2e}\u{2e}","\u{27}\u{61}\u{27}","","\u{61}")
458testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{27}\u{27}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{61}\u{2e}\u{2e}","\u{27}\u{61}\u{27}","","\u{61}")
459−testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{61}\u{5e}","\u{61}","",1)
459+testrep("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}","\u{61}\u{5e}","\u{61}","",0x1)
460−checkmessage("\u{61}\u{20}\u{3d}\u{20}\u{66}\u{28}\u{78}" .. string.rep("\u{2c}\u{78}",260) .. "\u{29}","\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{67}\u{69}\u{73}\u{74}\u{65}\u{72}\u{73}")
460+checkmessage("\u{61}\u{20}\u{3d}\u{20}\u{66}\u{28}\u{78}" .. string.rep("\u{2c}\u{78}",0x104) .. "\u{29}","\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{67}\u{69}\u{73}\u{74}\u{65}\u{72}\u{73}")
461−local lim = 127
461+local lim = 0x7f
462local s = "\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{41}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}"
462local s = "\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{41}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}"
463−for j = 1, lim
463+for j = 0x1, lim
464do
464do
465s=s .. "\u{61}" .. j .. "\u{2c}\u{20}"
465s=s .. "\u{61}" .. j .. "\u{2c}\u{20}"
466end
466end
467s=s .. "\u{62}\u{2c}\u{63}\u{a}"
467s=s .. "\u{62}\u{2c}\u{63}\u{a}"
468s=s .. "\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{42}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}"
468s=s .. "\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{42}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}"
469−for j = 1, lim
469+for j = 0x1, lim
470do
470do
471s=s .. "\u{62}" .. j .. "\u{2c}\u{20}"
471s=s .. "\u{62}" .. j .. "\u{2c}\u{20}"
472end
472end
473s=s .. "\u{62}\u{a}"
473s=s .. "\u{62}\u{a}"
474s=s .. "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{43}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{62}\u{2b}\u{63}"
474s=s .. "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{43}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{62}\u{2b}\u{63}"
475−local c = 1 + 2
475+local c = 0x1 + 0x2
476−for j = 1, lim
476+for j = 0x1, lim
477do
477do
478s=s .. "\u{2b}\u{61}" .. j .. "\u{2b}\u{62}" .. j
478s=s .. "\u{2b}\u{61}" .. j .. "\u{2b}\u{62}" .. j
479−c=c + 2
479+c=c + 0x2
480end
480end
481s=s .. "\u{a}\u{65}\u{6e}\u{64}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{20}\u{65}\u{6e}\u{64}"
481s=s .. "\u{a}\u{65}\u{6e}\u{64}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{20}\u{65}\u{6e}\u{64}"
482local a,b = load(s)
482local a,b = load(s)
483−assert(c > 255 and string.find(b,"\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{73}") and string.find(b,"\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{35}"))
483+assert(c > 0xff and string.find(b,"\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{75}\u{70}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{73}") and string.find(b,"\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{35}"))
484s="\u{a}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}"
484s="\u{a}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{20}\u{28}\u{29}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}"
485−for j = 1, 300
485+for j = 0x1, 0x12c
486do
486do
487s=s .. "\u{61}" .. j .. "\u{2c}\u{20}"
487s=s .. "\u{61}" .. j .. "\u{2c}\u{20}"
488end
488end
zod/luau/res/lua/cycled/events.lua+143−143
@@ -1,18 +1,18 @@
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
2local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
2local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
3−X=20
3+X=0x14
4;
4;
5−B=30
5+B=0x1e
6_ENV=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = _G})
6_ENV=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = _G})
7collectgarbage()
7collectgarbage()
8−X=X + 10
8+X=X + 0xa
9−assert(X == 30 and _G.X == 20)
9+assert(X == 0x1e and _G.X == 0x14)
10B=false
10B=false
11assert(B == false)
11assert(B == false)
12_ENV["\u{42}"]=undef
12_ENV["\u{42}"]=undef
13−assert(B == 30)
13+assert(B == 0x1e)
14assert(getmetatable({}) == nil)
14assert(getmetatable({}) == nil)
15−assert(getmetatable(4) == nil)
15+assert(getmetatable(0x4) == nil)
16assert(getmetatable(nil) == nil)
16assert(getmetatable(nil) == nil)
17a={["\u{6e}\u{61}\u{6d}\u{65}"] = "\u{4e}\u{41}\u{4d}\u{45}"}
17a={["\u{6e}\u{61}\u{6d}\u{65}"] = "\u{4e}\u{41}\u{4d}\u{45}"}
18;
18;
@@ -24,7 +24,7 @@ assert(tostring(a) == "\u{4e}\u{41}\u{4d}\u{45}")
24assert(pcall(setmetatable,a,{}) == false)
24assert(pcall(setmetatable,a,{}) == false)
25a.name="\u{67}\u{6f}\u{72}\u{6f}\u{72}\u{6f}\u{62}\u{61}"
25a.name="\u{67}\u{6f}\u{72}\u{6f}\u{72}\u{6f}\u{62}\u{61}"
26assert(tostring(a) == "\u{67}\u{6f}\u{72}\u{6f}\u{72}\u{6f}\u{62}\u{61}")
26assert(tostring(a) == "\u{67}\u{6f}\u{72}\u{6f}\u{72}\u{6f}\u{62}\u{61}")
27−local a,t = {10,20,30,["\u{78}"] = "\u{31}\u{30}",["\u{79}"] = "\u{32}\u{30}"},{}
27+local a,t = {0xa,0x14,0x1e,["\u{78}"] = "\u{31}\u{30}",["\u{79}"] = "\u{32}\u{30}"},{}
28assert(setmetatable(a,t) == a)
28assert(setmetatable(a,t) == a)
29assert(getmetatable(a) == t)
29assert(getmetatable(a) == t)
30assert(setmetatable(a,nil) == a)
30assert(setmetatable(a,nil) == a)
@@ -33,71 +33,71 @@ assert(setmetatable(a,t) == a)
33function f(t,i,e)
33function f(t,i,e)
34assert(not e)
34assert(not e)
35local p = rawget(t,"\u{70}\u{61}\u{72}\u{65}\u{6e}\u{74}")
35local p = rawget(t,"\u{70}\u{61}\u{72}\u{65}\u{6e}\u{74}")
36−return (p and p[i] + 3),"\u{64}\u{75}\u{6d}\u{6d}\u{79}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"
36+return (p and p[i] + 0x3),"\u{64}\u{75}\u{6d}\u{6d}\u{79}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"
37end
37end
38t.__index=f
38t.__index=f
39−a.parent={["\u{7a}"] = 25,["\u{78}"] = 12,[4] = 24}
39+a.parent={["\u{7a}"] = 0x19,["\u{78}"] = 0xc,[0x4] = 0x18}
40−assert(a[1] == 10 and a.z == 28 and a[4] == 27 and a.x == "\u{31}\u{30}")
40+assert(a[0x1] == 0xa and a.z == 0x1c and a[0x4] == 0x1b and a.x == "\u{31}\u{30}")
41collectgarbage()
41collectgarbage()
42a=setmetatable({},t)
42a=setmetatable({},t)
43function f(t,i,v)
43function f(t,i,v)
44−rawset(t,i,v - 3)
44+rawset(t,i,v - 0x3)
45end
45end
46setmetatable(t,t)
46setmetatable(t,t)
47t.__newindex=f
47t.__newindex=f
48−a[1]=30
48+a[0x1]=0x1e
49;
49;
50a.x="\u{31}\u{30}\u{31}"
50a.x="\u{31}\u{30}\u{31}"
51;
51;
52−a[5]=200
52+a[0x5]=0xc8
53−assert(a[1] == 27 and a.x == 98 and a[5] == 197)
53+assert(a[0x1] == 0x1b and a.x == 0x62 and a[0x5] == 0xc5)
54do
54do
55local mt = {}
55local mt = {}
56mt.__newindex=mt
56mt.__newindex=mt
57local t = setmetatable({},mt)
57local t = setmetatable({},mt)
58−t[1]=10
58+t[0x1]=0xa
59−assert(mt[1] == 10)
59+assert(mt[0x1] == 0xa)
60end
60end
61local c = {}
61local c = {}
62a=setmetatable({},t)
62a=setmetatable({},t)
63t.__newindex=c
63t.__newindex=c
64t.__index=c
64t.__index=c
65−a[1]=10
65+a[0x1]=0xa
66;
66;
67−a[2]=20
67+a[0x2]=0x14
68;
68;
69−a[3]=90
69+a[0x3]=0x5a
70;
70;
71−for i = 4, 20
71+for i = 0x4, 0x14
72do
72do
73−a[i]=i * 10
73+a[i]=i * 0xa
74end
74end
75−assert(a[1] == 10 and a[2] == 20 and a[3] == 90)
75+assert(a[0x1] == 0xa and a[0x2] == 0x14 and a[0x3] == 0x5a)
76−for i = 4, 20
76+for i = 0x4, 0x14
77do
77do
78−assert(a[i] == i * 10)
78+assert(a[i] == i * 0xa)
79end
79end
80assert(next(a) == nil)
80assert(next(a) == nil)
81do
81do
82local a
82local a
83;
83;
84a=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,n)
84a=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,n)
85−return a[n - 3] + 4,"\u{6c}\u{69}\u{78}\u{6f}"
85+return a[n - 0x3] + 0x4,"\u{6c}\u{69}\u{78}\u{6f}"
86end})})})
86end})})})
87−a[0]=20
87+a[0x0]=0x14
88−for i = 0, 10
88+for i = 0x0, 0xa
89do
89do
90−assert(a[i * 3] == 20 + i * 4)
90+assert(a[i * 0x3] == 0x14 + i * 0x4)
91end
91end
92end
92end
93do
93do
94local foi
94local foi
95local a = {}
95local a = {}
96−for i = 1, 10
96+for i = 0x1, 0xa
97do
97do
98−a[i]=0
98+a[i]=0x0
99;
99;
100−a["\u{61}" .. i]=0
100+a["\u{61}" .. i]=0x0
101;
101;
102end
102end
103setmetatable(a,{["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k,v)
103setmetatable(a,{["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k,v)
@@ -107,33 +107,33 @@ rawset(t,k,v)
107end})
107end})
108foi=false
108foi=false
109;
109;
110−a[1]=0
110+a[0x1]=0x0
111;
111;
112assert(not foi)
112assert(not foi)
113foi=false
113foi=false
114;
114;
115−a["\u{61}\u{31}"]=0
115+a["\u{61}\u{31}"]=0x0
116;
116;
117assert(not foi)
117assert(not foi)
118foi=false
118foi=false
119;
119;
120−a["\u{61}\u{31}\u{31}"]=0
120+a["\u{61}\u{31}\u{31}"]=0x0
121;
121;
122assert(foi)
122assert(foi)
123foi=false
123foi=false
124;
124;
125−a[11]=0
125+a[0xb]=0x0
126;
126;
127assert(foi)
127assert(foi)
128foi=false
128foi=false
129;
129;
130−a[1]=undef
130+a[0x1]=undef
131;
131;
132assert(not foi)
132assert(not foi)
133−a[1]=undef
133+a[0x1]=undef
134foi=false
134foi=false
135;
135;
136−a[1]=nil
136+a[0x1]=nil
137;
137;
138assert(foi)
138assert(foi)
139end
139end
@@ -143,16 +143,16 @@ return t,{...}
143end
143end
144t.__call=f
144t.__call=f
145do
145do
146−local x,y = a(table.unpack({"\u{61}",1}))
146+local x,y = a(table.unpack({"\u{61}",0x1}))
147−assert(x == a and y[1] == "\u{61}" and y[2] == 1 and y[3] == undef)
147+assert(x == a and y[0x1] == "\u{61}" and y[0x2] == 0x1 and y[0x3] == undef)
148x,y=a()
148x,y=a()
149−assert(x == a and y[1] == undef)
149+assert(x == a and y[0x1] == undef)
150end
150end
151local b = setmetatable({},t)
151local b = setmetatable({},t)
152setmetatable(b,t)
152setmetatable(b,t)
153function f(op)
153function f(op)
154return function (...)
154return function (...)
155−cap={[0] = op,...}
155+cap={[0x0] = op,...}
156;
156;
157return (...)
157return (...)
158end
158end
@@ -176,54 +176,54 @@ t.__lt=f("\u{6c}\u{74}")
176t.__le=f("\u{6c}\u{65}")
176t.__le=f("\u{6c}\u{65}")
177local function checkcap
177local function checkcap
178(t)
178(t)
179−assert(# cap + 1 == # t)
179+assert(# cap + 0x1 == # t)
180−for i = 1, # t
180+for i = 0x1, # t
181do
181do
182−assert(cap[i - 1] == t[i])
182+assert(cap[i - 0x1] == t[i])
183−assert(math.type(cap[i - 1]) == math.type(t[i]))
183+assert(math.type(cap[i - 0x1]) == math.type(t[i]))
184end
184end
185end
185end
186−assert(b + 5 == b)
186+assert(b + 0x5 == b)
187;
187;
188−checkcap({"\u{61}\u{64}\u{64}",b,5})
188+checkcap({"\u{61}\u{64}\u{64}",b,0x5})
189assert(5.2 + b == 5.2)
189assert(5.2 + b == 5.2)
190;
190;
191checkcap({"\u{61}\u{64}\u{64}",5.2,b})
191checkcap({"\u{61}\u{64}\u{64}",5.2,b})
192assert(b + "\u{35}" == b)
192assert(b + "\u{35}" == b)
193;
193;
194checkcap({"\u{61}\u{64}\u{64}",b,"\u{35}"})
194checkcap({"\u{61}\u{64}\u{64}",b,"\u{35}"})
195−assert(5 + b == 5)
195+assert(0x5 + b == 0x5)
196;
196;
197−checkcap({"\u{61}\u{64}\u{64}",5,b})
197+checkcap({"\u{61}\u{64}\u{64}",0x5,b})
198assert("\u{35}" + b == "\u{35}")
198assert("\u{35}" + b == "\u{35}")
199;
199;
200checkcap({"\u{61}\u{64}\u{64}","\u{35}",b})
200checkcap({"\u{61}\u{64}\u{64}","\u{35}",b})
201−b=b - 3
201+b=b - 0x3
202;
202;
203assert(getmetatable(b) == t)
203assert(getmetatable(b) == t)
204;
204;
205−checkcap({"\u{73}\u{75}\u{62}",b,3})
205+checkcap({"\u{73}\u{75}\u{62}",b,0x3})
206−assert(5 - a == 5)
206+assert(0x5 - a == 0x5)
207;
207;
208−checkcap({"\u{73}\u{75}\u{62}",5,a})
208+checkcap({"\u{73}\u{75}\u{62}",0x5,a})
209assert("\u{35}" - a == "\u{35}")
209assert("\u{35}" - a == "\u{35}")
210;
210;
211checkcap({"\u{73}\u{75}\u{62}","\u{35}",a})
211checkcap({"\u{73}\u{75}\u{62}","\u{35}",a})
212assert(a * a == a)
212assert(a * a == a)
213;
213;
214checkcap({"\u{6d}\u{75}\u{6c}",a,a})
214checkcap({"\u{6d}\u{75}\u{6c}",a,a})
215−assert(a / 0 == a)
215+assert(a / 0x0 == a)
216;
216;
217−checkcap({"\u{64}\u{69}\u{76}",a,0})
217+checkcap({"\u{64}\u{69}\u{76}",a,0x0})
218assert(a / 0.0 == a)
218assert(a / 0.0 == a)
219;
219;
220checkcap({"\u{64}\u{69}\u{76}",a,0.0})
220checkcap({"\u{64}\u{69}\u{76}",a,0.0})
221−assert(a % 2 == a)
221+assert(a % 0x2 == a)
222;
222;
223−checkcap({"\u{6d}\u{6f}\u{64}",a,2})
223+checkcap({"\u{6d}\u{6f}\u{64}",a,0x2})
224−assert(a // (1 / 0) == a)
224+assert(a // (0x1 / 0x0) == a)
225;
225;
226−checkcap({"\u{69}\u{64}\u{69}\u{76}",a,1 / 0})
226+checkcap({"\u{69}\u{64}\u{69}\u{76}",a,0x1 / 0x0})
227;
227;
228(function ()
228(function ()
229assert(a & "\u{68}\u{69}" == a)
229assert(a & "\u{68}\u{69}" == a)
@@ -232,16 +232,16 @@ end)()
232checkcap({"\u{62}\u{61}\u{6e}\u{64}",a,"\u{68}\u{69}"})
232checkcap({"\u{62}\u{61}\u{6e}\u{64}",a,"\u{68}\u{69}"})
233;
233;
234(function ()
234(function ()
235−assert(10 & a == 10)
235+assert(0xa & a == 0xa)
236end)()
236end)()
237;
237;
238−checkcap({"\u{62}\u{61}\u{6e}\u{64}",10,a})
238+checkcap({"\u{62}\u{61}\u{6e}\u{64}",0xa,a})
239;
239;
240(function ()
240(function ()
241−assert(a | 10 == a)
241+assert(a | 0xa == a)
242end)()
242end)()
243;
243;
244−checkcap({"\u{62}\u{6f}\u{72}",a,10})
244+checkcap({"\u{62}\u{6f}\u{72}",a,0xa})
245assert(a | "\u{68}\u{69}" == a)
245assert(a | "\u{68}\u{69}" == a)
246;
246;
247checkcap({"\u{62}\u{6f}\u{72}",a,"\u{68}\u{69}"})
247checkcap({"\u{62}\u{6f}\u{72}",a,"\u{68}\u{69}"})
@@ -250,10 +250,10 @@ assert("\u{68}\u{69}" ~ a == "\u{68}\u{69}")
250checkcap({"\u{62}\u{78}\u{6f}\u{72}","\u{68}\u{69}",a})
250checkcap({"\u{62}\u{78}\u{6f}\u{72}","\u{68}\u{69}",a})
251;
251;
252(function ()
252(function ()
253−assert(10 ~ a == 10)
253+assert(0xa ~ a == 0xa)
254end)()
254end)()
255;
255;
256−checkcap({"\u{62}\u{78}\u{6f}\u{72}",10,a})
256+checkcap({"\u{62}\u{78}\u{6f}\u{72}",0xa,a})
257assert(- a == a)
257assert(- a == a)
258;
258;
259checkcap({"\u{75}\u{6e}\u{6d}",a,a})
259checkcap({"\u{75}\u{6e}\u{6d}",a,a})
@@ -263,9 +263,9 @@ checkcap({"\u{70}\u{6f}\u{77}",a,4.0})
263assert(a ^ "\u{34}" == a)
263assert(a ^ "\u{34}" == a)
264;
264;
265checkcap({"\u{70}\u{6f}\u{77}",a,"\u{34}"})
265checkcap({"\u{70}\u{6f}\u{77}",a,"\u{34}"})
266−assert(4 ^ a == 4)
266+assert(0x4 ^ a == 0x4)
267;
267;
268−checkcap({"\u{70}\u{6f}\u{77}",4,a})
268+checkcap({"\u{70}\u{6f}\u{77}",0x4,a})
269assert("\u{34}" ^ a == "\u{34}")
269assert("\u{34}" ^ a == "\u{34}")
270;
270;
271checkcap({"\u{70}\u{6f}\u{77}","\u{34}",a})
271checkcap({"\u{70}\u{6f}\u{77}","\u{34}",a})
@@ -275,33 +275,33 @@ checkcap({"\u{6c}\u{65}\u{6e}",a,a})
275assert(~ a == a)
275assert(~ a == a)
276;
276;
277checkcap({"\u{62}\u{6e}\u{6f}\u{74}",a,a})
277checkcap({"\u{62}\u{6e}\u{6f}\u{74}",a,a})
278−assert(a << 3 == a)
278+assert(a << 0x3 == a)
279;
279;
280−checkcap({"\u{73}\u{68}\u{6c}",a,3})
280+checkcap({"\u{73}\u{68}\u{6c}",a,0x3})
281assert(1.5 >> a == 1.5)
281assert(1.5 >> a == 1.5)
282;
282;
283checkcap({"\u{73}\u{68}\u{72}",1.5,a})
283checkcap({"\u{73}\u{68}\u{72}",1.5,a})
284assert(5.0 > a)
284assert(5.0 > a)
285;
285;
286checkcap({"\u{6c}\u{74}",a,5.0})
286checkcap({"\u{6c}\u{74}",a,5.0})
287−assert(a >= 10)
287+assert(a >= 0xa)
288;
288;
289−checkcap({"\u{6c}\u{65}",10,a})
289+checkcap({"\u{6c}\u{65}",0xa,a})
290assert(a <= - 10.0)
290assert(a <= - 10.0)
291;
291;
292checkcap({"\u{6c}\u{65}",a,- 10.0})
292checkcap({"\u{6c}\u{65}",a,- 10.0})
293−assert(a < - 10)
293+assert(a < - 0xa)
294;
294;
295−checkcap({"\u{6c}\u{74}",a,- 10})
295+checkcap({"\u{6c}\u{74}",a,- 0xa})
296−t=setmetatable({1,2,3},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
296+t=setmetatable({0x1,0x2,0x3},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
297−return 10
297+return 0xa
298end})
298end})
299−assert(# t == 10 and rawlen(t) == 3)
299+assert(# t == 0xa and rawlen(t) == 0x3)
300−assert(rawlen("\u{61}\u{62}\u{63}") == 3)
300+assert(rawlen("\u{61}\u{62}\u{63}") == 0x3)
301assert(not pcall(rawlen,io.stdin))
301assert(not pcall(rawlen,io.stdin))
302−assert(not pcall(rawlen,34))
302+assert(not pcall(rawlen,0x22))
303assert(not pcall(rawlen))
303assert(not pcall(rawlen))
304−assert(rawlen(string.rep("\u{61}",1000)) == 1000)
304+assert(rawlen(string.rep("\u{61}",0x3e8)) == 0x3e8)
305t={}
305t={}
306t.__lt=function (a,b,c)
306t.__lt=function (a,b,c)
307collectgarbage()
307collectgarbage()
@@ -339,30 +339,30 @@ return setmetatable({["\u{78}"] = x},t)
339end
339end
340local function test
340local function test
341(a,b,c)
341(a,b,c)
342−assert(not (Op(1) < Op(1)) and (Op(1) < Op(2)) and not (Op(2) < Op(1)))
342+assert(not (Op(0x1) < Op(0x1)) and (Op(0x1) < Op(0x2)) and not (Op(0x2) < Op(0x1)))
343−assert(not (1 < Op(1)) and (Op(1) < 2) and not (2 < Op(1)))
343+assert(not (0x1 < Op(0x1)) and (Op(0x1) < 0x2) and not (0x2 < Op(0x1)))
344assert(not (Op("\u{61}") < Op("\u{61}")) and (Op("\u{61}") < Op("\u{62}")) and not (Op("\u{62}") < Op("\u{61}")))
344assert(not (Op("\u{61}") < Op("\u{61}")) and (Op("\u{61}") < Op("\u{62}")) and not (Op("\u{62}") < Op("\u{61}")))
345assert(not ("\u{61}" < Op("\u{61}")) and (Op("\u{61}") < "\u{62}") and not (Op("\u{62}") < Op("\u{61}")))
345assert(not ("\u{61}" < Op("\u{61}")) and (Op("\u{61}") < "\u{62}") and not (Op("\u{62}") < Op("\u{61}")))
346−assert((Op(1) <= Op(1)) and (Op(1) <= Op(2)) and not (Op(2) <= Op(1)))
346+assert((Op(0x1) <= Op(0x1)) and (Op(0x1) <= Op(0x2)) and not (Op(0x2) <= Op(0x1)))
347assert((Op("\u{61}") <= Op("\u{61}")) and (Op("\u{61}") <= Op("\u{62}")) and not (Op("\u{62}") <= Op("\u{61}")))
347assert((Op("\u{61}") <= Op("\u{61}")) and (Op("\u{61}") <= Op("\u{62}")) and not (Op("\u{62}") <= Op("\u{61}")))
348−assert(not (Op(1) > Op(1)) and not (Op(1) > Op(2)) and (Op(2) > Op(1)))
348+assert(not (Op(0x1) > Op(0x1)) and not (Op(0x1) > Op(0x2)) and (Op(0x2) > Op(0x1)))
349assert(not (Op("\u{61}") > Op("\u{61}")) and not (Op("\u{61}") > Op("\u{62}")) and (Op("\u{62}") > Op("\u{61}")))
349assert(not (Op("\u{61}") > Op("\u{61}")) and not (Op("\u{61}") > Op("\u{62}")) and (Op("\u{62}") > Op("\u{61}")))
350−assert((Op(1) >= Op(1)) and not (Op(1) >= Op(2)) and (Op(2) >= Op(1)))
350+assert((Op(0x1) >= Op(0x1)) and not (Op(0x1) >= Op(0x2)) and (Op(0x2) >= Op(0x1)))
351−assert((1 >= Op(1)) and not (1 >= Op(2)) and (Op(2) >= 1))
351+assert((0x1 >= Op(0x1)) and not (0x1 >= Op(0x2)) and (Op(0x2) >= 0x1))
352assert((Op("\u{61}") >= Op("\u{61}")) and not (Op("\u{61}") >= Op("\u{62}")) and (Op("\u{62}") >= Op("\u{61}")))
352assert((Op("\u{61}") >= Op("\u{61}")) and not (Op("\u{61}") >= Op("\u{62}")) and (Op("\u{62}") >= Op("\u{61}")))
353assert(("\u{61}" >= Op("\u{61}")) and not (Op("\u{61}") >= "\u{62}") and (Op("\u{62}") >= Op("\u{61}")))
353assert(("\u{61}" >= Op("\u{61}")) and not (Op("\u{61}") >= "\u{62}") and (Op("\u{62}") >= Op("\u{61}")))
354−assert(Op(1) == Op(1) and Op(1) ~= Op(2))
354+assert(Op(0x1) == Op(0x1) and Op(0x1) ~= Op(0x2))
355assert(Op("\u{61}") == Op("\u{61}") and Op("\u{61}") ~= Op("\u{62}"))
355assert(Op("\u{61}") == Op("\u{61}") and Op("\u{61}") ~= Op("\u{62}"))
356assert(a == a and a ~= b)
356assert(a == a and a ~= b)
357−assert(Op(3) == c)
357+assert(Op(0x3) == c)
358end
358end
359−test(Op(1),Op(2),Op(3))
359+test(Op(0x1),Op(0x2),Op(0x3))
360local function rawSet
360local function rawSet
361(x)
361(x)
362local y = {}
362local y = {}
363for _,k in pairs(x)
363for _,k in pairs(x)
364do
364do
365−y[k]=1
365+y[k]=0x1
366end
366end
367return y
367return y
368end
368end
@@ -389,13 +389,13 @@ end
389end
389end
390return true
390return true
391end
391end
392−assert(Set({1,2,3}) < Set({1,2,3,4}))
392+assert(Set({0x1,0x2,0x3}) < Set({0x1,0x2,0x3,0x4}))
393−assert(not (Set({1,2,3,4}) < Set({1,2,3,4})))
393+assert(not (Set({0x1,0x2,0x3,0x4}) < Set({0x1,0x2,0x3,0x4})))
394−assert((Set({1,2,3,4}) <= Set({1,2,3,4})))
394+assert((Set({0x1,0x2,0x3,0x4}) <= Set({0x1,0x2,0x3,0x4})))
395−assert((Set({1,2,3,4}) >= Set({1,2,3,4})))
395+assert((Set({0x1,0x2,0x3,0x4}) >= Set({0x1,0x2,0x3,0x4})))
396−assert(not (Set({1,3}) <= Set({3,5})))
396+assert(not (Set({0x1,0x3}) <= Set({0x3,0x5})))
397−assert(not (Set({1,3}) <= Set({3,5})))
397+assert(not (Set({0x1,0x3}) <= Set({0x3,0x5})))
398−assert(not (Set({1,3}) >= Set({3,5})))
398+assert(not (Set({0x1,0x3}) >= Set({0x3,0x5})))
399t.__eq=function (a,b)
399t.__eq=function (a,b)
400for k in pairs(a)
400for k in pairs(a)
401do
401do
@@ -406,38 +406,38 @@ b[k]=undef
406end
406end
407return next(b) == nil
407return next(b) == nil
408end
408end
409−local s = Set({1,3,5})
409+local s = Set({0x1,0x3,0x5})
410−assert(s == Set({3,5,1}))
410+assert(s == Set({0x3,0x5,0x1}))
411−assert(not rawequal(s,Set({3,5,1})))
411+assert(not rawequal(s,Set({0x3,0x5,0x1})))
412assert(rawequal(s,s))
412assert(rawequal(s,s))
413−assert(Set({1,3,5,1}) == rawSet({3,5,1}))
413+assert(Set({0x1,0x3,0x5,0x1}) == rawSet({0x3,0x5,0x1}))
414−assert(rawSet({1,3,5,1}) == Set({3,5,1}))
414+assert(rawSet({0x1,0x3,0x5,0x1}) == Set({0x3,0x5,0x1}))
415−assert(Set({1,3,5}) ~= Set({3,5,1,6}))
415+assert(Set({0x1,0x3,0x5}) ~= Set({0x3,0x5,0x1,0x6}))
416−t[Set({1,3,5})]=1
416+t[Set({0x1,0x3,0x5})]=0x1
417−assert(t[Set({1,3,5})] == undef)
417+assert(t[Set({0x1,0x3,0x5})] == undef)
418do
418do
419local mt = {["\u{5f}\u{5f}\u{65}\u{71}"] = true}
419local mt = {["\u{5f}\u{5f}\u{65}\u{71}"] = true}
420−local a = setmetatable({10},mt)
420+local a = setmetatable({0xa},mt)
421−local b = setmetatable({10},mt)
421+local b = setmetatable({0xa},mt)
422mt.__eq=nil
422mt.__eq=nil
423assert(a ~= b)
423assert(a ~= b)
424mt.__eq=function (x,y)
424mt.__eq=function (x,y)
425−return x[1] == y[1]
425+return x[0x1] == y[0x1]
426end
426end
427assert(a == b)
427assert(a == b)
428end
428end
429if not T then
429if not T then
430(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
430(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
431else
431else
432−local u1 = T.newuserdata(0,1)
432+local u1 = T.newuserdata(0x0,0x1)
433−local u2 = T.newuserdata(0,1)
433+local u2 = T.newuserdata(0x0,0x1)
434−local u3 = T.newuserdata(0,1)
434+local u3 = T.newuserdata(0x0,0x1)
435assert(u1 ~= u2 and u1 ~= u3)
435assert(u1 ~= u2 and u1 ~= u3)
436−debug.setuservalue(u1,1)
436+debug.setuservalue(u1,0x1)
437;
437;
438−debug.setuservalue(u2,2)
438+debug.setuservalue(u2,0x2)
439;
439;
440−debug.setuservalue(u3,1)
440+debug.setuservalue(u3,0x1)
441;
441;
442debug.setmetatable(u1,{["\u{5f}\u{5f}\u{65}\u{71}"] = function (a,b)
442debug.setmetatable(u1,{["\u{5f}\u{5f}\u{65}\u{71}"] = function (a,b)
443return debug.getuservalue(a) == debug.getuservalue(b)
443return debug.getuservalue(a) == debug.getuservalue(b)
@@ -451,11 +451,11 @@ assert(u2 ~= {})
451assert(rawequal(u1,u1) and not rawequal(u1,u3))
451assert(rawequal(u1,u1) and not rawequal(u1,u3))
452local mirror = {}
452local mirror = {}
453debug.setmetatable(u3,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = mirror,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = mirror})
453debug.setmetatable(u3,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = mirror,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = mirror})
454−for i = 1, 10
454+for i = 0x1, 0xa
455do
455do
456u3[i]=i
456u3[i]=i
457end
457end
458−for i = 1, 10
458+for i = 0x1, 0xa
459do
459do
460assert(u3[i] == i)
460assert(u3[i] == i)
461end
461end
@@ -482,12 +482,12 @@ d={["\u{76}\u{61}\u{6c}"] = "\u{64}"}
482setmetatable(d,t)
482setmetatable(d,t)
483A=true
483A=true
484assert(c .. d == "\u{63}\u{64}")
484assert(c .. d == "\u{63}\u{64}")
485−assert(0 .. "\u{61}" .. "\u{62}" .. c .. d .. "\u{65}" .. "\u{66}" .. (5 + 3) .. "\u{67}" == "\u{30}\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{38}\u{67}")
485+assert(0x0 .. "\u{61}" .. "\u{62}" .. c .. d .. "\u{65}" .. "\u{66}" .. (0x5 + 0x3) .. "\u{67}" == "\u{30}\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{38}\u{67}")
486A=false
486A=false
487assert((c .. d .. c .. d).val == "\u{63}\u{64}\u{63}\u{64}")
487assert((c .. d .. c .. d).val == "\u{63}\u{64}\u{63}\u{64}")
488x=c .. d
488x=c .. d
489assert(getmetatable(x) == t and x.val == "\u{63}\u{64}")
489assert(getmetatable(x) == t and x.val == "\u{63}\u{64}")
490−x=0 .. "\u{61}" .. "\u{62}" .. c .. d .. "\u{65}" .. "\u{66}" .. "\u{67}"
490+x=0x0 .. "\u{61}" .. "\u{62}" .. c .. d .. "\u{65}" .. "\u{66}" .. "\u{67}"
491assert(x.val == "\u{30}\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}")
491assert(x.val == "\u{30}\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}")
492c={}
492c={}
493local x
493local x
@@ -495,8 +495,8 @@ setmetatable(c,{["\u{5f}\u{5f}\u{63}\u{6f}\u{6e}\u{63}\u{61}\u{74}"] = function
495assert(type(a) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and b == c or type(b) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and a == c)
495assert(type(a) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and b == c or type(b) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and a == c)
496return c
496return c
497end})
497end})
498−assert(c .. 5 == c and 5 .. c == c)
498+assert(c .. 0x5 == c and 0x5 .. c == c)
499−assert(4 .. c .. 5 == c and 4 .. 5 .. 6 .. 7 .. c == c)
499+assert(0x4 .. c .. 0x5 == c and 0x4 .. 0x5 .. 0x6 .. 0x7 .. c == c)
500local t1,t2,c,d
500local t1,t2,c,d
501t1={}
501t1={}
502;
502;
@@ -522,7 +522,7 @@ setmetatable(d,t2)
522assert(c == d and c < d and not (d <= c))
522assert(c == d and c < d and not (d <= c))
523local i
523local i
524local tt = {["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = function (t, ...)
524local tt = {["\u{5f}\u{5f}\u{63}\u{61}\u{6c}\u{6c}"] = function (t, ...)
525−i=i + 1
525+i=i + 0x1
526if t.f then
526if t.f then
527return t.f(...)
527return t.f(...)
528else
528else
@@ -532,10 +532,10 @@ end}
532local a = setmetatable({},tt)
532local a = setmetatable({},tt)
533local b = setmetatable({["\u{66}"] = a},tt)
533local b = setmetatable({["\u{66}"] = a},tt)
534local c = setmetatable({["\u{66}"] = b},tt)
534local c = setmetatable({["\u{66}"] = b},tt)
535−i=0
535+i=0x0
536−x=c(3,4,5)
536+x=c(0x3,0x4,0x5)
537−assert(i == 3 and x[1] == 3 and x[3] == 5)
537+assert(i == 0x3 and x[0x1] == 0x3 and x[0x3] == 0x5)
538−assert(_G.X == 20)
538+assert(_G.X == 0x14)
539_G.X,_G.B=nil
539_G.X,_G.B=nil
540print("\u{2b}")
540print("\u{2b}")
541local _g = _G
541local _g = _G
@@ -543,21 +543,21 @@ _ENV=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function
543return _g[k]
543return _g[k]
544end})
544end})
545a={}
545a={}
546−rawset(a,"\u{78}",1,2,3)
546+rawset(a,"\u{78}",0x1,0x2,0x3)
547−assert(a.x == 1 and rawget(a,"\u{78}",3) == 1)
547+assert(a.x == 0x1 and rawget(a,"\u{78}",0x3) == 0x1)
548print("\u{2b}")
548print("\u{2b}")
549mt={["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (a,b)
549mt={["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (a,b)
550return a + b
550return a + b
551end,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function (x)
551end,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function (x)
552return math.floor(x)
552return math.floor(x)
553end}
553end}
554−debug.setmetatable(10,mt)
554+debug.setmetatable(0xa,mt)
555−assert(getmetatable(- 2) == mt)
555+assert(getmetatable(- 0x2) == mt)
556−assert((10)[3] == 13)
556+assert((0xa)[0x3] == 0xd)
557−assert((10)["\u{33}"] == 13)
557+assert((0xa)["\u{33}"] == 0xd)
558−assert(# 3.45 == 3)
558+assert(# 3.45 == 0x3)
559−debug.setmetatable(23,nil)
559+debug.setmetatable(0x17,nil)
560−assert(getmetatable(- 2) == nil)
560+assert(getmetatable(- 0x2) == nil)
561debug.setmetatable(true,mt)
561debug.setmetatable(true,mt)
562assert(getmetatable(false) == mt)
562assert(getmetatable(false) == mt)
563mt.__index=function (a,b)
563mt.__index=function (a,b)
@@ -570,11 +570,11 @@ assert(getmetatable(true) == nil)
570debug.setmetatable(nil,mt)
570debug.setmetatable(nil,mt)
571assert(getmetatable(nil) == mt)
571assert(getmetatable(nil) == mt)
572mt.__add=function (a,b)
572mt.__add=function (a,b)
573−return (a or 1) + (b or 2)
573+return (a or 0x1) + (b or 0x2)
574end
574end
575−assert(10 + nil == 12)
575+assert(0xa + nil == 0xc)
576−assert(nil + 23 == 24)
576+assert(nil + 0x17 == 0x18)
577−assert(nil + nil == 3)
577+assert(nil + nil == 0x3)
578debug.setmetatable(nil,nil)
578debug.setmetatable(nil,nil)
579assert(getmetatable(nil) == nil)
579assert(getmetatable(nil) == nil)
580debug.setmetatable(nil,{})
580debug.setmetatable(nil,{})
@@ -587,10 +587,10 @@ a.__index=a
587a.__newindex=a
587a.__newindex=a
588assert(not pcall(function (a,b)
588assert(not pcall(function (a,b)
589return a[b]
589return a[b]
590−end,a,10))
590+end,a,0xa))
591assert(not pcall(function (a,b,c)
591assert(not pcall(function (a,b,c)
592a[b]=c
592a[b]=c
593−end,a,10,true))
593+end,a,0xa,true))
594T,K,V=nil
594T,K,V=nil
595grandparent={}
595grandparent={}
596grandparent.__newindex=function (t,k,v)
596grandparent.__newindex=function (t,k,v)
@@ -604,7 +604,7 @@ parent={}
604parent.__newindex=parent
604parent.__newindex=parent
605setmetatable(parent,grandparent)
605setmetatable(parent,grandparent)
606child=setmetatable({},parent)
606child=setmetatable({},parent)
607−child.foo=10
607+child.foo=0xa
608−assert(T == parent and K == "\u{66}\u{6f}\u{6f}" and V == 10)
608+assert(T == parent and K == "\u{66}\u{6f}\u{6f}" and V == 0xa)
609print("\u{4f}\u{4b}")
609print("\u{4f}\u{4b}")
610−return 12
610+return 0xc
zod/luau/res/lua/cycled/files.lua+169−169
@@ -7,7 +7,7 @@ assert(io.output(io.stdout) == io.stdout)
7local function testerr
7local function testerr
8(msg,f, ...)
8(msg,f, ...)
9local stat,err = pcall(f,...)
9local stat,err = pcall(f,...)
10−return (not stat and string.find(err,msg,1,true))
10+return (not stat and string.find(err,msg,0x1,true))
11end
11end
12local function checkerr
12local function checkerr
13(msg,f, ...)
13(msg,f, ...)
@@ -17,7 +17,7 @@ assert(not io.close(io.stdin) and not io.stdout:close() and not io.stderr:close(
17checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{6f}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}",io.stdin.close)
17checkerr("\u{67}\u{6f}\u{74}\u{20}\u{6e}\u{6f}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}",io.stdin.close)
18assert(type(io.input()) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}" and io.type(io.output()) == "\u{66}\u{69}\u{6c}\u{65}")
18assert(type(io.input()) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}" and io.type(io.output()) == "\u{66}\u{69}\u{6c}\u{65}")
19assert(type(io.stdin) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}" and io.type(io.stderr) == "\u{66}\u{69}\u{6c}\u{65}")
19assert(type(io.stdin) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}" and io.type(io.stderr) == "\u{66}\u{69}\u{6c}\u{65}")
20−assert(not io.type(8))
20+assert(not io.type(0x8))
21local a = {}
21local a = {}
22;
22;
23setmetatable(a,{})
23setmetatable(a,{})
@@ -56,15 +56,15 @@ assert(not io.open(file))
56io.output(file)
56io.output(file)
57assert(io.output() ~= io.stdout)
57assert(io.output() ~= io.stdout)
58if not _port then
58if not _port then
59−local status,msg,code = io.stdin:seek("\u{73}\u{65}\u{74}",1000)
59+local status,msg,code = io.stdin:seek("\u{73}\u{65}\u{74}",0x3e8)
60assert(not status and type(msg) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(code) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}")
60assert(not status and type(msg) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(code) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}")
61end
61end
62−assert(io.output():seek() == 0)
62+assert(io.output():seek() == 0x0)
63assert(io.write("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}"):seek() == string.len("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}"))
63assert(io.write("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}"):seek() == string.len("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}"))
64−assert(io.output():seek("\u{63}\u{75}\u{72}",- 3) == string.len("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}") - 3)
64+assert(io.output():seek("\u{63}\u{75}\u{72}",- 0x3) == string.len("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}") - 0x3)
65assert(io.write("\u{6a}\u{6f}\u{61}\u{6f}"))
65assert(io.write("\u{6a}\u{6f}\u{61}\u{6f}"))
66assert(io.output():seek("\u{65}\u{6e}\u{64}") == string.len("\u{61}\u{6c}\u{6f}\u{20}\u{6a}\u{6f}\u{61}\u{6f}"))
66assert(io.output():seek("\u{65}\u{6e}\u{64}") == string.len("\u{61}\u{6c}\u{6f}\u{20}\u{6a}\u{6f}\u{61}\u{6f}"))
67−assert(io.output():seek("\u{73}\u{65}\u{74}") == 0)
67+assert(io.output():seek("\u{73}\u{65}\u{74}") == 0x0)
68assert(io.write("\u{22}\u{61}\u{6c}\u{6f}\u{22}","\u{7b}\u{61}\u{7d}\u{a}","\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}","\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{a}"))
68assert(io.write("\u{22}\u{61}\u{6c}\u{6f}\u{22}","\u{7b}\u{61}\u{7d}\u{a}","\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}","\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{a}"))
69assert(io.write("\u{58}\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}"))
69assert(io.write("\u{58}\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}"))
70io.output(io.stdout)
70io.output(io.stdout)
@@ -72,9 +72,9 @@ collectgarbage()
72assert(io.input() == io.stdin and rawequal(io.output(),io.stdout))
72assert(io.input() == io.stdin and rawequal(io.output(),io.stdout))
73print("\u{2b}")
73print("\u{2b}")
74collectgarbage()
74collectgarbage()
75−for i = 1, 120
75+for i = 0x1, 0x78
76do
76do
77−for i = 1, 5
77+for i = 0x1, 0x5
78do
78do
79io.input(file)
79io.input(file)
80assert(io.open(file,"\u{72}"))
80assert(io.open(file,"\u{72}"))
@@ -87,7 +87,7 @@ io.close()
87assert(os.rename(file,otherfile))
87assert(os.rename(file,otherfile))
88assert(not os.rename(file,otherfile))
88assert(not os.rename(file,otherfile))
89io.output(io.open(otherfile,"\u{61}\u{62}"))
89io.output(io.open(otherfile,"\u{61}\u{62}"))
90−assert(io.write("\u{a}\u{a}\u{9}\u{9}\u{20}\u{20}",3450,"\u{a}"))
90+assert(io.write("\u{a}\u{a}\u{9}\u{9}\u{20}\u{20}",0xd7a,"\u{a}"))
91;
91;
92io.close()
92io.close()
93do
93do
@@ -104,7 +104,7 @@ local f <close> = assert(io.open(file,"\u{77}"))
104f:write(maxint,"\u{a}")
104f:write(maxint,"\u{a}")
105f:write(string.format("\u{30}\u{58}\u{25}\u{78}\u{a}",maxint))
105f:write(string.format("\u{30}\u{58}\u{25}\u{78}\u{a}",maxint))
106f:write("\u{30}\u{78}\u{41}\u{42}\u{43}\u{70}\u{2d}\u{33}","\u{a}")
106f:write("\u{30}\u{78}\u{41}\u{42}\u{43}\u{70}\u{2d}\u{33}","\u{a}")
107−f:write(0,"\u{a}")
107+f:write(0x0,"\u{a}")
108f:write(- maxint,"\u{a}")
108f:write(- maxint,"\u{a}")
109f:write(string.format("\u{30}\u{78}\u{25}\u{58}\u{a}",- maxint))
109f:write(string.format("\u{30}\u{78}\u{25}\u{58}\u{a}",- maxint))
110f:write("\u{2d}\u{30}\u{78}\u{41}\u{42}\u{43}\u{70}\u{2d}\u{33}","\u{a}")
110f:write("\u{2d}\u{30}\u{78}\u{41}\u{42}\u{43}\u{70}\u{2d}\u{33}","\u{a}")
@@ -113,7 +113,7 @@ local f <close> = assert(io.open(file,"\u{72}"))
113assert(f:read("\u{6e}") == maxint)
113assert(f:read("\u{6e}") == maxint)
114assert(f:read("\u{6e}") == maxint)
114assert(f:read("\u{6e}") == maxint)
115assert(f:read("\u{6e}") == 343.5)
115assert(f:read("\u{6e}") == 343.5)
116−assert(f:read("\u{6e}") == 0)
116+assert(f:read("\u{6e}") == 0x0)
117assert(f:read("\u{2a}\u{6e}") == - maxint)
117assert(f:read("\u{2a}\u{6e}") == - maxint)
118assert(f:read("\u{6e}") == - maxint)
118assert(f:read("\u{6e}") == - maxint)
119assert(f:read("\u{2a}\u{6e}") == - 343.5)
119assert(f:read("\u{2a}\u{6e}") == - 343.5)
@@ -126,11 +126,11 @@ local l1,l2,l3,l4,n1,n2,c,dummy
126assert(f:close())
126assert(f:close())
127local f <close> = assert(io.open(file,"\u{72}"))
127local f <close> = assert(io.open(file,"\u{72}"))
128l1,l2,n1,n2,dummy=f:read("\u{6c}","\u{4c}","\u{6e}","\u{6e}")
128l1,l2,n1,n2,dummy=f:read("\u{6c}","\u{4c}","\u{6e}","\u{6e}")
129−assert(l1 == "\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}" and l2 == "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}" and n1 == 1234 and n2 == 3.45 and dummy == nil)
129+assert(l1 == "\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}" and l2 == "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}" and n1 == 0x4d2 and n2 == 3.45 and dummy == nil)
130assert(f:close())
130assert(f:close())
131local f <close> = assert(io.open(file,"\u{72}"))
131local f <close> = assert(io.open(file,"\u{72}"))
132−l1,l2,n1,n2,c,l3,l4,dummy=f:read(7,"\u{6c}","\u{6e}","\u{6e}",1,"\u{6c}","\u{6c}")
132+l1,l2,n1,n2,c,l3,l4,dummy=f:read(0x7,"\u{6c}","\u{6e}","\u{6e}",0x1,"\u{6c}","\u{6c}")
133−assert(l1 == "\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}" and l2 == "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6c}\u{69}\u{6e}\u{65}" and c == "\u{a}" and n1 == 1234 and n2 == 3.45 and l3 == "\u{6f}\u{6e}\u{65}" and l4 == "\u{74}\u{77}\u{6f}" and dummy == nil)
133+assert(l1 == "\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}" and l2 == "\u{61}\u{6e}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{6c}\u{69}\u{6e}\u{65}" and c == "\u{a}" and n1 == 0x4d2 and n2 == 3.45 and l3 == "\u{6f}\u{6e}\u{65}" and l4 == "\u{74}\u{77}\u{6f}" and dummy == nil)
134assert(f:close())
134assert(f:close())
135local f <close> = assert(io.open(file,"\u{72}"))
135local f <close> = assert(io.open(file,"\u{72}"))
136l1,n1,n2,dummy=f:read("\u{6c}","\u{6e}","\u{6e}","\u{6c}")
136l1,n1,n2,dummy=f:read("\u{6c}","\u{6e}","\u{6e}","\u{6c}")
@@ -141,15 +141,15 @@ f=assert(io.open(file,"\u{77}"))
141f:write("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{2c}\u{20}\u{7a}\u{20}\u{3d}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{31}\u{30}\u{29}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{79}\u{20}\u{3d}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{32}\u{30}\u{29}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{20}\u{2b}\u{20}\u{79}\u{20}\u{2a}\u{20}\u{7a}\u{a}")
141f:write("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{2c}\u{20}\u{7a}\u{20}\u{3d}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{31}\u{30}\u{29}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{79}\u{20}\u{3d}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{2e}\u{79}\u{69}\u{65}\u{6c}\u{64}\u{28}\u{32}\u{30}\u{29}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{78}\u{20}\u{2b}\u{20}\u{79}\u{20}\u{2a}\u{20}\u{7a}\u{a}")
142assert(f:close())
142assert(f:close())
143f=coroutine.wrap(dofile)
143f=coroutine.wrap(dofile)
144−assert(f(file) == 10)
144+assert(f(file) == 0xa)
145−assert(f(100,101) == 20)
145+assert(f(0x64,0x65) == 0x14)
146−assert(f(200) == 100 + 200 * 101)
146+assert(f(0xc8) == 0x64 + 0xc8 * 0x65)
147assert(os.remove(file))
147assert(os.remove(file))
148f=assert(io.open(file,"\u{77}"))
148f=assert(io.open(file,"\u{77}"))
149f:write("\u{2d}\u{31}\u{32}\u{2e}\u{33}\u{2d}\u{9}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{2b}\u{20}\u{20}\u{2e}\u{33}\u{7c}\u{35}\u{2e}\u{45}\u{2d}\u{33}\u{58}\u{20}\u{20}\u{2b}\u{32}\u{33}\u{34}\u{65}\u{2b}\u{31}\u{33}\u{45}\u{20}\u{30}\u{78}\u{44}\u{45}\u{41}\u{44}\u{42}\u{45}\u{45}\u{46}\u{44}\u{45}\u{41}\u{44}\u{42}\u{45}\u{45}\u{46}\u{78}\u{a}\u{30}\u{78}\u{31}\u{2e}\u{31}\u{33}\u{41}\u{70}\u{2b}\u{33}\u{65}\u{a}")
149f:write("\u{2d}\u{31}\u{32}\u{2e}\u{33}\u{2d}\u{9}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{2b}\u{20}\u{20}\u{2e}\u{33}\u{7c}\u{35}\u{2e}\u{45}\u{2d}\u{33}\u{58}\u{20}\u{20}\u{2b}\u{32}\u{33}\u{34}\u{65}\u{2b}\u{31}\u{33}\u{45}\u{20}\u{30}\u{78}\u{44}\u{45}\u{41}\u{44}\u{42}\u{45}\u{45}\u{46}\u{44}\u{45}\u{41}\u{44}\u{42}\u{45}\u{45}\u{46}\u{78}\u{a}\u{30}\u{78}\u{31}\u{2e}\u{31}\u{33}\u{41}\u{70}\u{2b}\u{33}\u{65}\u{a}")
150f:write("\u{31}\u{32}\u{33}\u{34}")
150f:write("\u{31}\u{32}\u{33}\u{34}")
151;
151;
152−for i = 1, 1000
152+for i = 0x1, 0x3e8
153do
153do
154f:write("\u{30}")
154f:write("\u{30}")
155end
155end
@@ -160,25 +160,25 @@ assert(f:close())
160f=assert(io.open(file,"\u{72}"))
160f=assert(io.open(file,"\u{72}"))
161assert(f:read("\u{6e}") == - 12.3)
161assert(f:read("\u{6e}") == - 12.3)
162;
162;
163−assert(f:read(1) == "\u{2d}")
163+assert(f:read(0x1) == "\u{2d}")
164−assert(f:read("\u{6e}") == - 65535)
164+assert(f:read("\u{6e}") == - 0xffff)
165;
165;
166−assert(f:read(2) == "\u{2b}\u{20}")
166+assert(f:read(0x2) == "\u{2b}\u{20}")
167assert(f:read("\u{6e}") == 0.3)
167assert(f:read("\u{6e}") == 0.3)
168;
168;
169−assert(f:read(1) == "\u{7c}")
169+assert(f:read(0x1) == "\u{7c}")
170assert(f:read("\u{6e}") == 5e-3)
170assert(f:read("\u{6e}") == 5e-3)
171;
171;
172−assert(f:read(1) == "\u{58}")
172+assert(f:read(0x1) == "\u{58}")
173assert(f:read("\u{6e}") == 2.34e15)
173assert(f:read("\u{6e}") == 2.34e15)
174;
174;
175−assert(f:read(1) == "\u{45}")
175+assert(f:read(0x1) == "\u{45}")
176−assert(f:read("\u{6e}") == 16045690984833335023)
176+assert(f:read("\u{6e}") == 0xdeadbeefdeadbeef)
177;
177;
178−assert(f:read(2) == "\u{78}\u{a}")
178+assert(f:read(0x2) == "\u{78}\u{a}")
179assert(f:read("\u{6e}") == 8.61328125)
179assert(f:read("\u{6e}") == 8.61328125)
180;
180;
181−assert(f:read(1) == "\u{65}")
181+assert(f:read(0x1) == "\u{65}")
182do
182do
183assert(not f:read("\u{6e}"))
183assert(not f:read("\u{6e}"))
184local s = f:read("\u{4c}")
184local s = f:read("\u{4c}")
@@ -186,91 +186,91 @@ assert(string.find(s,"\u{5e}\u{30}\u{30}\u{2a}\u{a}\u{24}"))
186end
186end
187assert(not f:read("\u{6e}"))
187assert(not f:read("\u{6e}"))
188;
188;
189−assert(f:read(2) == "\u{65}\u{2b}")
189+assert(f:read(0x2) == "\u{65}\u{2b}")
190assert(not f:read("\u{6e}"))
190assert(not f:read("\u{6e}"))
191;
191;
192−assert(f:read(1) == "\u{3b}")
192+assert(f:read(0x1) == "\u{3b}")
193assert(not f:read("\u{6e}"))
193assert(not f:read("\u{6e}"))
194;
194;
195−assert(f:read(2) == "\u{2d}\u{3b}")
195+assert(f:read(0x2) == "\u{2d}\u{3b}")
196assert(not f:read("\u{6e}"))
196assert(not f:read("\u{6e}"))
197;
197;
198−assert(f:read(1) == "\u{58}")
198+assert(f:read(0x1) == "\u{58}")
199assert(not f:read("\u{6e}"))
199assert(not f:read("\u{6e}"))
200;
200;
201−assert(f:read(1) == "\u{3b}")
201+assert(f:read(0x1) == "\u{3b}")
202assert(not f:read("\u{6e}"))
202assert(not f:read("\u{6e}"))
203;
203;
204−assert(not f:read(0))
204+assert(not f:read(0x0))
205assert(f:close())
205assert(f:close())
206assert(os.remove(file))
206assert(os.remove(file))
207assert(not pcall(io.lines,"\u{6e}\u{6f}\u{6e}\u{2d}\u{65}\u{78}\u{69}\u{73}\u{74}\u{65}\u{6e}\u{74}\u{2d}\u{66}\u{69}\u{6c}\u{65}"))
207assert(not pcall(io.lines,"\u{6e}\u{6f}\u{6e}\u{2d}\u{65}\u{78}\u{69}\u{73}\u{74}\u{65}\u{6e}\u{74}\u{2d}\u{66}\u{69}\u{6c}\u{65}"))
208assert(os.rename(otherfile,file))
208assert(os.rename(otherfile,file))
209io.output(otherfile)
209io.output(otherfile)
210−local n = 0
210+local n = 0x0
211local f = io.lines(file)
211local f = io.lines(file)
212while f() do
212while f() do
213−n=n + 1
213+n=n + 0x1
214end
214end
215;
215;
216−assert(n == 6)
216+assert(n == 0x6)
217checkerr("\u{66}\u{69}\u{6c}\u{65}\u{20}\u{69}\u{73}\u{20}\u{61}\u{6c}\u{72}\u{65}\u{61}\u{64}\u{79}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}",f)
217checkerr("\u{66}\u{69}\u{6c}\u{65}\u{20}\u{69}\u{73}\u{20}\u{61}\u{6c}\u{72}\u{65}\u{61}\u{64}\u{79}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}",f)
218checkerr("\u{66}\u{69}\u{6c}\u{65}\u{20}\u{69}\u{73}\u{20}\u{61}\u{6c}\u{72}\u{65}\u{61}\u{64}\u{79}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}",f)
218checkerr("\u{66}\u{69}\u{6c}\u{65}\u{20}\u{69}\u{73}\u{20}\u{61}\u{6c}\u{72}\u{65}\u{61}\u{64}\u{79}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}",f)
219−n=0
219+n=0x0
220for l in io.lines(file)
220for l in io.lines(file)
221do
221do
222io.write(l,"\u{a}")
222io.write(l,"\u{a}")
223;
223;
224−n=n + 1
224+n=n + 0x1
225end
225end
226io.close()
226io.close()
227−assert(n == 6)
227+assert(n == 0x6)
228local f = assert(io.open(otherfile))
228local f = assert(io.open(otherfile))
229assert(io.type(f) == "\u{66}\u{69}\u{6c}\u{65}")
229assert(io.type(f) == "\u{66}\u{69}\u{6c}\u{65}")
230io.output(file)
230io.output(file)
231assert(not io.output():read())
231assert(not io.output():read())
232−n=0
232+n=0x0
233for l in f:lines()
233for l in f:lines()
234do
234do
235io.write(l,"\u{a}")
235io.write(l,"\u{a}")
236;
236;
237−n=n + 1
237+n=n + 0x1
238end
238end
239−assert(tostring(f):sub(1,5) == "\u{66}\u{69}\u{6c}\u{65}\u{20}")
239+assert(tostring(f):sub(0x1,0x5) == "\u{66}\u{69}\u{6c}\u{65}\u{20}")
240assert(f:close())
240assert(f:close())
241;
241;
242io.close()
242io.close()
243−assert(n == 6)
243+assert(n == 0x6)
244checkerr("\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{66}\u{69}\u{6c}\u{65}",io.close,f)
244checkerr("\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{66}\u{69}\u{6c}\u{65}",io.close,f)
245assert(tostring(f) == "\u{66}\u{69}\u{6c}\u{65}\u{20}\u{28}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{29}")
245assert(tostring(f) == "\u{66}\u{69}\u{6c}\u{65}\u{20}\u{28}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{29}")
246assert(io.type(f) == "\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{66}\u{69}\u{6c}\u{65}")
246assert(io.type(f) == "\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{66}\u{69}\u{6c}\u{65}")
247io.input(file)
247io.input(file)
248f=io.open(otherfile):lines()
248f=io.open(otherfile):lines()
249−n=0
249+n=0x0
250for l in io.lines()
250for l in io.lines()
251do
251do
252assert(l == f())
252assert(l == f())
253;
253;
254−n=n + 1
254+n=n + 0x1
255end
255end
256f=nil
256f=nil
257;
257;
258collectgarbage()
258collectgarbage()
259−assert(n == 6)
259+assert(n == 0x6)
260assert(os.remove(otherfile))
260assert(os.remove(otherfile))
261do
261do
262io.output(otherfile)
262io.output(otherfile)
263−io.write(string.rep("\u{61}",300),"\u{a}")
263+io.write(string.rep("\u{61}",0x12c),"\u{a}")
264io.close()
264io.close()
265local t = {}
265local t = {}
266;
266;
267−for i = 1, 250
267+for i = 0x1, 0xfa
268do
268do
269−t[i]=1
269+t[i]=0x1
270end
270end
271t={io.lines(otherfile,table.unpack(t))()}
271t={io.lines(otherfile,table.unpack(t))()}
272−assert(# t == 250 and t[1] == "\u{61}" and t[# t] == "\u{61}")
272+assert(# t == 0xfa and t[0x1] == "\u{61}" and t[# t] == "\u{61}")
273−t[# t + 1]=1
273+t[# t + 0x1]=0x1
274checkerr("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{73}",io.lines,otherfile,table.unpack(t))
274checkerr("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{73}",io.lines,otherfile,table.unpack(t))
275collectgarbage()
275collectgarbage()
276assert(os.remove(otherfile))
276assert(os.remove(otherfile))
@@ -281,29 +281,29 @@ local a,b,c = io.input():write("\u{78}\u{75}\u{78}\u{75}")
281assert(not a and type(b) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(c) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}")
281assert(not a and type(b) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(c) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}")
282end
282end
283checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",io.read,"\u{78}")
283checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",io.read,"\u{78}")
284−assert(io.read(0) == "")
284+assert(io.read(0x0) == "")
285−assert(io.read(5,"\u{6c}") == "\u{22}\u{61}\u{6c}\u{6f}\u{22}")
285+assert(io.read(0x5,"\u{6c}") == "\u{22}\u{61}\u{6c}\u{6f}\u{22}")
286−assert(io.read(0) == "")
286+assert(io.read(0x0) == "")
287assert(io.read() == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}")
287assert(io.read() == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}")
288local x = io.input():seek()
288local x = io.input():seek()
289assert(io.read() == "\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}")
289assert(io.read() == "\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}")
290assert(io.input():seek("\u{73}\u{65}\u{74}",x))
290assert(io.input():seek("\u{73}\u{65}\u{74}",x))
291assert(io.read("\u{4c}") == "\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{a}")
291assert(io.read("\u{4c}") == "\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{a}")
292−assert(io.read(1) == "\u{58}")
292+assert(io.read(0x1) == "\u{58}")
293assert(io.read(string.len("\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")) == "\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")
293assert(io.read(string.len("\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")) == "\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")
294assert(io.input():seek("\u{63}\u{75}\u{72}",- string.len("\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")))
294assert(io.input():seek("\u{63}\u{75}\u{72}",- string.len("\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")))
295assert(io.read() == "\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")
295assert(io.read() == "\u{66}\u{6f}\u{75}\u{72}\u{74}\u{68}\u{5f}\u{6c}\u{69}\u{6e}\u{65}")
296assert(io.read() == "")
296assert(io.read() == "")
297−assert(io.read("\u{6e}") == 3450)
297+assert(io.read("\u{6e}") == 0xd7a)
298−assert(io.read(1) == "\u{a}")
298+assert(io.read(0x1) == "\u{a}")
299−assert(not io.read(0))
299+assert(not io.read(0x0))
300−assert(not io.read(1))
300+assert(not io.read(0x1))
301−assert(not io.read(30000))
301+assert(not io.read(0x7530))
302−assert(({io.read(1)})[2] == undef)
302+assert(({io.read(0x1)})[0x2] == undef)
303assert(not io.read())
303assert(not io.read())
304−assert(({io.read()})[2] == undef)
304+assert(({io.read()})[0x2] == undef)
305assert(not io.read("\u{6e}"))
305assert(not io.read("\u{6e}"))
306−assert(({io.read("\u{6e}")})[2] == undef)
306+assert(({io.read("\u{6e}")})[0x2] == undef)
307assert(io.read("\u{61}") == "")
307assert(io.read("\u{61}") == "")
308assert(io.read("\u{61}") == "")
308assert(io.read("\u{61}") == "")
309collectgarbage()
309collectgarbage()
@@ -312,12 +312,12 @@ io.close(io.input())
312checkerr("\u{20}\u{69}\u{6e}\u{70}\u{75}\u{74}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{20}\u{69}\u{73}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}",io.read)
312checkerr("\u{20}\u{69}\u{6e}\u{70}\u{75}\u{74}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{20}\u{69}\u{73}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}",io.read)
313assert(os.remove(file))
313assert(os.remove(file))
314local t = "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
314local t = "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
315−for i = 1, 10
315+for i = 0x1, 0xa
316do
316do
317t=t .. t
317t=t .. t
318;
318;
319end
319end
320−assert(string.len(t) == 10 * 2 ^ 10)
320+assert(string.len(t) == 0xa * 0x2 ^ 0xa)
321io.output(file)
321io.output(file)
322io.write("\u{61}\u{6c}\u{6f}"):write("\u{a}")
322io.write("\u{61}\u{6c}\u{6f}"):write("\u{a}")
323io.close()
323io.close()
@@ -334,12 +334,12 @@ f:close()
334print("\u{2b}")
334print("\u{2b}")
335io.input(file)
335io.input(file)
336assert(io.read() == "\u{61}\u{6c}\u{6f}")
336assert(io.read() == "\u{61}\u{6c}\u{6f}")
337−assert(io.read(1) == "\u{20}")
337+assert(io.read(0x1) == "\u{20}")
338assert(io.read(string.len(t)) == t)
338assert(io.read(string.len(t)) == t)
339−assert(io.read(1) == "\u{20}")
339+assert(io.read(0x1) == "\u{20}")
340−assert(io.read(0))
340+assert(io.read(0x0))
341assert(io.read("\u{61}") == "\u{3b}\u{65}\u{6e}\u{64}\u{20}\u{6f}\u{66}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{a}")
341assert(io.read("\u{61}") == "\u{3b}\u{65}\u{6e}\u{64}\u{20}\u{6f}\u{66}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{a}")
342−assert(not io.read(0))
342+assert(not io.read(0x0))
343assert(io.close(io.input()))
343assert(io.close(io.input()))
344do
344do
345local function ismsg
345local function ismsg
@@ -403,18 +403,18 @@ io.output(file)
403io.write("\u{61}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{20}\u{2b}\u{20}\u{33}\u{34}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{32}\u{2a}\u{61}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{2d}\u{61}\u{a}"):close()
403io.write("\u{61}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{20}\u{2b}\u{20}\u{33}\u{34}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{32}\u{2a}\u{61}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{2d}\u{61}\u{a}"):close()
404local t = {}
404local t = {}
405assert(load(io.lines(file,"\u{4c}"),nil,nil,t))()
405assert(load(io.lines(file,"\u{4c}"),nil,nil,t))()
406−assert(t.a == - ((10 + 34) * 2))
406+assert(t.a == - ((0xa + 0x22) * 0x2))
407do
407do
408local function gettoclose
408local function gettoclose
409(lv)
409(lv)
410−lv=lv + 1
410+lv=lv + 0x1
411−local stvar = 0
411+local stvar = 0x0
412−for i = 1, 1000
412+for i = 0x1, 0x3e8
413do
413do
414local n,v = debug.getlocal(lv,i)
414local n,v = debug.getlocal(lv,i)
415if n == "\u{28}\u{66}\u{6f}\u{72}\u{20}\u{73}\u{74}\u{61}\u{74}\u{65}\u{29}" then
415if n == "\u{28}\u{66}\u{6f}\u{72}\u{20}\u{73}\u{74}\u{61}\u{74}\u{65}\u{29}" then
416−stvar=stvar + 1
416+stvar=stvar + 0x1
417−if stvar == 4 then
417+if stvar == 0x4 then
418return v
418return v
419end
419end
420end
420end
@@ -423,7 +423,7 @@ end
423local f
423local f
424for l in io.lines(file)
424for l in io.lines(file)
425do
425do
426−f=gettoclose(1)
426+f=gettoclose(0x1)
427assert(io.type(f) == "\u{66}\u{69}\u{6c}\u{65}")
427assert(io.type(f) == "\u{66}\u{69}\u{6c}\u{65}")
428break
428break
429end
429end
@@ -433,7 +433,7 @@ local function foo
433(name)
433(name)
434for l in io.lines(name)
434for l in io.lines(name)
435do
435do
436−f=gettoclose(1)
436+f=gettoclose(0x1)
437assert(io.type(f) == "\u{66}\u{69}\u{6c}\u{65}")
437assert(io.type(f) == "\u{66}\u{69}\u{6c}\u{65}")
438error(f)
438error(f)
439end
439end
@@ -444,19 +444,19 @@ end
444io.output(file)
444io.output(file)
445;
445;
446io.write("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}"):close()
446io.write("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}"):close()
447−for a,b in io.lines(file,1,1)
447+for a,b in io.lines(file,0x1,0x1)
448do
448do
449if a == "\u{a}" then
449if a == "\u{a}" then
450assert(not b)
450assert(not b)
451else
451else
452−assert(tonumber(a) == tonumber(b) - 1)
452+assert(tonumber(a) == tonumber(b) - 0x1)
453end
453end
454end
454end
455−for a,b,c in io.lines(file,1,2,"\u{61}")
455+for a,b,c in io.lines(file,0x1,0x2,"\u{61}")
456do
456do
457assert(a == "\u{30}" and b == "\u{31}\u{32}" and c == "\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}")
457assert(a == "\u{30}" and b == "\u{31}\u{32}" and c == "\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}")
458end
458end
459−for a,b,c in io.lines(file,"\u{61}",0,1)
459+for a,b,c in io.lines(file,"\u{61}",0x0,0x1)
460do
460do
461if a == "" then
461if a == "" then
462break
462break
@@ -469,24 +469,24 @@ io.output(file)
469io.write("\u{30}\u{30}\u{a}\u{31}\u{30}\u{a}\u{32}\u{30}\u{a}\u{33}\u{30}\u{a}\u{34}\u{30}\u{a}"):close()
469io.write("\u{30}\u{30}\u{a}\u{31}\u{30}\u{a}\u{32}\u{30}\u{a}\u{33}\u{30}\u{a}\u{34}\u{30}\u{a}"):close()
470for a,b in io.lines(file,"\u{6e}","\u{6e}")
470for a,b in io.lines(file,"\u{6e}","\u{6e}")
471do
471do
472−if a == 40 then
472+if a == 0x28 then
473assert(not b)
473assert(not b)
474else
474else
475−assert(a == b - 10)
475+assert(a == b - 0xa)
476end
476end
477end
477end
478io.output(file)
478io.output(file)
479;
479;
480io.write("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{79}\u{a}\u{3d}\u{20}\u{58}\u{a}\u{58}\u{20}\u{3d}\u{a}\u{58}\u{20}\u{2a}\u{a}\u{32}\u{20}\u{2b}\u{a}\u{58}\u{3b}\u{a}\u{58}\u{20}\u{3d}\u{a}\u{58}\u{a}\u{2d}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{3b}\u{a}"):close()
480io.write("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{79}\u{a}\u{3d}\u{20}\u{58}\u{a}\u{58}\u{20}\u{3d}\u{a}\u{58}\u{20}\u{2a}\u{a}\u{32}\u{20}\u{2b}\u{a}\u{58}\u{3b}\u{a}\u{58}\u{20}\u{3d}\u{a}\u{58}\u{a}\u{2d}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{79}\u{3b}\u{a}"):close()
481−_G.X=1
481+_G.X=0x1
482assert(not load((io.lines(file))))
482assert(not load((io.lines(file))))
483collectgarbage()
483collectgarbage()
484load((io.lines(file,"\u{4c}")))()
484load((io.lines(file,"\u{4c}")))()
485−assert(_G.X == 2)
485+assert(_G.X == 0x2)
486−load((io.lines(file,1)))()
486+load((io.lines(file,0x1)))()
487−assert(_G.X == 4)
487+assert(_G.X == 0x4)
488−load((io.lines(file,3)))()
488+load((io.lines(file,0x3)))()
489−assert(_G.X == 8)
489+assert(_G.X == 0x8)
490_G.X=nil
490_G.X=nil
491print("\u{2b}")
491print("\u{2b}")
492local x1 = "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{a}\u{a}\u{5c}\u{63}\u{6f}\u{6d}\u{20}\u{22}\u{22}\u{27}\u{27}\u{63}\u{6f}\u{69}\u{73}\u{61}\u{73}\u{20}\u{5b}\u{5b}\u{65}\u{73}\u{74}\u{72}\u{61}\u{6e}\u{68}\u{61}\u{73}\u{5d}\u{5d}\u{20}\u{5d}\u{5d}\u{27}"
492local x1 = "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{a}\u{a}\u{5c}\u{63}\u{6f}\u{6d}\u{20}\u{22}\u{22}\u{27}\u{27}\u{63}\u{6f}\u{69}\u{73}\u{61}\u{73}\u{20}\u{5b}\u{5b}\u{65}\u{73}\u{74}\u{72}\u{61}\u{6e}\u{68}\u{61}\u{73}\u{5d}\u{5d}\u{20}\u{5d}\u{5d}\u{27}"
@@ -513,44 +513,44 @@ assert(res == expres)
513end
513end
514testloadfile(nil,nil)
514testloadfile(nil,nil)
515testloadfile("\u{23}\u{20}\u{61}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{65}\u{6e}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}",nil)
515testloadfile("\u{23}\u{20}\u{61}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{65}\u{6e}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}",nil)
516−testloadfile("\u{ef}\u{bb}\u{bf}\u{23}\u{20}\u{73}\u{6f}\u{6d}\u{65}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{33}\u{34}",234)
516+testloadfile("\u{ef}\u{bb}\u{bf}\u{23}\u{20}\u{73}\u{6f}\u{6d}\u{65}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{33}\u{34}",0xea)
517−testloadfile("\u{ef}\u{bb}\u{bf}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{33}\u{39}",239)
517+testloadfile("\u{ef}\u{bb}\u{bf}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{33}\u{39}",0xef)
518testloadfile("\u{ef}\u{bb}\u{bf}",nil)
518testloadfile("\u{ef}\u{bb}\u{bf}",nil)
519−testloadfile("\u{23}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{27}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{31}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}",2)
519+testloadfile("\u{23}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{27}\u{64}\u{65}\u{62}\u{75}\u{67}\u{27}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{31}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}",0x2)
520io.output(io.open(file,"\u{77}\u{62}"))
520io.output(io.open(file,"\u{77}\u{62}"))
521assert(io.write(string.dump(function ()
521assert(io.write(string.dump(function ()
522−return 10,"\u{0}\u{61}\u{6c}\u{6f}\u{ff}","\u{68}\u{69}"
522+return 0xa,"\u{0}\u{61}\u{6c}\u{6f}\u{ff}","\u{68}\u{69}"
523end)))
523end)))
524io.close()
524io.close()
525a,b,c=assert(loadfile(file))()
525a,b,c=assert(loadfile(file))()
526−assert(a == 10 and b == "\u{0}\u{61}\u{6c}\u{6f}\u{ff}" and c == "\u{68}\u{69}")
526+assert(a == 0xa and b == "\u{0}\u{61}\u{6c}\u{6f}\u{ff}" and c == "\u{68}\u{69}")
527assert(os.remove(file))
527assert(os.remove(file))
528do
528do
529io.output(io.open(file,"\u{77}\u{62}"))
529io.output(io.open(file,"\u{77}\u{62}"))
530assert(io.write(string.dump(function ()
530assert(io.write(string.dump(function ()
531−return 1
531+return 0x1
532end)))
532end)))
533io.close()
533io.close()
534f=assert(loadfile(file,"\u{62}",{}))
534f=assert(loadfile(file,"\u{62}",{}))
535−assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and f() == 1)
535+assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and f() == 0x1)
536assert(os.remove(file))
536assert(os.remove(file))
537end
537end
538io.output(io.open(file,"\u{77}\u{62}"))
538io.output(io.open(file,"\u{77}\u{62}"))
539assert(io.write("\u{23}\u{74}\u{68}\u{69}\u{73}\u{20}\u{69}\u{73}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{61}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{0}\u{a}",string.dump(function ()
539assert(io.write("\u{23}\u{74}\u{68}\u{69}\u{73}\u{20}\u{69}\u{73}\u{20}\u{61}\u{20}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{61}\u{20}\u{62}\u{69}\u{6e}\u{61}\u{72}\u{79}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{0}\u{a}",string.dump(function ()
540−return 20,"\u{0}\u{0}\u{0}"
540+return 0x14,"\u{0}\u{0}\u{0}"
541end)))
541end)))
542io.close()
542io.close()
543a,b,c=assert(loadfile(file))()
543a,b,c=assert(loadfile(file))()
544−assert(a == 20 and b == "\u{0}\u{0}\u{0}" and c == nil)
544+assert(a == 0x14 and b == "\u{0}\u{0}\u{0}" and c == nil)
545assert(os.remove(file))
545assert(os.remove(file))
546do
546do
547local f = io.open(file,"\u{77}")
547local f = io.open(file,"\u{77}")
548f:write("\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{28}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{62}\u{2c}\u{20}\u{63}\u{2c}\u{20}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6c}\u{73}\u{65}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{45}\u{4e}\u{56}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}")
548f:write("\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{28}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{35}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{62}\u{2c}\u{20}\u{63}\u{2c}\u{20}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6c}\u{73}\u{65}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{5f}\u{45}\u{4e}\u{56}\u{a}\u{20}\u{20}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}")
549f:close()
549f:close()
550−local t = {["\u{62}"] = 12,["\u{63}"] = "\u{78}\u{75}\u{78}\u{75}",["\u{64}"] = print}
550+local t = {["\u{62}"] = 0xc,["\u{63}"] = "\u{78}\u{75}\u{78}\u{75}",["\u{64}"] = print}
551local f = assert(loadfile(file,"\u{74}",t))
551local f = assert(loadfile(file,"\u{74}",t))
552−local b,c,d = f(1)
552+local b,c,d = f(0x1)
553−assert(t.a == 15 and b == 12 and c == t.c and d == print)
553+assert(t.a == 0xf and b == 0xc and c == t.c and d == print)
554assert(f() == t)
554assert(f() == t)
555f=assert(loadfile(file,"\u{74}",nil))
555f=assert(loadfile(file,"\u{74}",nil))
556assert(f() == nil)
556assert(f() == nil)
@@ -584,12 +584,12 @@ filehandle:close()
584;
584;
585assert(type(filehandle) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}")
585assert(type(filehandle) == "\u{75}\u{73}\u{65}\u{72}\u{64}\u{61}\u{74}\u{61}")
586io.input(otherfilehandle)
586io.input(otherfilehandle)
587−assert(io.read(4) == "\u{0}\u{1}\u{3}\u{0}")
587+assert(io.read(0x4) == "\u{0}\u{1}\u{3}\u{0}")
588−assert(io.read(3) == "\u{0}\u{0}\u{0}")
588+assert(io.read(0x3) == "\u{0}\u{0}\u{0}")
589−assert(io.read(0) == "")
589+assert(io.read(0x0) == "")
590−assert(io.read(1) == "\u{ff}")
590+assert(io.read(0x1) == "\u{ff}")
591assert(io.read("\u{61}") == "\u{0}")
591assert(io.read("\u{61}") == "\u{0}")
592−assert(not io.read(0))
592+assert(not io.read(0x0))
593assert(otherfilehandle == io.input())
593assert(otherfilehandle == io.input())
594otherfilehandle:close()
594otherfilehandle:close()
595assert(os.remove(file))
595assert(os.remove(file))
@@ -597,7 +597,7 @@ assert(os.remove(otherfile))
597collectgarbage()
597collectgarbage()
598io.output(file):write("\u{20}\u{31}\u{32}\u{33}\u{2e}\u{34}\u{9}\u{2d}\u{35}\u{36}\u{65}\u{2d}\u{32}\u{20}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{a}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}\u{a}\u{61}\u{6e}\u{64}\u{20}\u{74}\u{68}\u{65}\u{20}\u{72}\u{65}\u{73}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{74}\u{68}\u{65}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{a}"):close()
598io.output(file):write("\u{20}\u{31}\u{32}\u{33}\u{2e}\u{34}\u{9}\u{2d}\u{35}\u{36}\u{65}\u{2d}\u{32}\u{20}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{a}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}\u{74}\u{68}\u{69}\u{72}\u{64}\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{a}\u{a}\u{61}\u{6e}\u{64}\u{20}\u{74}\u{68}\u{65}\u{20}\u{72}\u{65}\u{73}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{74}\u{68}\u{65}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{a}"):close()
599io.input(file)
599io.input(file)
600−local _,a,b,c,d,e,h,__ = io.read(1,"\u{6e}","\u{6e}","\u{6c}","\u{6c}","\u{6c}","\u{61}",10)
600+local _,a,b,c,d,e,h,__ = io.read(0x1,"\u{6e}","\u{6e}","\u{6c}","\u{6c}","\u{6c}","\u{61}",0xa)
601assert(io.close(io.input()))
601assert(io.close(io.input()))
602assert(_ == "\u{20}" and not __)
602assert(_ == "\u{20}" and not __)
603assert(type(a) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and a == 123.4 and b == - 0.56)
603assert(type(a) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" and a == 123.4 and b == - 0.56)
@@ -608,7 +608,7 @@ collectgarbage()
608do
608do
609local f = assert(io.open(file,"\u{77}"))
609local f = assert(io.open(file,"\u{77}"))
610local fr = assert(io.open(file,"\u{72}"))
610local fr = assert(io.open(file,"\u{72}"))
611−assert(f:setvbuf("\u{66}\u{75}\u{6c}\u{6c}",2000))
611+assert(f:setvbuf("\u{66}\u{75}\u{6c}\u{6c}",0x7d0))
612f:write("\u{78}")
612f:write("\u{78}")
613assert(fr:read("\u{61}\u{6c}\u{6c}") == "")
613assert(fr:read("\u{61}\u{6c}\u{6c}") == "")
614f:close()
614f:close()
@@ -623,9 +623,9 @@ f:close()
623f=assert(io.open(file,"\u{61}"))
623f=assert(io.open(file,"\u{61}"))
624assert(f:setvbuf("\u{6c}\u{69}\u{6e}\u{65}"))
624assert(f:setvbuf("\u{6c}\u{69}\u{6e}\u{65}"))
625f:write("\u{78}")
625f:write("\u{78}")
626−fr:seek("\u{73}\u{65}\u{74}",1)
626+fr:seek("\u{73}\u{65}\u{74}",0x1)
627assert(fr:read("\u{61}\u{6c}\u{6c}") == "")
627assert(fr:read("\u{61}\u{6c}\u{6c}") == "")
628−f:write("\u{61}\u{a}"):seek("\u{73}\u{65}\u{74}",1)
628+f:write("\u{61}\u{a}"):seek("\u{73}\u{65}\u{74}",0x1)
629assert(fr:read("\u{61}\u{6c}\u{6c}") == "\u{78}\u{61}\u{a}")
629assert(fr:read("\u{61}\u{6c}\u{6c}") == "\u{78}\u{61}\u{a}")
630f:close()
630f:close()
631;
631;
@@ -635,17 +635,17 @@ end
635if not _soft then
635if not _soft then
636print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{73}\u{20}\u{28}\u{3e}\u{20}\u{42}\u{55}\u{46}\u{53}\u{49}\u{5a}\u{29}")
636print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{73}\u{20}\u{28}\u{3e}\u{20}\u{42}\u{55}\u{46}\u{53}\u{49}\u{5a}\u{29}")
637io.output(file)
637io.output(file)
638−for i = 1, 5001
638+for i = 0x1, 0x1389
639do
639do
640io.write("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}")
640io.write("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}")
641end
641end
642io.write("\u{a}\u{31}\u{32}\u{33}\u{34}\u{36}"):close()
642io.write("\u{a}\u{31}\u{32}\u{33}\u{34}\u{36}"):close()
643io.input(file)
643io.input(file)
644local x = io.read("\u{61}")
644local x = io.read("\u{61}")
645−io.input():seek("\u{73}\u{65}\u{74}",0)
645+io.input():seek("\u{73}\u{65}\u{74}",0x0)
646−local y = io.read(30001) .. io.read(1005) .. io.read(0) .. io.read(1) .. io.read(100003)
646+local y = io.read(0x7531) .. io.read(0x3ed) .. io.read(0x0) .. io.read(0x1) .. io.read(0x186a3)
647−assert(x == y and string.len(x) == 5001 * 13 + 6)
647+assert(x == y and string.len(x) == 0x1389 * 0xd + 0x6)
648−io.input():seek("\u{73}\u{65}\u{74}",0)
648+io.input():seek("\u{73}\u{65}\u{74}",0x0)
649y=io.read()
649y=io.read()
650assert(x == y .. "\u{a}" .. io.read())
650assert(x == y .. "\u{a}" .. io.read())
651assert(not io.read())
651assert(not io.read())
@@ -659,11 +659,11 @@ if not _port then
659local progname
659local progname
660do
660do
661local arg = arg or ARG
661local arg = arg or ARG
662−local i = 0
662+local i = 0x0
663while arg[i] do
663while arg[i] do
664−i=i - 1
664+i=i - 0x1
665end
665end
666−progname="\u{22}" .. arg[i + 1] .. "\u{22}"
666+progname="\u{22}" .. arg[i + 0x1] .. "\u{22}"
667end
667end
668print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{6f}\u{70}\u{65}\u{6e}\u{2f}\u{70}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{65}\u{78}\u{65}\u{63}\u{75}\u{74}\u{65}")
668print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{6f}\u{70}\u{65}\u{6e}\u{2f}\u{70}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{65}\u{78}\u{65}\u{63}\u{75}\u{74}\u{65}")
669checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6d}\u{6f}\u{64}\u{65}",io.popen,"\u{63}\u{61}\u{74}","")
669checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6d}\u{6f}\u{64}\u{65}",io.popen,"\u{63}\u{61}\u{74}","")
@@ -679,18 +679,18 @@ assert(f:read("\u{61}") == "\u{61}\u{20}\u{6c}\u{69}\u{6e}\u{65}")
679assert(f:close())
679assert(f:close())
680assert(os.remove(file))
680assert(os.remove(file))
681end
681end
682−local tests = {{"\u{6c}\u{73}\u{20}\u{3e}\u{20}\u{2f}\u{64}\u{65}\u{76}\u{2f}\u{6e}\u{75}\u{6c}\u{6c}","\u{6f}\u{6b}"},{"\u{6e}\u{6f}\u{74}\u{2d}\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{66}\u{6f}\u{75}\u{6e}\u{64}\u{2d}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}","\u{65}\u{78}\u{69}\u{74}"},{"\u{65}\u{78}\u{69}\u{74}\u{20}\u{33}","\u{65}\u{78}\u{69}\u{74}",3},{"\u{65}\u{78}\u{69}\u{74}\u{20}\u{31}\u{32}\u{39}","\u{65}\u{78}\u{69}\u{74}",129},{"\u{6b}\u{69}\u{6c}\u{6c}\u{20}\u{2d}\u{73}\u{20}\u{48}\u{55}\u{50}\u{20}\u{24}\u{24}","\u{73}\u{69}\u{67}\u{6e}\u{61}\u{6c}",1},{"\u{6b}\u{69}\u{6c}\u{6c}\u{20}\u{2d}\u{73}\u{20}\u{4b}\u{49}\u{4c}\u{4c}\u{20}\u{24}\u{24}","\u{73}\u{69}\u{67}\u{6e}\u{61}\u{6c}",9},{"\u{73}\u{68}\u{20}\u{2d}\u{63}\u{20}\u{27}\u{6b}\u{69}\u{6c}\u{6c}\u{20}\u{2d}\u{73}\u{20}\u{48}\u{55}\u{50}\u{20}\u{24}\u{24}\u{27}","\u{65}\u{78}\u{69}\u{74}"},{progname .. "\u{20}\u{2d}\u{65}\u{20}\u{22}\u{20}\u{22}","\u{6f}\u{6b}"},{progname .. "\u{20}\u{2d}\u{65}\u{20}\u{22}\u{6f}\u{73}\u{2e}\u{65}\u{78}\u{69}\u{74}\u{28}\u{30}\u{2c}\u{20}\u{74}\u{72}\u{75}\u{65}\u{29}\u{22}","\u{6f}\u{6b}"},{progname .. "\u{20}\u{2d}\u{65}\u{20}\u{22}\u{6f}\u{73}\u{2e}\u{65}\u{78}\u{69}\u{74}\u{28}\u{32}\u{30}\u{2c}\u{20}\u{74}\u{72}\u{75}\u{65}\u{29}\u{22}","\u{65}\u{78}\u{69}\u{74}",20}}
682+local tests = {{"\u{6c}\u{73}\u{20}\u{3e}\u{20}\u{2f}\u{64}\u{65}\u{76}\u{2f}\u{6e}\u{75}\u{6c}\u{6c}","\u{6f}\u{6b}"},{"\u{6e}\u{6f}\u{74}\u{2d}\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{66}\u{6f}\u{75}\u{6e}\u{64}\u{2d}\u{63}\u{6f}\u{6d}\u{6d}\u{61}\u{6e}\u{64}","\u{65}\u{78}\u{69}\u{74}"},{"\u{65}\u{78}\u{69}\u{74}\u{20}\u{33}","\u{65}\u{78}\u{69}\u{74}",0x3},{"\u{65}\u{78}\u{69}\u{74}\u{20}\u{31}\u{32}\u{39}","\u{65}\u{78}\u{69}\u{74}",0x81},{"\u{6b}\u{69}\u{6c}\u{6c}\u{20}\u{2d}\u{73}\u{20}\u{48}\u{55}\u{50}\u{20}\u{24}\u{24}","\u{73}\u{69}\u{67}\u{6e}\u{61}\u{6c}",0x1},{"\u{6b}\u{69}\u{6c}\u{6c}\u{20}\u{2d}\u{73}\u{20}\u{4b}\u{49}\u{4c}\u{4c}\u{20}\u{24}\u{24}","\u{73}\u{69}\u{67}\u{6e}\u{61}\u{6c}",0x9},{"\u{73}\u{68}\u{20}\u{2d}\u{63}\u{20}\u{27}\u{6b}\u{69}\u{6c}\u{6c}\u{20}\u{2d}\u{73}\u{20}\u{48}\u{55}\u{50}\u{20}\u{24}\u{24}\u{27}","\u{65}\u{78}\u{69}\u{74}"},{progname .. "\u{20}\u{2d}\u{65}\u{20}\u{22}\u{20}\u{22}","\u{6f}\u{6b}"},{progname .. "\u{20}\u{2d}\u{65}\u{20}\u{22}\u{6f}\u{73}\u{2e}\u{65}\u{78}\u{69}\u{74}\u{28}\u{30}\u{2c}\u{20}\u{74}\u{72}\u{75}\u{65}\u{29}\u{22}","\u{6f}\u{6b}"},{progname .. "\u{20}\u{2d}\u{65}\u{20}\u{22}\u{6f}\u{73}\u{2e}\u{65}\u{78}\u{69}\u{74}\u{28}\u{32}\u{30}\u{2c}\u{20}\u{74}\u{72}\u{75}\u{65}\u{29}\u{22}","\u{65}\u{78}\u{69}\u{74}",0x14}}
683print("\u{a}\u{28}\u{73}\u{6f}\u{6d}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{73}\u{20}\u{61}\u{72}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{6e}\u{6f}\u{77}\u{29}")
683print("\u{a}\u{28}\u{73}\u{6f}\u{6d}\u{65}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{6d}\u{65}\u{73}\u{73}\u{61}\u{67}\u{65}\u{73}\u{20}\u{61}\u{72}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{6e}\u{6f}\u{77}\u{29}")
684for _,v in ipairs(tests)
684for _,v in ipairs(tests)
685do
685do
686−local x,y,z = io.popen(v[1]):close()
686+local x,y,z = io.popen(v[0x1]):close()
687−local x1,y1,z1 = os.execute(v[1])
687+local x1,y1,z1 = os.execute(v[0x1])
688assert(x == x1 and y == y1 and z == z1)
688assert(x == x1 and y == y1 and z == z1)
689−if v[2] == "\u{6f}\u{6b}" then
689+if v[0x2] == "\u{6f}\u{6b}" then
690−assert(x and y == "\u{65}\u{78}\u{69}\u{74}" and z == 0)
690+assert(x and y == "\u{65}\u{78}\u{69}\u{74}" and z == 0x0)
691else
691else
692−assert(not x and y == v[2])
692+assert(not x and y == v[0x2])
693−assert((v[3] == nil and z > 0) or v[3] == z)
693+assert((v[0x3] == nil and z > 0x0) or v[0x3] == z)
694end
694end
695end
695end
696end
696end
@@ -706,12 +706,12 @@ assert(os.date("") == "")
706assert(os.date("\u{21}") == "")
706assert(os.date("\u{21}") == "")
707assert(os.date("\u{0}\u{0}") == "\u{0}\u{0}")
707assert(os.date("\u{0}\u{0}") == "\u{0}\u{0}")
708assert(os.date("\u{21}\u{0}\u{0}") == "\u{0}\u{0}")
708assert(os.date("\u{21}\u{0}\u{0}") == "\u{0}\u{0}")
709−local x = string.rep("\u{61}",10000)
709+local x = string.rep("\u{61}",0x2710)
710assert(os.date(x) == x)
710assert(os.date(x) == x)
711local t = os.time()
711local t = os.time()
712D=os.date("\u{2a}\u{74}",t)
712D=os.date("\u{2a}\u{74}",t)
713−assert(os.date(string.rep("\u{25}\u{64}",1000),t) == string.rep(os.date("\u{25}\u{64}",t),1000))
713+assert(os.date(string.rep("\u{25}\u{64}",0x3e8),t) == string.rep(os.date("\u{25}\u{64}",t),0x3e8))
714−assert(os.date(string.rep("\u{25}",200)) == string.rep("\u{25}",100))
714+assert(os.date(string.rep("\u{25}",0xc8)) == string.rep("\u{25}",0x64))
715local function checkDateTable
715local function checkDateTable
716(t)
716(t)
717_G.D=os.date("\u{2a}\u{74}",t)
717_G.D=os.date("\u{2a}\u{74}",t)
@@ -721,11 +721,11 @@ _G.D=nil
721end
721end
722checkDateTable(os.time())
722checkDateTable(os.time())
723if not _port then
723if not _port then
724−checkDateTable(0)
724+checkDateTable(0x0)
725−checkDateTable(1)
725+checkDateTable(0x1)
726−checkDateTable(1000)
726+checkDateTable(0x3e8)
727−checkDateTable(2147483647)
727+checkDateTable(0x7fffffff)
728−checkDateTable(2147483648)
728+checkDateTable(0x80000000)
729end
729end
730checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}")
730checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}")
731checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{39}")
731checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{39}")
@@ -733,44 +733,44 @@ checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{7
733checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{4f}")
733checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{4f}")
734checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{45}")
734checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{45}")
735checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{45}\u{61}")
735checkerr("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}\u{20}\u{73}\u{70}\u{65}\u{63}\u{69}\u{66}\u{69}\u{65}\u{72}",os.date,"\u{25}\u{45}\u{61}")
736−checkerr("\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{6e}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 1000,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1,["\u{68}\u{6f}\u{75}\u{72}"] = "\u{78}"})
736+checkerr("\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{6e}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0x3e8,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1,["\u{68}\u{6f}\u{75}\u{72}"] = "\u{78}"})
737−checkerr("\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{6e}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 1000,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1,["\u{68}\u{6f}\u{75}\u{72}"] = 1.5})
737+checkerr("\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{6e}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0x3e8,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1,["\u{68}\u{6f}\u{75}\u{72}"] = 1.5})
738−checkerr("\u{6d}\u{69}\u{73}\u{73}\u{69}\u{6e}\u{67}",os.time,{["\u{68}\u{6f}\u{75}\u{72}"] = 12})
738+checkerr("\u{6d}\u{69}\u{73}\u{73}\u{69}\u{6e}\u{67}",os.time,{["\u{68}\u{6f}\u{75}\u{72}"] = 0xc})
739−if string.packsize("\u{69}") == 4 then
739+if string.packsize("\u{69}") == 0x4 then
740−checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = - (1 << 31) + 1899,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
740+checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = - (0x1 << 0x1f) + 0x76b,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
741−checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = - (1 << 31),["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
741+checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = - (0x1 << 0x1f),["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
742−if math.maxinteger > 2 ^ 31 then
742+if math.maxinteger > 0x2 ^ 0x1f then
743−checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = (1 << 31) + 1900,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
743+checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = (0x1 << 0x1f) + 0x76c,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
744end
744end
745end
745end
746if not _port then
746if not _port then
747assert(type(os.date("\u{25}\u{45}\u{78}")) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
747assert(type(os.date("\u{25}\u{45}\u{78}")) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
748assert(type(os.date("\u{25}\u{4f}\u{79}")) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
748assert(type(os.date("\u{25}\u{4f}\u{79}")) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
749−local t0 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 1970,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 0})
749+local t0 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 0x7b2,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x0})
750−local t1 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 1970,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 0,["\u{73}\u{65}\u{63}"] = (1 << 31) - 1})
750+local t1 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 0x7b2,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x0,["\u{73}\u{65}\u{63}"] = (0x1 << 0x1f) - 0x1})
751−assert(t1 - t0 == (1 << 31) - 1)
751+assert(t1 - t0 == (0x1 << 0x1f) - 0x1)
752−t0=os.time({["\u{79}\u{65}\u{61}\u{72}"] = 1970,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
752+t0=os.time({["\u{79}\u{65}\u{61}\u{72}"] = 0x7b2,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
753−t1=os.time({["\u{79}\u{65}\u{61}\u{72}"] = 1970,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1,["\u{73}\u{65}\u{63}"] = - (1 << 31)})
753+t1=os.time({["\u{79}\u{65}\u{61}\u{72}"] = 0x7b2,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1,["\u{73}\u{65}\u{63}"] = - (0x1 << 0x1f)})
754−assert(t1 - t0 == - (1 << 31))
754+assert(t1 - t0 == - (0x1 << 0x1f))
755−if maxint >= 2 ^ 62 then
755+if maxint >= 0x2 ^ 0x3e then
756−checkerr("\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = - maxint,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
756+checkerr("\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = - maxint,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
757−if string.packsize("\u{69}") == 4 then
757+if string.packsize("\u{69}") == 0x4 then
758−if testerr("\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.date,"\u{25}\u{59}",2 ^ 40) then
758+if testerr("\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.date,"\u{25}\u{59}",0x2 ^ 0x28) then
759print("\u{20}\u{20}\u{34}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{5f}\u{74}")
759print("\u{20}\u{20}\u{34}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{5f}\u{74}")
760−checkerr("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 4000,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
760+checkerr("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0xfa0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
761else
761else
762print("\u{20}\u{20}\u{38}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{5f}\u{74}")
762print("\u{20}\u{20}\u{38}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{5f}\u{74}")
763−checkerr("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.date,"\u{25}\u{59}",2 ^ 60)
763+checkerr("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.date,"\u{25}\u{59}",0x2 ^ 0x3c)
764−assert(tonumber(os.time({["\u{79}\u{65}\u{61}\u{72}"] = (1 << 31) + 1899,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 12,["\u{64}\u{61}\u{79}"] = 31,["\u{68}\u{6f}\u{75}\u{72}"] = 23,["\u{6d}\u{69}\u{6e}"] = 59,["\u{73}\u{65}\u{63}"] = 59})))
764+assert(tonumber(os.time({["\u{79}\u{65}\u{61}\u{72}"] = (0x1 << 0x1f) + 0x76b,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0xc,["\u{64}\u{61}\u{79}"] = 0x1f,["\u{68}\u{6f}\u{75}\u{72}"] = 0x17,["\u{6d}\u{69}\u{6e}"] = 0x3b,["\u{73}\u{65}\u{63}"] = 0x3b})))
765−checkerr("\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = (1 << 31) + 1899,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 12,["\u{64}\u{61}\u{79}"] = 31,["\u{68}\u{6f}\u{75}\u{72}"] = 23,["\u{6d}\u{69}\u{6e}"] = 59,["\u{73}\u{65}\u{63}"] = 60})
765+checkerr("\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = (0x1 << 0x1f) + 0x76b,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0xc,["\u{64}\u{61}\u{79}"] = 0x1f,["\u{68}\u{6f}\u{75}\u{72}"] = 0x17,["\u{6d}\u{69}\u{6e}"] = 0x3b,["\u{73}\u{65}\u{63}"] = 0x3c})
766end
766end
767−checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{64}\u{61}\u{79}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 2 ^ 32})
767+checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{64}\u{61}\u{79}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0x0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x2 ^ 0x20})
768−checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{6d}\u{6f}\u{6e}\u{74}\u{68}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = - ((1 << 31) + 1),["\u{64}\u{61}\u{79}"] = 1})
768+checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{6d}\u{6f}\u{6e}\u{74}\u{68}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0x0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = - ((0x1 << 0x1f) + 0x1),["\u{64}\u{61}\u{79}"] = 0x1})
769−checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = (1 << 31) + 1900,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
769+checkerr("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{79}\u{65}\u{61}\u{72}\u{27}\u{20}\u{69}\u{73}\u{20}\u{6f}\u{75}\u{74}\u{2d}\u{6f}\u{66}\u{2d}\u{62}\u{6f}\u{75}\u{6e}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = (0x1 << 0x1f) + 0x76c,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
770else
770else
771print("\u{20}\u{20}\u{38}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{5f}\u{74}")
771print("\u{20}\u{20}\u{38}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{74}\u{69}\u{6d}\u{65}\u{5f}\u{74}")
772−assert(tonumber(os.date("\u{25}\u{59}",2 ^ 60)))
772+assert(tonumber(os.date("\u{25}\u{59}",0x2 ^ 0x3c)))
773−checkerr("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 2 ^ 60,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1})
773+checkerr("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{65}\u{64}",os.time,{["\u{79}\u{65}\u{61}\u{72}"] = 0x2 ^ 0x3c,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1})
774end
774end
775end
775end
776end
776end
@@ -788,22 +788,22 @@ assert(t == t1)
788end
788end
789local D = os.date("\u{2a}\u{74}")
789local D = os.date("\u{2a}\u{74}")
790t=os.time(D)
790t=os.time(D)
791−D.year=D.year - 1
791+D.year=D.year - 0x1
792;
792;
793local t1 = os.time(D)
793local t1 = os.time(D)
794−assert(math.abs(os.difftime(t,t1) / (24 * 3600) - 365) < 2)
794+assert(math.abs(os.difftime(t,t1) / (0x18 * 0xe10) - 0x16d) < 0x2)
795t=os.time()
795t=os.time()
796t1=os.time(os.date("\u{2a}\u{74}"))
796t1=os.time(os.date("\u{2a}\u{74}"))
797local diff = os.difftime(t1,t)
797local diff = os.difftime(t1,t)
798−assert(0 <= diff and diff <= 1)
798+assert(0x0 <= diff and diff <= 0x1)
799diff=os.difftime(t,t1)
799diff=os.difftime(t,t1)
800−assert(- 1 <= diff and diff <= 0)
800+assert(- 0x1 <= diff and diff <= 0x0)
801−local t1 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 2000,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 10,["\u{64}\u{61}\u{79}"] = 1,["\u{68}\u{6f}\u{75}\u{72}"] = 23,["\u{6d}\u{69}\u{6e}"] = 12})
801+local t1 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 0x7d0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0xa,["\u{64}\u{61}\u{79}"] = 0x1,["\u{68}\u{6f}\u{75}\u{72}"] = 0x17,["\u{6d}\u{69}\u{6e}"] = 0xc})
802−local t2 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 2000,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 10,["\u{64}\u{61}\u{79}"] = 1,["\u{68}\u{6f}\u{75}\u{72}"] = 23,["\u{6d}\u{69}\u{6e}"] = 10,["\u{73}\u{65}\u{63}"] = 19})
802+local t2 = os.time({["\u{79}\u{65}\u{61}\u{72}"] = 0x7d0,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0xa,["\u{64}\u{61}\u{79}"] = 0x1,["\u{68}\u{6f}\u{75}\u{72}"] = 0x17,["\u{6d}\u{69}\u{6e}"] = 0xa,["\u{73}\u{65}\u{63}"] = 0x13})
803−assert(os.difftime(t1,t2) == 60 * 2 - 19)
803+assert(os.difftime(t1,t2) == 0x3c * 0x2 - 0x13)
804−t1={["\u{79}\u{65}\u{61}\u{72}"] = 2005,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 1,["\u{64}\u{61}\u{79}"] = 1,["\u{68}\u{6f}\u{75}\u{72}"] = 1,["\u{6d}\u{69}\u{6e}"] = 0,["\u{73}\u{65}\u{63}"] = - 3602}
804+t1={["\u{79}\u{65}\u{61}\u{72}"] = 0x7d5,["\u{6d}\u{6f}\u{6e}\u{74}\u{68}"] = 0x1,["\u{64}\u{61}\u{79}"] = 0x1,["\u{68}\u{6f}\u{75}\u{72}"] = 0x1,["\u{6d}\u{69}\u{6e}"] = 0x0,["\u{73}\u{65}\u{63}"] = - 0xe12}
805os.time(t1)
805os.time(t1)
806−assert(t1.day == 31 and t1.month == 12 and t1.year == 2004 and t1.hour == 23 and t1.min == 59 and t1.sec == 58 and t1.yday == 366)
806+assert(t1.day == 0x1f and t1.month == 0xc and t1.year == 0x7d4 and t1.hour == 0x17 and t1.min == 0x3b and t1.sec == 0x3a and t1.yday == 0x16e)
807io.output(io.stdout)
807io.output(io.stdout)
808local t = os.date("\u{25}\u{64}\u{20}\u{25}\u{6d}\u{20}\u{25}\u{59}\u{20}\u{25}\u{48}\u{20}\u{25}\u{4d}\u{20}\u{25}\u{53}")
808local t = os.date("\u{25}\u{64}\u{20}\u{25}\u{6d}\u{20}\u{25}\u{59}\u{20}\u{25}\u{48}\u{20}\u{25}\u{4d}\u{20}\u{25}\u{53}")
809local d,m,a,h,min,s = string.match(t,"\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}")
809local d,m,a,h,min,s = string.match(t,"\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}\u{20}\u{28}\u{25}\u{64}\u{2b}\u{29}")
zod/luau/res/lua/cycled/foo.lua+17−17
@@ -1,17 +1,17 @@
1foosjis=nil
1foosjis=nil
2az=bar[nil]
2az=bar[nil]
3−baz=bar(1).foo
3+baz=bar(0x1).foo
4−i=3
4+i=0x3
5−i,a[i]=i + 1,20 >> 9
5+i,a[i]=i + 0x1,0x14 >> 0x9
6hello="\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{64}\u{6b}\u{6e}\u{64}\u{6a}\u{d0}\u{b2}\u{d0}\u{b3}\u{d0}\u{be}\u{d0}\u{b2}\u{d1}\u{88}\u{d0}\u{be}\u{d0}\u{b2}"
6hello="\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{64}\u{6b}\u{6e}\u{64}\u{6a}\u{d0}\u{b2}\u{d0}\u{b3}\u{d0}\u{be}\u{d0}\u{b2}\u{d1}\u{88}\u{d0}\u{be}\u{d0}\u{b2}"
7−x={[hello] = 8,["\u{68}\u{65}\u{6c}\u{6c}\u{6f}"] = 12}
7+x={[hello] = 0x8,["\u{68}\u{65}\u{6c}\u{6c}\u{6f}"] = 0xc}
8;
8;
9−test_cases={{2147483647,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}"},{2147483647,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}"},{4294967295,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{35}"},{4294967295,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{35}"},{9223372036854775807,"\u{39}\u{2e}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{38}\u{65}\u{2b}\u{31}\u{38}"},{9223372036854775807,"\u{39}\u{2e}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{38}\u{65}\u{2b}\u{31}\u{38}"},{18446744073709551615,"\u{31}\u{2e}\u{38}\u{34}\u{34}\u{36}\u{37}\u{34}\u{34}\u{30}\u{37}\u{33}\u{37}\u{31}\u{65}\u{2b}\u{31}\u{39}"},{18446744073709551615,"\u{31}\u{2e}\u{38}\u{34}\u{34}\u{36}\u{37}\u{34}\u{34}\u{30}\u{37}\u{33}\u{37}\u{31}\u{65}\u{2b}\u{31}\u{39}"},{4294967296,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{36}"},{4294967296,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{36}"},{17592186044416,"\u{31}\u{37}\u{35}\u{39}\u{32}\u{31}\u{38}\u{36}\u{30}\u{34}\u{34}\u{34}\u{31}\u{36}"},{17592186044416,"\u{31}\u{37}\u{35}\u{39}\u{32}\u{31}\u{38}\u{36}\u{30}\u{34}\u{34}\u{34}\u{31}\u{36}"},{2147483648,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{38}"},{2147483648,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{38}"},{140737488355328,"\u{31}\u{2e}\u{34}\u{30}\u{37}\u{33}\u{37}\u{34}\u{38}\u{38}\u{33}\u{35}\u{35}\u{33}\u{33}\u{65}\u{2b}\u{31}\u{34}"},{140737488355328,"\u{31}\u{2e}\u{34}\u{30}\u{37}\u{33}\u{37}\u{34}\u{38}\u{38}\u{33}\u{35}\u{35}\u{33}\u{33}\u{65}\u{2b}\u{31}\u{34}"}}
9+test_cases={{0x7fffffff,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}"},{0x7fffffff,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}"},{0xffffffff,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{35}"},{0xffffffff,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{35}"},{0x7fffffffffffffff,"\u{39}\u{2e}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{38}\u{65}\u{2b}\u{31}\u{38}"},{0x7fffffffffffffff,"\u{39}\u{2e}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{38}\u{65}\u{2b}\u{31}\u{38}"},{0x100000000,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{36}"},{0x100000000,"\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{36}"},{0x100000000000,"\u{31}\u{37}\u{35}\u{39}\u{32}\u{31}\u{38}\u{36}\u{30}\u{34}\u{34}\u{34}\u{31}\u{36}"},{0x100000000000,"\u{31}\u{37}\u{35}\u{39}\u{32}\u{31}\u{38}\u{36}\u{30}\u{34}\u{34}\u{34}\u{31}\u{36}"},{0x80000000,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{38}"},{0x80000000,"\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{38}"},{0x800000000000,"\u{31}\u{2e}\u{34}\u{30}\u{37}\u{33}\u{37}\u{34}\u{38}\u{38}\u{33}\u{35}\u{35}\u{33}\u{33}\u{65}\u{2b}\u{31}\u{34}"},{0x800000000000,"\u{31}\u{2e}\u{34}\u{30}\u{37}\u{33}\u{37}\u{34}\u{38}\u{38}\u{33}\u{35}\u{35}\u{33}\u{33}\u{65}\u{2b}\u{31}\u{34}"}}
10::helli::
10::helli::
11foo={3.0,3.1416,3.1416,3.1416,340.0,0.1171875,162.1875,162.1875,3.141592653589793,1984.0}
11foo={3.0,3.1416,3.1416,3.1416,340.0,0.1171875,162.1875,162.1875,3.141592653589793,1984.0}
12do
12do
13−foo=1
13+foo=0x1
14−return 8,foo
14+return 0x8,foo
15end
15end
16print("\u{74}\u{68}\u{65}\u{20}\u{77}\u{61}\u{79}\u{20}\u{6f}\u{66}\u{20}\u{74}\u{68}\u{65}\u{20}\u{66}\u{75}\u{74}\u{75}\u{72}\u{65}")
16print("\u{74}\u{68}\u{65}\u{20}\u{77}\u{61}\u{79}\u{20}\u{6f}\u{66}\u{20}\u{74}\u{68}\u{65}\u{20}\u{66}\u{75}\u{74}\u{75}\u{72}\u{65}")
17print("\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
17print("\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
@@ -23,26 +23,26 @@ break
23end
23end
24repeat
24repeat
25do
25do
26−foo=9
26+foo=0x9
27;
27;
28end
28end
29until true
29until true
30−if l == 3 then
30+if l == 0x3 then
31−a=a + 1
31+a=a + 0x1
32;
32;
33−assert(getlocal(2,1) == "\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
33+assert(getlocal(0x2,0x1) == "\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{29}")
34−elseif l == 4 then
34+elseif l == 0x4 then
35−a=a + 1
35+a=a + 0x1
36;
36;
37−assert(getlocal(2,1) == "\u{41}")
37+assert(getlocal(0x2,0x1) == "\u{41}")
38else
38else
39;
39;
40end
40end
41−for i = 1, 100
41+for i = 0x1, 0x64
42do
42do
43karlSum=karlSum + i
43karlSum=karlSum + i
44end
44end
45−for j = 100, 1, 1
45+for j = 0x64, 0x1, 0x1
46do
46do
47fredSum=fredSum + j
47fredSum=fredSum + j
48end
48end
@@ -69,7 +69,7 @@ return function (y)
69return x + y
69return x + y
70end
70end
71end
71end
72−x=- 1 + 8
72+x=- 0x1 + 0x8
73if _VERSION ~= version then
73if _VERSION ~= version then
74io.stderr:write("\u{54}\u{68}\u{69}\u{73}\u{20}\u{74}\u{65}\u{73}\u{74}\u{20}\u{73}\u{75}\u{69}\u{74}\u{65}\u{20}\u{69}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}",version,"\u{2c}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{6f}\u{72}\u{20}",_VERSION,"\u{a}\u{45}\u{78}\u{69}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}")
74io.stderr:write("\u{54}\u{68}\u{69}\u{73}\u{20}\u{74}\u{65}\u{73}\u{74}\u{20}\u{73}\u{75}\u{69}\u{74}\u{65}\u{20}\u{69}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}",version,"\u{2c}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{6f}\u{72}\u{20}",_VERSION,"\u{a}\u{45}\u{78}\u{69}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}")
75return
75return
zod/luau/res/lua/cycled/gc.lua+151−151
@@ -13,29 +13,29 @@ local function nop
13end
13end
14local function gcinfo
14local function gcinfo
15()
15()
16−return collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 1024
16+return collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 0x400
17end
17end
18do
18do
19−local a = collectgarbage("\u{73}\u{65}\u{74}\u{70}\u{61}\u{75}\u{73}\u{65}",200)
19+local a = collectgarbage("\u{73}\u{65}\u{74}\u{70}\u{61}\u{75}\u{73}\u{65}",0xc8)
20−local b = collectgarbage("\u{73}\u{65}\u{74}\u{73}\u{74}\u{65}\u{70}\u{6d}\u{75}\u{6c}",200)
20+local b = collectgarbage("\u{73}\u{65}\u{74}\u{73}\u{74}\u{65}\u{70}\u{6d}\u{75}\u{6c}",0xc8)
21−local t = {0,2,10,90,500,5000,30000,2147483646}
21+local t = {0x0,0x2,0xa,0x5a,0x1f4,0x1388,0x7530,0x7ffffffe}
22−for i = 1, # t
22+for i = 0x1, # t
23do
23do
24local p = t[i]
24local p = t[i]
25−for j = 1, # t
25+for j = 0x1, # t
26do
26do
27local m = t[j]
27local m = t[j]
28collectgarbage("\u{73}\u{65}\u{74}\u{70}\u{61}\u{75}\u{73}\u{65}",p)
28collectgarbage("\u{73}\u{65}\u{74}\u{70}\u{61}\u{75}\u{73}\u{65}",p)
29collectgarbage("\u{73}\u{65}\u{74}\u{73}\u{74}\u{65}\u{70}\u{6d}\u{75}\u{6c}",m)
29collectgarbage("\u{73}\u{65}\u{74}\u{73}\u{74}\u{65}\u{70}\u{6d}\u{75}\u{6c}",m)
30−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
30+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
31−collectgarbage("\u{73}\u{74}\u{65}\u{70}",10000)
31+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x2710)
32end
32end
33end
33end
34collectgarbage("\u{73}\u{65}\u{74}\u{70}\u{61}\u{75}\u{73}\u{65}",a)
34collectgarbage("\u{73}\u{65}\u{74}\u{70}\u{61}\u{75}\u{73}\u{65}",a)
35collectgarbage("\u{73}\u{65}\u{74}\u{73}\u{74}\u{65}\u{70}\u{6d}\u{75}\u{6c}",b)
35collectgarbage("\u{73}\u{65}\u{74}\u{73}\u{74}\u{65}\u{70}\u{6d}\u{75}\u{6c}",b)
36collectgarbage()
36collectgarbage()
37end
37end
38−_G["\u{77}\u{68}\u{69}\u{6c}\u{65}"]=234
38+_G["\u{77}\u{68}\u{69}\u{6c}\u{65}"]=0xea
39local function GC1
39local function GC1
40()
40()
41local u
41local u
@@ -44,23 +44,23 @@ local finish = false
44u=setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
44u=setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
45finish=true
45finish=true
46end})
46end})
47−b={34}
47+b={0x22}
48repeat
48repeat
49u={}
49u={}
50until finish
50until finish
51−assert(b[1] == 34)
51+assert(b[0x1] == 0x22)
52finish=false
52finish=false
53;
53;
54−local i = 1
54+local i = 0x1
55u=setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
55u=setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
56finish=true
56finish=true
57end})
57end})
58repeat
58repeat
59−i=i + 1
59+i=i + 0x1
60;
60;
61u=tostring(i) .. tostring(i)
61u=tostring(i) .. tostring(i)
62until finish
62until finish
63−assert(b[1] == 34)
63+assert(b[0x1] == 0x22)
64finish=false
64finish=false
65u=setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
65u=setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
66finish=true
66finish=true
@@ -72,7 +72,7 @@ u=function ()
72return i
72return i
73end
73end
74until finish
74until finish
75−assert(b[1] == 34)
75+assert(b[0x1] == 0x22)
76end
76end
77local function GC2
77local function GC2
78()
78()
@@ -81,23 +81,23 @@ local finish = false
81u={setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
81u={setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
82finish=true
82finish=true
83end})}
83end})}
84−local b = {34}
84+local b = {0x22}
85repeat
85repeat
86u={{}}
86u={{}}
87until finish
87until finish
88−assert(b[1] == 34)
88+assert(b[0x1] == 0x22)
89finish=false
89finish=false
90;
90;
91−local i = 1
91+local i = 0x1
92u={setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
92u={setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
93finish=true
93finish=true
94end})}
94end})}
95repeat
95repeat
96−i=i + 1
96+i=i + 0x1
97;
97;
98u={tostring(i) .. tostring(i)}
98u={tostring(i) .. tostring(i)}
99until finish
99until finish
100−assert(b[1] == 34)
100+assert(b[0x1] == 0x22)
101finish=false
101finish=false
102u={setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
102u={setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
103finish=true
103finish=true
@@ -109,7 +109,7 @@ u={function ()
109return i
109return i
110end}
110end}
111until finish
111until finish
112−assert(b[1] == 34)
112+assert(b[0x1] == 0x22)
113end
113end
114local function GC
114local function GC
115()
115()
@@ -119,15 +119,15 @@ GC2()
119end
119end
120do
120do
121print("\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{73}")
121print("\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{73}")
122−local limit = 5000
122+local limit = 0x1388
123−for i = 1, limit
123+for i = 0x1, limit
124do
124do
125local a = {}
125local a = {}
126;
126;
127a=nil
127a=nil
128end
128end
129local a = "\u{61}"
129local a = "\u{61}"
130−for i = 1, limit
130+for i = 0x1, limit
131do
131do
132a=i .. "\u{62}"
132a=i .. "\u{62}"
133;
133;
@@ -136,7 +136,7 @@ a="\u{61}"
136end
136end
137a={}
137a={}
138function a:test()
138function a:test()
139−for i = 1, limit
139+for i = 0x1, limit
140do
140do
141load(string.format("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{28}\u{61}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{61}\u{25}\u{64}\u{27}\u{20}\u{65}\u{6e}\u{64}",i),"")()
141load(string.format("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{74}\u{65}\u{6d}\u{70}\u{28}\u{61}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}\u{61}\u{25}\u{64}\u{27}\u{20}\u{65}\u{6e}\u{64}",i),"")()
142assert(temp() == string.format("\u{61}\u{25}\u{64}",i))
142assert(temp() == string.format("\u{61}\u{25}\u{64}",i))
@@ -153,11 +153,11 @@ end
153print("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{73}")
153print("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{73}")
154local prog = "\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{28}\u{78}\u{2c}\u{79}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{73}\u{69}\u{6e}\u{28}\u{61}\u{2b}\u{30}\u{2e}\u{34}\u{35}\u{36}\u{2d}\u{30}\u{2e}\u{32}\u{33}\u{65}\u{2d}\u{31}\u{32}\u{29}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{7a}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{69}\u{6e}\u{28}\u{25}\u{78}\u{2b}\u{7a}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{77}\u{29}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{77}\u{3b}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{65}\u{6e}\u{64}\u{a}"
154local prog = "\u{64}\u{6f}\u{a}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{3b}\u{a}\u{20}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{28}\u{78}\u{2c}\u{79}\u{29}\u{a}\u{20}\u{20}\u{20}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{73}\u{69}\u{6e}\u{28}\u{61}\u{2b}\u{30}\u{2e}\u{34}\u{35}\u{36}\u{2d}\u{30}\u{2e}\u{32}\u{33}\u{65}\u{2d}\u{31}\u{32}\u{29}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{7a}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{69}\u{6e}\u{28}\u{25}\u{78}\u{2b}\u{7a}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{77}\u{29}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{77}\u{3b}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{65}\u{6e}\u{64}\u{a}"
155do
155do
156−local step = 1
156+local step = 0x1
157if _soft then
157if _soft then
158−step=13
158+step=0xd
159end
159end
160−for i = 1, string.len(prog), step
160+for i = 0x1, string.len(prog), step
161do
161do
162for j = i, string.len(prog), step
162for j = i, string.len(prog), step
163do
163do
@@ -171,20 +171,20 @@ do
171foo=nil
171foo=nil
172print("\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}")
172print("\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}")
173local x = "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
173local x = "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
174−assert(string.len(x) == 80)
174+assert(string.len(x) == 0x50)
175local s = ""
175local s = ""
176−local k = math.min(300,(math.maxinteger // 80) // 2)
176+local k = math.min(0x12c,(math.maxinteger // 0x50) // 0x2)
177−for n = 1, k
177+for n = 0x1, k
178do
178do
179s=s .. x
179s=s .. x
180;
180;
181local j = tostring(n)
181local j = tostring(n)
182end
182end
183−assert(string.len(s) == k * 80)
183+assert(string.len(s) == k * 0x50)
184−s=string.sub(s,1,10000)
184+s=string.sub(s,0x1,0x2710)
185local s,i = string.gsub(s,"\u{28}\u{25}\u{64}\u{25}\u{64}\u{25}\u{64}\u{25}\u{64}\u{29}","")
185local s,i = string.gsub(s,"\u{28}\u{25}\u{64}\u{25}\u{64}\u{25}\u{64}\u{25}\u{64}\u{29}","")
186−assert(i == 10000 // 4)
186+assert(i == 0x2710 // 0x4)
187−assert(_G["\u{77}\u{68}\u{69}\u{6c}\u{65}"] == 234)
187+assert(_G["\u{77}\u{68}\u{69}\u{6c}\u{65}"] == 0xea)
188_G["\u{77}\u{68}\u{69}\u{6c}\u{65}"]=nil
188_G["\u{77}\u{68}\u{69}\u{6c}\u{65}"]=nil
189end
189end
190do
190do
@@ -194,27 +194,27 @@ local function dosteps
194(siz)
194(siz)
195collectgarbage()
195collectgarbage()
196local a = {}
196local a = {}
197−for i = 1, 100
197+for i = 0x1, 0x64
198do
198do
199a[i]={{}}
199a[i]={{}}
200;
200;
201local b = {}
201local b = {}
202end
202end
203local x = gcinfo()
203local x = gcinfo()
204−local i = 0
204+local i = 0x0
205repeat
205repeat
206−i=i + 1
206+i=i + 0x1
207until collectgarbage("\u{73}\u{74}\u{65}\u{70}",siz)
207until collectgarbage("\u{73}\u{74}\u{65}\u{70}",siz)
208assert(gcinfo() < x)
208assert(gcinfo() < x)
209return i
209return i
210end
210end
211collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
211collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
212if not _port then
212if not _port then
213−assert(dosteps(10) < dosteps(2))
213+assert(dosteps(0xa) < dosteps(0x2))
214end
214end
215−assert(dosteps(20000) == 1)
215+assert(dosteps(0x4e20) == 0x1)
216−assert(collectgarbage("\u{73}\u{74}\u{65}\u{70}",20000) == true)
216+assert(collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x4e20) == true)
217−assert(collectgarbage("\u{73}\u{74}\u{65}\u{70}",20000) == true)
217+assert(collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x4e20) == true)
218assert(not collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
218assert(not collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
219collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
219collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
220assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
220assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
@@ -227,17 +227,17 @@ local x = gcinfo()
227collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
227collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
228repeat
228repeat
229local a = {}
229local a = {}
230−until gcinfo() > 3 * x
230+until gcinfo() > 0x3 * x
231collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
231collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
232assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
232assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
233repeat
233repeat
234local a = {}
234local a = {}
235−until gcinfo() <= x * 2
235+until gcinfo() <= x * 0x2
236end
236end
237print("\u{63}\u{6c}\u{65}\u{61}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
237print("\u{63}\u{6c}\u{65}\u{61}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}")
238−local lim = 15
238+local lim = 0xf
239local a = {}
239local a = {}
240−for i = 1, lim
240+for i = 0x1, lim
241do
241do
242a[{}]=i
242a[{}]=i
243end
243end
@@ -258,11 +258,11 @@ for n in pairs(a)
258do
258do
259error("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}")
259error("\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}")
260end
260end
261−for i = 1, lim
261+for i = 0x1, lim
262do
262do
263a[i]=i
263a[i]=i
264end
264end
265−for i = 1, lim
265+for i = 0x1, lim
266do
266do
267assert(a[i] == i)
267assert(a[i] == i)
268end
268end
@@ -271,80 +271,80 @@ a={}
271;
271;
272setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"})
272setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"})
273;
273;
274−for i = 1, lim
274+for i = 0x1, lim
275do
275do
276a[{}]=i
276a[{}]=i
277end
277end
278−for i = 1, lim
278+for i = 0x1, lim
279do
279do
280a[i]=i
280a[i]=i
281end
281end
282−for i = 1, lim
282+for i = 0x1, lim
283do
283do
284local s = string.rep("\u{40}",i)
284local s = string.rep("\u{40}",i)
285;
285;
286a[s]=s .. "\u{23}"
286a[s]=s .. "\u{23}"
287end
287end
288collectgarbage()
288collectgarbage()
289−local i = 0
289+local i = 0x0
290for k,v in pairs(a)
290for k,v in pairs(a)
291do
291do
292assert(k == v or k .. "\u{23}" == v)
292assert(k == v or k .. "\u{23}" == v)
293;
293;
294−i=i + 1
294+i=i + 0x1
295end
295end
296−assert(i == 2 * lim)
296+assert(i == 0x2 * lim)
297a={}
297a={}
298;
298;
299setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}"})
299setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}"})
300;
300;
301−a[1]=string.rep("\u{62}",21)
301+a[0x1]=string.rep("\u{62}",0x15)
302collectgarbage()
302collectgarbage()
303−assert(a[1])
303+assert(a[0x1])
304−a[1]=undef
304+a[0x1]=undef
305−for i = 1, lim
305+for i = 0x1, lim
306do
306do
307a[i]={}
307a[i]={}
308end
308end
309−for i = 1, lim
309+for i = 0x1, lim
310do
310do
311a[i .. "\u{78}"]={}
311a[i .. "\u{78}"]={}
312end
312end
313−for i = 1, lim
313+for i = 0x1, lim
314do
314do
315local t = {}
315local t = {}
316;
316;
317a[t]=t
317a[t]=t
318end
318end
319−for i = 1, lim
319+for i = 0x1, lim
320do
320do
321a[i + lim]=i .. "\u{78}"
321a[i + lim]=i .. "\u{78}"
322end
322end
323collectgarbage()
323collectgarbage()
324−local i = 0
324+local i = 0x0
325for k,v in pairs(a)
325for k,v in pairs(a)
326do
326do
327assert(k == v or k - lim .. "\u{78}" == v)
327assert(k == v or k - lim .. "\u{78}" == v)
328;
328;
329−i=i + 1
329+i=i + 0x1
330end
330end
331−assert(i == 2 * lim)
331+assert(i == 0x2 * lim)
332a={}
332a={}
333;
333;
334setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
334setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
335;
335;
336local x,y,z = {},{},{}
336local x,y,z = {},{},{}
337−a[1],a[2],a[3]=x,y,z
337+a[0x1],a[0x2],a[0x3]=x,y,z
338−a[string.rep("\u{24}",11)]=string.rep("\u{24}",11)
338+a[string.rep("\u{24}",0xb)]=string.rep("\u{24}",0xb)
339−for i = 4, lim
339+for i = 0x4, lim
340do
340do
341a[i]={}
341a[i]={}
342end
342end
343−for i = 1, lim
343+for i = 0x1, lim
344do
344do
345a[{}]=i
345a[{}]=i
346end
346end
347−for i = 1, lim
347+for i = 0x1, lim
348do
348do
349local t = {}
349local t = {}
350;
350;
@@ -352,21 +352,21 @@ a[t]=t
352end
352end
353collectgarbage()
353collectgarbage()
354assert(next(a) ~= nil)
354assert(next(a) ~= nil)
355−local i = 0
355+local i = 0x0
356for k,v in pairs(a)
356for k,v in pairs(a)
357do
357do
358−assert((k == 1 and v == x) or (k == 2 and v == y) or (k == 3 and v == z) or k == v)
358+assert((k == 0x1 and v == x) or (k == 0x2 and v == y) or (k == 0x3 and v == z) or k == v)
359;
359;
360−i=i + 1
360+i=i + 0x1
361end
361end
362−assert(i == 4)
362+assert(i == 0x4)
363x,y,z=nil
363x,y,z=nil
364collectgarbage()
364collectgarbage()
365−assert(next(a) == string.rep("\u{24}",11))
365+assert(next(a) == string.rep("\u{24}",0xb))
366a={}
366a={}
367−local t = {["\u{78}"] = 10}
367+local t = {["\u{78}"] = 0xa}
368local C = setmetatable({["\u{6b}\u{65}\u{79}"] = t},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}"})
368local C = setmetatable({["\u{6b}\u{65}\u{79}"] = t},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}"})
369−local C1 = setmetatable({[t] = 1},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"})
369+local C1 = setmetatable({[t] = 0x1},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"})
370a.x=t
370a.x=t
371setmetatable(a,{["\u{5f}\u{5f}\u{67}\u{63}"] = function (u)
371setmetatable(a,{["\u{5f}\u{5f}\u{67}\u{63}"] = function (u)
372assert(C.key == nil)
372assert(C.key == nil)
@@ -378,11 +378,11 @@ collectgarbage()
378assert(next(C) == nil and next(C1) == nil)
378assert(next(C) == nil and next(C1) == nil)
379C,C1=nil
379C,C1=nil
380local mt = {["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"}
380local mt = {["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"}
381−a={{10},{20},{30},{40}}
381+a={{0xa},{0x14},{0x1e},{0x28}}
382;
382;
383setmetatable(a,mt)
383setmetatable(a,mt)
384x=nil
384x=nil
385−for i = 1, 100
385+for i = 0x1, 0x64
386do
386do
387local n = {}
387local n = {}
388;
388;
@@ -392,37 +392,37 @@ x=n
392end
392end
393GC()
393GC()
394local n = x
394local n = x
395−local i = 0
395+local i = 0x0
396while n do
396while n do
397−n=a[n].k[1]
397+n=a[n].k[0x1]
398;
398;
399−i=i + 1
399+i=i + 0x1
400end
400end
401−assert(i == 100)
401+assert(i == 0x64)
402x=nil
402x=nil
403GC()
403GC()
404−for i = 1, 4
404+for i = 0x1, 0x4
405do
405do
406−assert(a[i][1] == i * 10)
406+assert(a[i][0x1] == i * 0xa)
407;
407;
408a[i]=undef
408a[i]=undef
409end
409end
410assert(next(a) == nil)
410assert(next(a) == nil)
411local K = {}
411local K = {}
412a[K]={}
412a[K]={}
413−for i = 1, 10
413+for i = 0x1, 0xa
414do
414do
415a[K][i]={}
415a[K][i]={}
416;
416;
417a[a[K][i]]=setmetatable({},mt)
417a[a[K][i]]=setmetatable({},mt)
418end
418end
419x=nil
419x=nil
420−local k = 1
420+local k = 0x1
421−for j = 1, 100
421+for j = 0x1, 0x64
422do
422do
423local n = {}
423local n = {}
424;
424;
425−local nk = k % 10 + 1
425+local nk = k % 0xa + 0x1
426a[a[K][nk]][n]={x,["\u{6b}"] = k}
426a[a[K][nk]][n]={x,["\u{6b}"] = k}
427;
427;
428x=n
428x=n
@@ -431,17 +431,17 @@ k=nk
431end
431end
432GC()
432GC()
433local n = x
433local n = x
434−local i = 0
434+local i = 0x0
435while n do
435while n do
436local t = a[a[K][k]][n]
436local t = a[a[K][k]][n]
437;
437;
438−n=t[1]
438+n=t[0x1]
439;
439;
440k=t.k
440k=t.k
441;
441;
442−i=i + 1
442+i=i + 0x1
443end
443end
444−assert(i == 100)
444+assert(i == 0x64)
445K=nil
445K=nil
446GC()
446GC()
447if T then
447if T then
@@ -453,12 +453,12 @@ setmetatable(s,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}"})
453setmetatable(u,{["\u{5f}\u{5f}\u{67}\u{63}"] = function (o)
453setmetatable(u,{["\u{5f}\u{5f}\u{67}\u{63}"] = function (o)
454local i = s[o]
454local i = s[o]
455s[i]=true
455s[i]=true
456−assert(not s[i - 1])
456+assert(not s[i - 0x1])
457−if i == 8 then
457+if i == 0x8 then
458error("\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{40}")
458error("\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{40}")
459end
459end
460end})
460end})
461−for i = 6, 10
461+for i = 0x6, 0xa
462do
462do
463local n = setmetatable({},getmetatable(u))
463local n = setmetatable({},getmetatable(u))
464s[n]=i
464s[n]=i
@@ -471,17 +471,17 @@ assert(string.find(_WARN,"\u{65}\u{72}\u{72}\u{6f}\u{72}\u{20}\u{69}\u{6e}\u{20}
471assert(string.match(_WARN,"\u{40}\u{28}\u{2e}\u{2d}\u{29}\u{40}") == "\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}")
471assert(string.match(_WARN,"\u{40}\u{28}\u{2e}\u{2d}\u{29}\u{40}") == "\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}")
472;
472;
473_WARN=false
473_WARN=false
474−for i = 8, 10
474+for i = 0x8, 0xa
475do
475do
476assert(s[i])
476assert(s[i])
477end
477end
478−for i = 1, 5
478+for i = 0x1, 0x5
479do
479do
480local n = setmetatable({},getmetatable(u))
480local n = setmetatable({},getmetatable(u))
481s[n]=i
481s[n]=i
482end
482end
483collectgarbage()
483collectgarbage()
484−for i = 1, 10
484+for i = 0x1, 0xa
485do
485do
486assert(s[i])
486assert(s[i])
487end
487end
@@ -494,16 +494,16 @@ if T == nil then
494else
494else
495local function newproxy
495local function newproxy
496(u)
496(u)
497−return debug.setmetatable(T.newuserdata(0),debug.getmetatable(u))
497+return debug.setmetatable(T.newuserdata(0x0),debug.getmetatable(u))
498end
498end
499collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
499collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
500local u = newproxy(nil)
500local u = newproxy(nil)
501debug.setmetatable(u,{["\u{5f}\u{5f}\u{67}\u{63}"] = true})
501debug.setmetatable(u,{["\u{5f}\u{5f}\u{67}\u{63}"] = true})
502−local s = 0
502+local s = 0x0
503−local a = {[u] = 0}
503+local a = {[u] = 0x0}
504;
504;
505setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}\u{6b}"})
505setmetatable(a,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}\u{6b}"})
506−for i = 1, 10
506+for i = 0x1, 0xa
507do
507do
508a[newproxy(u)]=i
508a[newproxy(u)]=i
509end
509end
@@ -521,7 +521,7 @@ for k,v in pairs(a1)
521do
521do
522a[v]=k
522a[v]=k
523end
523end
524−for i = 1, 10
524+for i = 0x1, 0xa
525do
525do
526assert(a[i])
526assert(a[i])
527end
527end
@@ -530,62 +530,62 @@ getmetatable(u).u=u
530do
530do
531local u = u
531local u = u
532getmetatable(u).__gc=function (o)
532getmetatable(u).__gc=function (o)
533−assert(a[o] == 10 - s)
533+assert(a[o] == 0xa - s)
534−assert(a[10 - s] == undef)
534+assert(a[0xa - s] == undef)
535assert(getmetatable(o) == getmetatable(u))
535assert(getmetatable(o) == getmetatable(u))
536−assert(getmetatable(o).a[o] == 10 - s)
536+assert(getmetatable(o).a[o] == 0xa - s)
537−s=s + 1
537+s=s + 0x1
538end
538end
539end
539end
540a1,u=nil
540a1,u=nil
541assert(next(a) ~= nil)
541assert(next(a) ~= nil)
542collectgarbage()
542collectgarbage()
543−assert(s == 11)
543+assert(s == 0xb)
544collectgarbage()
544collectgarbage()
545assert(next(a) == nil)
545assert(next(a) == nil)
546end
546end
547local u = setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = true})
547local u = setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = true})
548setmetatable(getmetatable(u),{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}"})
548setmetatable(getmetatable(u),{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{76}"})
549getmetatable(u).__gc=function (o)
549getmetatable(u).__gc=function (o)
550−os.exit(1)
550+os.exit(0x1)
551end
551end
552u=nil
552u=nil
553collectgarbage()
553collectgarbage()
554local u = setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = true})
554local u = setmetatable({},{["\u{5f}\u{5f}\u{67}\u{63}"] = true})
555local m = getmetatable(u)
555local m = getmetatable(u)
556−m.x={[{0}] = 1,[0] = {1}}
556+m.x={[{0x0}] = 0x1,[0x0] = {0x1}}
557;
557;
558setmetatable(m.x,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
558setmetatable(m.x,{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
559;
559;
560m.__gc=function (o)
560m.__gc=function (o)
561assert(next(getmetatable(o).x) == nil)
561assert(next(getmetatable(o).x) == nil)
562−m=10
562+m=0xa
563end
563end
564u,m=nil
564u,m=nil
565collectgarbage()
565collectgarbage()
566−assert(m == 10)
566+assert(m == 0xa)
567do
567do
568collectgarbage()
568collectgarbage()
569;
569;
570collectgarbage()
570collectgarbage()
571local m = collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
571local m = collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
572local a = setmetatable({},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
572local a = setmetatable({},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
573−a[string.rep("\u{61}",2 ^ 22)]=25
573+a[string.rep("\u{61}",0x2 ^ 0x16)]=0x19
574−a[string.rep("\u{62}",2 ^ 22)]={}
574+a[string.rep("\u{62}",0x2 ^ 0x16)]={}
575−a[{}]=14
575+a[{}]=0xe
576−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") > m + 2 ^ 13)
576+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") > m + 0x2 ^ 0xd)
577collectgarbage()
577collectgarbage()
578−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= m + 2 ^ 12 and collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") < m + 2 ^ 13)
578+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") >= m + 0x2 ^ 0xc and collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") < m + 0x2 ^ 0xd)
579local k,v = next(a)
579local k,v = next(a)
580−assert(k == string.rep("\u{61}",2 ^ 22) and v == 25)
580+assert(k == string.rep("\u{61}",0x2 ^ 0x16) and v == 0x19)
581assert(next(a,k) == nil)
581assert(next(a,k) == nil)
582−assert(a[string.rep("\u{62}",2 ^ 22)] == undef)
582+assert(a[string.rep("\u{62}",0x2 ^ 0x16)] == undef)
583a[k]=undef
583a[k]=undef
584k=nil
584k=nil
585collectgarbage()
585collectgarbage()
586assert(next(a) == nil)
586assert(next(a) == nil)
587−assert(a[string.rep("\u{62}",100)] == undef)
587+assert(a[string.rep("\u{62}",0x64)] == undef)
588−assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= m + 1)
588+assert(collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") <= m + 0x1)
589end
589end
590if T then
590if T then
591warn("\u{40}\u{73}\u{74}\u{6f}\u{72}\u{65}")
591warn("\u{40}\u{73}\u{74}\u{6f}\u{72}\u{65}")
@@ -602,7 +602,7 @@ end
602if not _soft then
602if not _soft then
603print("\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{6c}\u{69}\u{73}\u{74}")
603print("\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{6c}\u{69}\u{73}\u{74}")
604local a = {}
604local a = {}
605−for i = 1, 200000
605+for i = 0x1, 0x30d40
606do
606do
607a={["\u{6e}\u{65}\u{78}\u{74}"] = a}
607a={["\u{6e}\u{65}\u{78}\u{74}"] = a}
608end
608end
@@ -610,7 +610,7 @@ a=nil
610collectgarbage()
610collectgarbage()
611end
611end
612print("\u{73}\u{65}\u{6c}\u{66}\u{2d}\u{72}\u{65}\u{66}\u{65}\u{72}\u{65}\u{6e}\u{63}\u{65}\u{64}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{73}")
612print("\u{73}\u{65}\u{6c}\u{66}\u{2d}\u{72}\u{65}\u{66}\u{65}\u{72}\u{65}\u{6e}\u{63}\u{65}\u{64}\u{20}\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}\u{73}")
613−local thread_id = 0
613+local thread_id = 0x0
614local threads = {}
614local threads = {}
615local function fn
615local function fn
616(thread)
616(thread)
@@ -620,10 +620,10 @@ thread=x
620end
620end
621coroutine.yield()
621coroutine.yield()
622end
622end
623−while thread_id < 1000 do
623+while thread_id < 0x3e8 do
624local thread = coroutine.create(fn)
624local thread = coroutine.create(fn)
625coroutine.resume(thread,thread)
625coroutine.resume(thread,thread)
626−thread_id=thread_id + 1
626+thread_id=thread_id + 0x1
627end
627end
628do
628do
629local collected = false
629local collected = false
@@ -640,7 +640,7 @@ param={param,f}
640setmetatable(param,{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
640setmetatable(param,{["\u{5f}\u{5f}\u{67}\u{63}"] = function ()
641collected=true
641collected=true
642end})
642end})
643−coroutine.yield(100)
643+coroutine.yield(0x64)
644end)()
644end)()
645end
645end
646local co = coroutine.create(f)
646local co = coroutine.create(f)
@@ -653,28 +653,28 @@ end
653do
653do
654collectgarbage()
654collectgarbage()
655collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
655collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
656−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
656+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
657local x = gcinfo()
657local x = gcinfo()
658repeat
658repeat
659−for i = 1, 1000
659+for i = 0x1, 0x3e8
660do
660do
661_ENV.a={}
661_ENV.a={}
662end
662end
663−until gcinfo() > 2 * x
663+until gcinfo() > 0x2 * x
664collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
664collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
665_ENV.a=nil
665_ENV.a=nil
666end
666end
667if T then
667if T then
668local function foo
668local function foo
669()
669()
670−local a = {["\u{78}"] = 20}
670+local a = {["\u{78}"] = 0x14}
671coroutine.yield(function ()
671coroutine.yield(function ()
672return a.x
672return a.x
673end)
673end)
674−assert(a.x == 20)
674+assert(a.x == 0x14)
675−a={["\u{78}"] = 30}
675+a={["\u{78}"] = 0x1e}
676assert(T.gccolor(a) == "\u{77}\u{68}\u{69}\u{74}\u{65}")
676assert(T.gccolor(a) == "\u{77}\u{68}\u{69}\u{74}\u{65}")
677−coroutine.yield(100)
677+coroutine.yield(0x64)
678end
678end
679local t = setmetatable({},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
679local t = setmetatable({},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
680collectgarbage()
680collectgarbage()
@@ -684,12 +684,12 @@ t.co=coroutine.wrap(foo)
684local f = t.co()
684local f = t.co()
685T.gcstate("\u{61}\u{74}\u{6f}\u{6d}\u{69}\u{63}")
685T.gcstate("\u{61}\u{74}\u{6f}\u{6d}\u{69}\u{63}")
686assert(T.gcstate() == "\u{61}\u{74}\u{6f}\u{6d}\u{69}\u{63}")
686assert(T.gcstate() == "\u{61}\u{74}\u{6f}\u{6d}\u{69}\u{63}")
687−assert(t.co() == 100)
687+assert(t.co() == 0x64)
688assert(T.gccolor(t.co) == "\u{77}\u{68}\u{69}\u{74}\u{65}")
688assert(T.gccolor(t.co) == "\u{77}\u{68}\u{69}\u{74}\u{65}")
689T.gcstate("\u{70}\u{61}\u{75}\u{73}\u{65}")
689T.gcstate("\u{70}\u{61}\u{75}\u{73}\u{65}")
690−assert(t.co == nil and f() == 30)
690+assert(t.co == nil and f() == 0x1e)
691collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
691collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
692−local u = T.newuserdata(0,1)
692+local u = T.newuserdata(0x0,0x1)
693collectgarbage()
693collectgarbage()
694collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
694collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
695local a = {}
695local a = {}
@@ -706,8 +706,8 @@ end
706if T then
706if T then
707local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
707local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
708collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
708collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
709−local x = T.newuserdata(0)
709+local x = T.newuserdata(0x0)
710−local y = T.newuserdata(0)
710+local y = T.newuserdata(0x0)
711debug.setmetatable(y,{["\u{5f}\u{5f}\u{67}\u{63}"] = nop})
711debug.setmetatable(y,{["\u{5f}\u{5f}\u{67}\u{63}"] = nop})
712debug.setmetatable(x,{["\u{5f}\u{5f}\u{67}\u{63}"] = nop})
712debug.setmetatable(x,{["\u{5f}\u{5f}\u{67}\u{63}"] = nop})
713assert(T.gccolor(y) == "\u{77}\u{68}\u{69}\u{74}\u{65}")
713assert(T.gccolor(y) == "\u{77}\u{68}\u{69}\u{74}\u{65}")
@@ -718,33 +718,33 @@ if T then
718print("\u{65}\u{6d}\u{65}\u{72}\u{67}\u{65}\u{6e}\u{63}\u{79}\u{20}\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}")
718print("\u{65}\u{6d}\u{65}\u{72}\u{67}\u{65}\u{6e}\u{63}\u{79}\u{20}\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{73}")
719collectgarbage()
719collectgarbage()
720collectgarbage()
720collectgarbage()
721−T.totalmem(T.totalmem() + 200)
721+T.totalmem(T.totalmem() + 0xc8)
722−for i = 1, 200
722+for i = 0x1, 0xc8
723do
723do
724local a = {}
724local a = {}
725end
725end
726−T.totalmem(0)
726+T.totalmem(0x0)
727collectgarbage()
727collectgarbage()
728local t = T.totalmem("\u{74}\u{61}\u{62}\u{6c}\u{65}")
728local t = T.totalmem("\u{74}\u{61}\u{62}\u{6c}\u{65}")
729local a = {{},{},{}}
729local a = {{},{},{}}
730−assert(T.totalmem("\u{74}\u{61}\u{62}\u{6c}\u{65}") == t + 4)
730+assert(T.totalmem("\u{74}\u{61}\u{62}\u{6c}\u{65}") == t + 0x4)
731t=T.totalmem("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
731t=T.totalmem("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
732a=function ()
732a=function ()
733
733
734end
734end
735−assert(T.totalmem("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}") == t + 1)
735+assert(T.totalmem("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}") == t + 0x1)
736t=T.totalmem("\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}")
736t=T.totalmem("\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}")
737a=coroutine.create(function ()
737a=coroutine.create(function ()
738
738
739end)
739end)
740−assert(T.totalmem("\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}") == t + 1)
740+assert(T.totalmem("\u{74}\u{68}\u{72}\u{65}\u{61}\u{64}") == t + 0x1)
741end
741end
742do
742do
743local setmetatable,assert,type,print,getmetatable = setmetatable,assert,type,print,getmetatable
743local setmetatable,assert,type,print,getmetatable = setmetatable,assert,type,print,getmetatable
744local tt = {}
744local tt = {}
745tt.__gc=function (o)
745tt.__gc=function (o)
746assert(getmetatable(o) == tt)
746assert(getmetatable(o) == tt)
747−local a = "\u{78}\u{75}\u{78}\u{75}" .. (10 + 3) .. "\u{6a}\u{6f}\u{61}\u{6f}",{}
747+local a = "\u{78}\u{75}\u{78}\u{75}" .. (0xa + 0x3) .. "\u{6a}\u{6f}\u{61}\u{6f}",{}
748___Glob=o
748___Glob=o
749setmetatable({},tt)
749setmetatable({},tt)
750print("\u{3e}\u{3e}\u{3e}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{74}\u{65}\u{20}" .. "\u{3c}\u{3c}\u{3c}\u{a}")
750print("\u{3e}\u{3e}\u{3e}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{61}\u{74}\u{65}\u{20}" .. "\u{3c}\u{3c}\u{3c}\u{a}")
@@ -754,14 +754,14 @@ ___Glob={u}
754end
754end
755if T then
755if T then
756local error,assert,find,warn = error,assert,string.find,warn
756local error,assert,find,warn = error,assert,string.find,warn
757−local n = 0
757+local n = 0x0
758local lastmsg
758local lastmsg
759local mt = {["\u{5f}\u{5f}\u{67}\u{63}"] = function (o)
759local mt = {["\u{5f}\u{5f}\u{67}\u{63}"] = function (o)
760−n=n + 1
760+n=n + 0x1
761−assert(n == o[1])
761+assert(n == o[0x1])
762−if n == 1 then
762+if n == 0x1 then
763_WARN=false
763_WARN=false
764−elseif n == 2 then
764+elseif n == 0x2 then
765assert(find(_WARN,"\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}"))
765assert(find(_WARN,"\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}"))
766lastmsg=_WARN
766lastmsg=_WARN
767else
767else
@@ -772,7 +772,7 @@ warn("\u{40}\u{73}\u{74}\u{6f}\u{72}\u{65}")
772_WARN=false
772_WARN=false
773error("\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}")
773error("\u{40}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{77}\u{61}\u{72}\u{6e}\u{69}\u{6e}\u{67}")
774end}
774end}
775−for i = 10, 1, - 1
775+for i = 0xa, 0x1, - 0x1
776do
776do
777table.insert(___Glob,setmetatable({i},mt))
777table.insert(___Glob,setmetatable({i},mt))
778end
778end
zod/luau/res/lua/cycled/gengc.lua+36−36
@@ -7,83 +7,83 @@ do
7local U = {}
7local U = {}
8collectgarbage()
8collectgarbage()
9assert(not T or T.gcage(U) == "\u{6f}\u{6c}\u{64}")
9assert(not T or T.gcage(U) == "\u{6f}\u{6c}\u{64}")
10−U[1]={["\u{78}"] = {234}}
10+U[0x1]={["\u{78}"] = {0xea}}
11−assert(not T or (T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{31}" and T.gcage(U[1]) == "\u{6e}\u{65}\u{77}"))
11+assert(not T or (T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{31}" and T.gcage(U[0x1]) == "\u{6e}\u{65}\u{77}"))
12−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
12+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
13−assert(not T or (T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{32}" and T.gcage(U[1]) == "\u{73}\u{75}\u{72}\u{76}\u{69}\u{76}\u{61}\u{6c}"))
13+assert(not T or (T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{32}" and T.gcage(U[0x1]) == "\u{73}\u{75}\u{72}\u{76}\u{69}\u{76}\u{61}\u{6c}"))
14−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
14+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
15−assert(not T or (T.gcage(U) == "\u{6f}\u{6c}\u{64}" and T.gcage(U[1]) == "\u{6f}\u{6c}\u{64}\u{31}"))
15+assert(not T or (T.gcage(U) == "\u{6f}\u{6c}\u{64}" and T.gcage(U[0x1]) == "\u{6f}\u{6c}\u{64}\u{31}"))
16−assert(U[1].x[1] == 234)
16+assert(U[0x1].x[0x1] == 0xea)
17end
17end
18do
18do
19local function foo
19local function foo
20()
20()
21
21
22end
22end
23−local old = {10}
23+local old = {0xa}
24collectgarbage()
24collectgarbage()
25assert(not T or T.gcage(old) == "\u{6f}\u{6c}\u{64}")
25assert(not T or T.gcage(old) == "\u{6f}\u{6c}\u{64}")
26setmetatable(old,{})
26setmetatable(old,{})
27assert(not T or T.gcage(getmetatable(old)) == "\u{6f}\u{6c}\u{64}\u{30}")
27assert(not T or T.gcage(getmetatable(old)) == "\u{6f}\u{6c}\u{64}\u{30}")
28−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
28+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
29assert(not T or T.gcage(getmetatable(old)) == "\u{6f}\u{6c}\u{64}\u{31}")
29assert(not T or T.gcage(getmetatable(old)) == "\u{6f}\u{6c}\u{64}\u{31}")
30setmetatable(getmetatable(old),{["\u{5f}\u{5f}\u{67}\u{63}"] = foo})
30setmetatable(getmetatable(old),{["\u{5f}\u{5f}\u{67}\u{63}"] = foo})
31−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
31+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
32end
32end
33do
33do
34local A = {}
34local A = {}
35−A[1]=false
35+A[0x1]=false
36local function gcf
36local function gcf
37(obj)
37(obj)
38−A[1]=obj
38+A[0x1]=obj
39assert(not T or T.gcage(obj) == "\u{6f}\u{6c}\u{64}\u{31}")
39assert(not T or T.gcage(obj) == "\u{6f}\u{6c}\u{64}\u{31}")
40obj=nil
40obj=nil
41−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
41+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
42−print(getmetatable(A[1]).x)
42+print(getmetatable(A[0x1]).x)
43end
43end
44collectgarbage()
44collectgarbage()
45local obj = {}
45local obj = {}
46−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
46+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
47assert(not T or T.gcage(obj) == "\u{73}\u{75}\u{72}\u{76}\u{69}\u{76}\u{61}\u{6c}")
47assert(not T or T.gcage(obj) == "\u{73}\u{75}\u{72}\u{76}\u{69}\u{76}\u{61}\u{6c}")
48setmetatable(obj,{["\u{5f}\u{5f}\u{67}\u{63}"] = gcf,["\u{78}"] = "\u{2b}"})
48setmetatable(obj,{["\u{5f}\u{5f}\u{67}\u{63}"] = gcf,["\u{78}"] = "\u{2b}"})
49assert(not T or T.gcage(getmetatable(obj)) == "\u{6e}\u{65}\u{77}")
49assert(not T or T.gcage(getmetatable(obj)) == "\u{6e}\u{65}\u{77}")
50obj=nil
50obj=nil
51−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
51+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
52end
52end
53do
53do
54−local old = {10}
54+local old = {0xa}
55collectgarbage()
55collectgarbage()
56local co = coroutine.create(function ()
56local co = coroutine.create(function ()
57local x = nil
57local x = nil
58local f = function ()
58local f = function ()
59−return x[1]
59+return x[0x1]
60end
60end
61x=coroutine.yield(f)
61x=coroutine.yield(f)
62coroutine.yield()
62coroutine.yield()
63end)
63end)
64local _,f = coroutine.resume(co)
64local _,f = coroutine.resume(co)
65−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
65+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
66−old[1]={"\u{68}\u{65}\u{6c}\u{6c}\u{6f}"}
66+old[0x1]={"\u{68}\u{65}\u{6c}\u{6c}\u{6f}"}
67−coroutine.resume(co,{123})
67+coroutine.resume(co,{0x7b})
68co=nil
68co=nil
69−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
69+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
70−assert(f() == 123 and old[1][1] == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
70+assert(f() == 0x7b and old[0x1][0x1] == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
71−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
71+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
72−assert(f() == 123 and old[1][1] == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
72+assert(f() == 0x7b and old[0x1][0x1] == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}")
73end
73end
74do
74do
75local t = setmetatable({},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
75local t = setmetatable({},{["\u{5f}\u{5f}\u{6d}\u{6f}\u{64}\u{65}"] = "\u{6b}\u{76}"})
76collectgarbage()
76collectgarbage()
77assert(not T or T.gcage(t) == "\u{6f}\u{6c}\u{64}")
77assert(not T or T.gcage(t) == "\u{6f}\u{6c}\u{64}")
78−t[1]={10}
78+t[0x1]={0xa}
79assert(not T or (T.gcage(t) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{31}" and T.gccolor(t) == "\u{67}\u{72}\u{61}\u{79}"))
79assert(not T or (T.gcage(t) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{31}" and T.gccolor(t) == "\u{67}\u{72}\u{61}\u{79}"))
80−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
80+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
81assert(not T or (T.gcage(t) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{32}" and T.gccolor(t) == "\u{62}\u{6c}\u{61}\u{63}\u{6b}"))
81assert(not T or (T.gcage(t) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{32}" and T.gccolor(t) == "\u{62}\u{6c}\u{61}\u{63}\u{6b}"))
82−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
82+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
83assert(not T or T.gcage(t) == "\u{6f}\u{6c}\u{64}")
83assert(not T or T.gcage(t) == "\u{6f}\u{6c}\u{64}")
84−t[1]={10}
84+t[0x1]={0xa}
85−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
85+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
86−assert(t[1] == nil)
86+assert(t[0x1] == nil)
87end
87end
88if T == nil then
88if T == nil then
89(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{6f}\u{6d}\u{65}\u{20}\u{67}\u{65}\u{6e}\u{65}\u{72}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{61}\u{6c}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
89(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{6f}\u{6d}\u{65}\u{20}\u{67}\u{65}\u{6e}\u{65}\u{72}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{61}\u{6c}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
@@ -91,16 +91,16 @@ print("\u{4f}\u{4b}")
91return
91return
92end
92end
93do
93do
94−local U = T.newuserdata(0,1)
94+local U = T.newuserdata(0x0,0x1)
95collectgarbage()
95collectgarbage()
96assert(T.gcage(U) == "\u{6f}\u{6c}\u{64}")
96assert(T.gcage(U) == "\u{6f}\u{6c}\u{64}")
97−debug.setuservalue(U,{["\u{78}"] = {234}})
97+debug.setuservalue(U,{["\u{78}"] = {0xea}})
98assert(T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{31}" and T.gcage(debug.getuservalue(U)) == "\u{6e}\u{65}\u{77}")
98assert(T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{31}" and T.gcage(debug.getuservalue(U)) == "\u{6e}\u{65}\u{77}")
99−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
99+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
100assert(T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{32}" and T.gcage(debug.getuservalue(U)) == "\u{73}\u{75}\u{72}\u{76}\u{69}\u{76}\u{61}\u{6c}")
100assert(T.gcage(U) == "\u{74}\u{6f}\u{75}\u{63}\u{68}\u{65}\u{64}\u{32}" and T.gcage(debug.getuservalue(U)) == "\u{73}\u{75}\u{72}\u{76}\u{69}\u{76}\u{61}\u{6c}")
101−collectgarbage("\u{73}\u{74}\u{65}\u{70}",0)
101+collectgarbage("\u{73}\u{74}\u{65}\u{70}",0x0)
102assert(T.gcage(U) == "\u{6f}\u{6c}\u{64}" and T.gcage(debug.getuservalue(U)) == "\u{6f}\u{6c}\u{64}\u{31}")
102assert(T.gcage(U) == "\u{6f}\u{6c}\u{64}" and T.gcage(debug.getuservalue(U)) == "\u{6f}\u{6c}\u{64}\u{31}")
103−assert(debug.getuservalue(U).x[1] == 234)
103+assert(debug.getuservalue(U).x[0x1] == 0xea)
104end
104end
105assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
105assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
106assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
106assert(collectgarbage("\u{69}\u{73}\u{72}\u{75}\u{6e}\u{6e}\u{69}\u{6e}\u{67}"))
zod/luau/res/lua/cycled/goto.lua+52−52
@@ -15,10 +15,10 @@ errmsg("\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{6c}\u{31}\u{20}\u{64}\u{6f}\u{20}
15errmsg("\u{20}\u{20}\u{72}\u{65}\u{70}\u{65}\u{61}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{78}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{75}\u{78}\u{75}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{63}\u{6f}\u{6e}\u{74}\u{3a}\u{3a}\u{a}\u{20}\u{20}\u{75}\u{6e}\u{74}\u{69}\u{6c}\u{20}\u{78}\u{75}\u{78}\u{75}\u{20}\u{3c}\u{20}\u{78}\u{a}","\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{27}\u{78}\u{75}\u{78}\u{75}\u{27}")
15errmsg("\u{20}\u{20}\u{72}\u{65}\u{70}\u{65}\u{61}\u{74}\u{a}\u{20}\u{20}\u{20}\u{20}\u{69}\u{66}\u{20}\u{78}\u{20}\u{74}\u{68}\u{65}\u{6e}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{63}\u{6f}\u{6e}\u{74}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{75}\u{78}\u{75}\u{20}\u{3d}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{63}\u{6f}\u{6e}\u{74}\u{3a}\u{3a}\u{a}\u{20}\u{20}\u{75}\u{6e}\u{74}\u{69}\u{6c}\u{20}\u{78}\u{75}\u{78}\u{75}\u{20}\u{3c}\u{20}\u{78}\u{a}","\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{27}\u{78}\u{75}\u{78}\u{75}\u{27}")
16local x
16local x
17do
17do
18−local y = 12
18+local y = 0xc
19goto l1
19goto l1
20::l2::
20::l2::
21−x=x + 1
21+x=x + 0x1
22;
22;
23goto l3
23goto l3
24::l1::
24::l1::
@@ -28,16 +28,16 @@ goto l2
28end
28end
29::l3::
29::l3::
30::l3_1::
30::l3_1::
31−assert(x == 13)
31+assert(x == 0xd)
32do
32do
33local prog = "\u{20}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{6c}\u{25}\u{73}\u{61}\u{3b}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{6c}\u{25}\u{73}\u{61}\u{3a}\u{3a}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{6c}\u{25}\u{73}\u{62}\u{3b}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{6c}\u{25}\u{73}\u{62}\u{3a}\u{3a}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{32}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}"
33local prog = "\u{20}\u{20}\u{64}\u{6f}\u{a}\u{20}\u{20}\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{6c}\u{25}\u{73}\u{61}\u{3b}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{6c}\u{25}\u{73}\u{61}\u{3a}\u{3a}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{67}\u{6f}\u{74}\u{6f}\u{20}\u{6c}\u{25}\u{73}\u{62}\u{3b}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{3a}\u{3a}\u{6c}\u{25}\u{73}\u{62}\u{3a}\u{3a}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{32}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{a}\u{20}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}"
34−local label = string.rep("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",40)
34+local label = string.rep("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x28)
35prog=string.format(prog,label,label,label,label)
35prog=string.format(prog,label,label,label,label)
36−assert(assert(load(prog))() == 31)
36+assert(assert(load(prog))() == 0x1f)
37end
37end
38do
38do
39goto l1
39goto l1
40−local a = 23
40+local a = 0x17
41x=a
41x=a
42::l1::
42::l1::
43;
43;
@@ -46,14 +46,14 @@ while true do
46goto l4
46goto l4
47goto l1
47goto l1
48goto l1
48goto l1
49−local x = 45
49+local x = 0x2d
50::l1::
50::l1::
51;
51;
52;
52;
53;
53;
54end
54end
55::l4::
55::l4::
56−assert(x == 13)
56+assert(x == 0xd)
57if print then
57if print then
58goto l1
58goto l1
59error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}")
59error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}")
@@ -72,35 +72,35 @@ local function foo
72local a = {}
72local a = {}
73goto l3
73goto l3
74::l1::
74::l1::
75−a[# a + 1]=1
75+a[# a + 0x1]=0x1
76;
76;
77goto l2
77goto l2
78;
78;
79::l2::
79::l2::
80−a[# a + 1]=2
80+a[# a + 0x1]=0x2
81;
81;
82goto l5
82goto l5
83;
83;
84::l3::
84::l3::
85::l3a::
85::l3a::
86−a[# a + 1]=3
86+a[# a + 0x1]=0x3
87;
87;
88goto l1
88goto l1
89;
89;
90::l4::
90::l4::
91−a[# a + 1]=4
91+a[# a + 0x1]=0x4
92;
92;
93goto l6
93goto l6
94;
94;
95::l5::
95::l5::
96−a[# a + 1]=5
96+a[# a + 0x1]=0x5
97;
97;
98goto l4
98goto l4
99;
99;
100::l6::
100::l6::
101−assert(a[1] == 3 and a[2] == 1 and a[3] == 2 and a[4] == 5 and a[5] == 4)
101+assert(a[0x1] == 0x3 and a[0x2] == 0x1 and a[0x3] == 0x2 and a[0x4] == 0x5 and a[0x5] == 0x4)
102−if not a[6] then
102+if not a[0x6] then
103−a[6]=true
103+a[0x6]=true
104;
104;
105goto l3a
105goto l3a
106end
106end
@@ -114,12 +114,12 @@ local y
114assert(y == nil)
114assert(y == nil)
115y=true
115y=true
116if x == nil then
116if x == nil then
117−x=1
117+x=0x1
118goto L1
118goto L1
119else
119else
120−x=x + 1
120+x=x + 0x1
121end
121end
122−assert(x == 2 and y == true)
122+assert(x == 0x2 and y == true)
123end
123end
124do
124do
125local first = true
125local first = true
@@ -151,27 +151,27 @@ local function foo
151()
151()
152local t = {}
152local t = {}
153do
153do
154−local i = 1
154+local i = 0x1
155local a,b,c,d
155local a,b,c,d
156−t[1]=function ()
156+t[0x1]=function ()
157return a,b,c,d
157return a,b,c,d
158end
158end
159::l1::
159::l1::
160local b
160local b
161do
161do
162local c
162local c
163−t[# t + 1]=function ()
163+t[# t + 0x1]=function ()
164return a,b,c,d
164return a,b,c,d
165end
165end
166−if i > 2 then
166+if i > 0x2 then
167goto l2
167goto l2
168end
168end
169do
169do
170local d
170local d
171−t[# t + 1]=function ()
171+t[# t + 0x1]=function ()
172return a,b,c,d
172return a,b,c,d
173end
173end
174−i=i + 1
174+i=i + 0x1
175local a
175local a
176goto l1
176goto l1
177end
177end
@@ -181,52 +181,52 @@ end
181return t
181return t
182end
182end
183local a = foo()
183local a = foo()
184−assert(# a == 6)
184+assert(# a == 0x6)
185−for i = 2, 6
185+for i = 0x2, 0x6
186do
186do
187−assert(debug.upvalueid(a[1],1) == debug.upvalueid(a[i],1))
187+assert(debug.upvalueid(a[0x1],0x1) == debug.upvalueid(a[i],0x1))
188end
188end
189−for i = 2, 6
189+for i = 0x2, 0x6
190do
190do
191−assert(debug.upvalueid(a[1],2) ~= debug.upvalueid(a[i],2))
191+assert(debug.upvalueid(a[0x1],0x2) ~= debug.upvalueid(a[i],0x2))
192−assert(debug.upvalueid(a[1],3) ~= debug.upvalueid(a[i],3))
192+assert(debug.upvalueid(a[0x1],0x3) ~= debug.upvalueid(a[i],0x3))
193end
193end
194−for i = 3, 5, 2
194+for i = 0x3, 0x5, 0x2
195do
195do
196−assert(debug.upvalueid(a[i],2) == debug.upvalueid(a[i - 1],2))
196+assert(debug.upvalueid(a[i],0x2) == debug.upvalueid(a[i - 0x1],0x2))
197−assert(debug.upvalueid(a[i],3) == debug.upvalueid(a[i - 1],3))
197+assert(debug.upvalueid(a[i],0x3) == debug.upvalueid(a[i - 0x1],0x3))
198−assert(debug.upvalueid(a[i],2) ~= debug.upvalueid(a[i + 1],2))
198+assert(debug.upvalueid(a[i],0x2) ~= debug.upvalueid(a[i + 0x1],0x2))
199−assert(debug.upvalueid(a[i],3) ~= debug.upvalueid(a[i + 1],3))
199+assert(debug.upvalueid(a[i],0x3) ~= debug.upvalueid(a[i + 0x1],0x3))
200end
200end
201−for i = 2, 6, 2
201+for i = 0x2, 0x6, 0x2
202do
202do
203−assert(debug.upvalueid(a[1],4) == debug.upvalueid(a[i],4))
203+assert(debug.upvalueid(a[0x1],0x4) == debug.upvalueid(a[i],0x4))
204end
204end
205−for i = 3, 5, 2
205+for i = 0x3, 0x5, 0x2
206do
206do
207−for j = 1, 6
207+for j = 0x1, 0x6
208do
208do
209−assert((debug.upvalueid(a[i],4) == debug.upvalueid(a[j],4)) == (i == j))
209+assert((debug.upvalueid(a[i],0x4) == debug.upvalueid(a[j],0x4)) == (i == j))
210end
210end
211end
211end
212local function testG
212local function testG
213(a)
213(a)
214−if a == 1 then
214+if a == 0x1 then
215goto l1
215goto l1
216error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
216error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
217−elseif a == 2 then
217+elseif a == 0x2 then
218goto l2
218goto l2
219−elseif a == 3 then
219+elseif a == 0x3 then
220goto l3
220goto l3
221−elseif a == 4 then
221+elseif a == 0x4 then
222goto l1
222goto l1
223error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
223error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
224::l1::
224::l1::
225−a=a + 1
225+a=a + 0x1
226else
226else
227goto l4
227goto l4
228::l4a::
228::l4a::
229−a=a * 2
229+a=a * 0x2
230;
230;
231goto l4b
231goto l4b
232error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
232error("\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{6e}\u{65}\u{76}\u{65}\u{72}\u{20}\u{62}\u{65}\u{20}\u{68}\u{65}\u{72}\u{65}\u{21}")
@@ -249,11 +249,11 @@ end
249::l1::
249::l1::
250return "\u{31}"
250return "\u{31}"
251end
251end
252−assert(testG(1) == "\u{31}")
252+assert(testG(0x1) == "\u{31}")
253−assert(testG(2) == "\u{32}")
253+assert(testG(0x2) == "\u{32}")
254−assert(testG(3) == "\u{33}")
254+assert(testG(0x3) == "\u{33}")
255−assert(testG(4) == 5)
255+assert(testG(0x4) == 0x5)
256−assert(testG(5) == 10)
256+assert(testG(0x5) == 0xa)
257do
257do
258local X
258local X
259goto L1
259goto L1
zod/luau/res/lua/cycled/heavy.lua+23−23
@@ -10,37 +10,37 @@ print(string.format("\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{77}\u{69}\u{74
10end
10end
11end)
11end)
12assert(not st and (string.find(msg,"\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}") or string.find(msg,"\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")))
12assert(not st and (string.find(msg,"\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}") or string.find(msg,"\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")))
13−print("\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}" .. # a * 100)
13+print("\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}" .. # a * 0x64)
14end
14end
15print("\u{2b}")
15print("\u{2b}")
16end
16end
17local function loadrep
17local function loadrep
18(x,what)
18(x,what)
19−local p = 1 << 20
19+local p = 0x1 << 0x14
20local s = string.rep(x,p)
20local s = string.rep(x,p)
21−local count = 0
21+local count = 0x0
22local function f
22local function f
23()
23()
24count=count + p
24count=count + p
25−if count % (128 * p) == 0 then
25+if count % (0x80 * p) == 0x0 then
26−io.stderr:write("\u{28}",count // 2 ^ 20,"\u{20}\u{4d}\u{29}")
26+io.stderr:write("\u{28}",count // 0x2 ^ 0x14,"\u{20}\u{4d}\u{29}")
27end
27end
28return s
28return s
29end
29end
30local st,msg = load(f,"\u{3d}\u{62}\u{69}\u{67}")
30local st,msg = load(f,"\u{3d}\u{62}\u{69}\u{67}")
31−print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}",collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 1024)
31+print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}",collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 0x400)
32msg=string.match(msg,"\u{5e}\u{5b}\u{5e}\u{a}\u{5d}\u{2b}")
32msg=string.match(msg,"\u{5e}\u{5b}\u{5e}\u{a}\u{5d}\u{2b}")
33print(string.format("\u{74}\u{6f}\u{74}\u{61}\u{6c}\u{3a}\u{20}\u{30}\u{78}\u{25}\u{78}\u{20}\u{25}\u{73}\u{20}\u{28}\u{27}\u{25}\u{73}\u{27}\u{29}",count,what,msg))
33print(string.format("\u{74}\u{6f}\u{74}\u{61}\u{6c}\u{3a}\u{20}\u{30}\u{78}\u{25}\u{78}\u{20}\u{25}\u{73}\u{20}\u{28}\u{27}\u{25}\u{73}\u{27}\u{29}",count,what,msg))
34return st,msg
34return st,msg
35end
35end
36function controlstruct()
36function controlstruct()
37print("\u{63}\u{6f}\u{6e}\u{74}\u{72}\u{6f}\u{6c}\u{20}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{75}\u{72}\u{65}\u{20}\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{6f}\u{6e}\u{67}")
37print("\u{63}\u{6f}\u{6e}\u{74}\u{72}\u{6f}\u{6c}\u{20}\u{73}\u{74}\u{72}\u{75}\u{63}\u{74}\u{75}\u{72}\u{65}\u{20}\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{6f}\u{6e}\u{67}")
38−local lim = ((1 << 24) - 2) // 3
38+local lim = ((0x1 << 0x18) - 0x2) // 0x3
39local s = string.rep("\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{a}",lim)
39local s = string.rep("\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{a}",lim)
40s="\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{64}\u{6f}\u{20}" .. s .. "\u{65}\u{6e}\u{64}"
40s="\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{64}\u{6f}\u{20}" .. s .. "\u{65}\u{6e}\u{64}"
41assert(load(s))
41assert(load(s))
42print("\u{6f}\u{6b}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}" .. lim .. "\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{73}")
42print("\u{6f}\u{6b}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}" .. lim .. "\u{20}\u{6c}\u{69}\u{6e}\u{65}\u{73}")
43−lim=lim + 3
43+lim=lim + 0x3
44s=string.rep("\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{a}",lim)
44s=string.rep("\u{61}\u{20}\u{3d}\u{20}\u{61}\u{20}\u{2b}\u{20}\u{31}\u{a}",lim)
45s="\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{64}\u{6f}\u{20}" .. s .. "\u{65}\u{6e}\u{64}"
45s="\u{77}\u{68}\u{69}\u{6c}\u{65}\u{20}\u{74}\u{72}\u{75}\u{65}\u{20}\u{64}\u{6f}\u{20}" .. s .. "\u{65}\u{6e}\u{64}"
46local st,msg = load(s)
46local st,msg = load(s)
@@ -66,59 +66,59 @@ print("\u{2b}")
66end
66end
67local function loadrepfunc
67local function loadrepfunc
68(prefix,f)
68(prefix,f)
69−local count = - 1
69+local count = - 0x1
70local function aux
70local function aux
71()
71()
72−count=count + 1
72+count=count + 0x1
73−if count == 0 then
73+if count == 0x0 then
74return prefix
74return prefix
75else
75else
76−if count % (1048576) == 0 then
76+if count % (0x100000) == 0x0 then
77−io.stderr:write("\u{28}",count // 2 ^ 20,"\u{20}\u{4d}\u{29}")
77+io.stderr:write("\u{28}",count // 0x2 ^ 0x14,"\u{20}\u{4d}\u{29}")
78end
78end
79return f(count)
79return f(count)
80end
80end
81end
81end
82local st,msg = load(aux,"\u{6b}")
82local st,msg = load(aux,"\u{6b}")
83−print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}",collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 1024)
83+print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}",collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 0x400)
84msg=string.match(msg,"\u{5e}\u{5b}\u{5e}\u{a}\u{5d}\u{2b}")
84msg=string.match(msg,"\u{5e}\u{5b}\u{5e}\u{a}\u{5d}\u{2b}")
85print("\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3a}\u{20}",msg)
85print("\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3a}\u{20}",msg)
86end
86end
87function toomanyconst()
87function toomanyconst()
88print("\u{6c}\u{6f}\u{61}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}\u{73}")
88print("\u{6c}\u{6f}\u{61}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}\u{73}")
89loadrepfunc("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{7b}\u{30}\u{2c}",function (n)
89loadrepfunc("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{6f}\u{6f}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{7b}\u{30}\u{2c}",function (n)
90−return string.char(34,((n // 128 ^ 0) & 127) + 128,((n // 128 ^ 1) & 127) + 128,((n // 128 ^ 2) & 127) + 128,((n // 128 ^ 3) & 127) + 128,((n // 128 ^ 4) & 127) + 128,34,44)
90+return string.char(0x22,((n // 0x80 ^ 0x0) & 0x7f) + 0x80,((n // 0x80 ^ 0x1) & 0x7f) + 0x80,((n // 0x80 ^ 0x2) & 0x7f) + 0x80,((n // 0x80 ^ 0x3) & 0x7f) + 0x80,((n // 0x80 ^ 0x4) & 0x7f) + 0x80,0x22,0x2c)
91end)
91end)
92end
92end
93function toomanystr()
93function toomanystr()
94local a = {}
94local a = {}
95local st,msg = pcall(function ()
95local st,msg = pcall(function ()
96−for i = 1, math.huge
96+for i = 0x1, math.huge
97do
97do
98−if i % (1048576) == 0 then
98+if i % (0x100000) == 0x0 then
99−io.stderr:write("\u{28}",i // 2 ^ 20,"\u{20}\u{4d}\u{29}")
99+io.stderr:write("\u{28}",i // 0x2 ^ 0x14,"\u{20}\u{4d}\u{29}")
100end
100end
101a[i]=string.pack("\u{49}",i)
101a[i]=string.pack("\u{49}",i)
102end
102end
103end)
103end)
104local size = # a
104local size = # a
105a=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
105a=collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}")
106−print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}",a * 1024)
106+print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}",a * 0x400)
107print("\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3a}",msg)
107print("\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3a}",msg)
108print("\u{73}\u{69}\u{7a}\u{65}\u{3a}",size)
108print("\u{73}\u{69}\u{7a}\u{65}\u{3a}",size)
109end
109end
110function toomanyidx()
110function toomanyidx()
111local a = {}
111local a = {}
112local st,msg = pcall(function ()
112local st,msg = pcall(function ()
113−for i = 1, math.huge
113+for i = 0x1, math.huge
114do
114do
115−if i % (1048576) == 0 then
115+if i % (0x100000) == 0x0 then
116−io.stderr:write("\u{28}",i // 2 ^ 20,"\u{20}\u{4d}\u{29}")
116+io.stderr:write("\u{28}",i // 0x2 ^ 0x14,"\u{20}\u{4d}\u{29}")
117end
117end
118a[i]=i
118a[i]=i
119end
119end
120end)
120end)
121−print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}",collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 1024)
121+print("\u{a}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}\u{3a}\u{20}",collectgarbage("\u{63}\u{6f}\u{75}\u{6e}\u{74}") * 0x400)
122print("\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3a}\u{20}",msg)
122print("\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}\u{20}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{3a}\u{20}",msg)
123print("\u{73}\u{69}\u{7a}\u{65}\u{3a}",# a)
123print("\u{73}\u{69}\u{7a}\u{65}\u{3a}",# a)
124end
124end
zod/luau/res/lua/cycled/literals.lua+19−19
@@ -5,7 +5,7 @@ local function dostring
5return assert(load(x),"")()
5return assert(load(x),"")()
6end
6end
7dostring("\u{78}\u{20}\u{b}\u{c}\u{20}\u{3d}\u{20}\u{9}\u{d}\u{20}\u{27}\u{61}\u{0}\u{61}\u{27}\u{20}\u{b}\u{c}\u{c}")
7dostring("\u{78}\u{20}\u{b}\u{c}\u{20}\u{3d}\u{20}\u{9}\u{d}\u{20}\u{27}\u{61}\u{0}\u{61}\u{27}\u{20}\u{b}\u{c}\u{c}")
8−assert(x == "\u{61}\u{0}\u{61}" and string.len(x) == 3)
8+assert(x == "\u{61}\u{0}\u{61}" and string.len(x) == 0x3)
9_G.x=nil
9_G.x=nil
10assert("\u{a}\u{22}\u{27}\u{5c}" == "\u{a}\u{22}\u{27}\u{5c}")
10assert("\u{a}\u{22}\u{27}\u{5c}" == "\u{a}\u{22}\u{27}\u{5c}")
11assert(string.find("\u{7}\u{8}\u{c}\u{a}\u{d}\u{9}\u{b}","\u{5e}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{24}"))
11assert(string.find("\u{7}\u{8}\u{c}\u{a}\u{d}\u{9}\u{b}","\u{5e}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{25}\u{63}\u{24}"))
@@ -14,7 +14,7 @@ assert("\u{63}\u{61}\u{62}" == "\u{63}\u{61}\u{62}")
14assert("\u{63}" == "\u{63}")
14assert("\u{63}" == "\u{63}")
15assert("\u{63}\u{a}" == "\u{63}\u{a}")
15assert("\u{63}\u{a}" == "\u{63}\u{a}")
16assert("\u{0}\u{0}\u{0}\u{61}\u{6c}\u{6f}" == "\u{0}" .. "\u{0}\u{0}" .. "\u{61}\u{6c}\u{6f}")
16assert("\u{0}\u{0}\u{0}\u{61}\u{6c}\u{6f}" == "\u{0}" .. "\u{0}\u{0}" .. "\u{61}\u{6c}\u{6f}")
17−assert(10 .. 20 .. - 30 == "\u{31}\u{30}\u{32}\u{30}\u{2d}\u{33}\u{30}")
17+assert(0xa .. 0x14 .. - 0x1e == "\u{31}\u{30}\u{32}\u{30}\u{2d}\u{33}\u{30}")
18assert("\u{0}\u{5}\u{10}\u{1f}\u{3c}\u{ff}\u{e8}" == "\u{0}\u{5}\u{10}\u{1f}\u{3c}\u{ff}\u{e8}")
18assert("\u{0}\u{5}\u{10}\u{1f}\u{3c}\u{ff}\u{e8}" == "\u{0}\u{5}\u{10}\u{1f}\u{3c}\u{ff}\u{e8}")
19local function lexstring
19local function lexstring
20(x,y,n)
20(x,y,n)
@@ -22,16 +22,16 @@ local f = assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. x .. "\u{2
22local s,l = f()
22local s,l = f()
23assert(s == y and l == n)
23assert(s == y and l == n)
24end
24end
25−lexstring("\u{27}\u{61}\u{62}\u{63}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{20}\u{20}\u{20}\u{65}\u{66}\u{67}\u{27}","\u{61}\u{62}\u{63}\u{65}\u{66}\u{67}",2)
25+lexstring("\u{27}\u{61}\u{62}\u{63}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{20}\u{20}\u{20}\u{65}\u{66}\u{67}\u{27}","\u{61}\u{62}\u{63}\u{65}\u{66}\u{67}",0x2)
26−lexstring("\u{27}\u{61}\u{62}\u{63}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{a}\u{a}\u{27}","\u{61}\u{62}\u{63}",4)
26+lexstring("\u{27}\u{61}\u{62}\u{63}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{a}\u{a}\u{27}","\u{61}\u{62}\u{63}",0x4)
27−lexstring("\u{27}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{9}\u{c}\u{b}\u{a}\u{27}","",3)
27+lexstring("\u{27}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{9}\u{c}\u{b}\u{a}\u{27}","",0x3)
28−lexstring("\u{5b}\u{5b}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{a}",5)
28+lexstring("\u{5b}\u{5b}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{a}",0x5)
29−lexstring("\u{5b}\u{5b}\u{a}\u{61}\u{6c}\u{6f}\u{d}\u{61}\u{6c}\u{6f}\u{a}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{a}",5)
29+lexstring("\u{5b}\u{5b}\u{a}\u{61}\u{6c}\u{6f}\u{d}\u{61}\u{6c}\u{6f}\u{a}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}\u{a}",0x5)
30−lexstring("\u{5b}\u{5b}\u{a}\u{61}\u{6c}\u{6f}\u{d}\u{61}\u{6c}\u{6f}\u{d}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}",4)
30+lexstring("\u{5b}\u{5b}\u{a}\u{61}\u{6c}\u{6f}\u{d}\u{61}\u{6c}\u{6f}\u{d}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}",0x4)
31−lexstring("\u{5b}\u{5b}\u{d}\u{61}\u{6c}\u{6f}\u{a}\u{d}\u{61}\u{6c}\u{6f}\u{d}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}",4)
31+lexstring("\u{5b}\u{5b}\u{d}\u{61}\u{6c}\u{6f}\u{a}\u{d}\u{61}\u{6c}\u{6f}\u{d}\u{a}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{a}\u{61}\u{6c}\u{6f}\u{a}",0x4)
32−lexstring("\u{5b}\u{5b}\u{61}\u{6c}\u{6f}\u{5d}\u{a}\u{5d}\u{61}\u{6c}\u{6f}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{5d}\u{a}\u{5d}\u{61}\u{6c}\u{6f}",2)
32+lexstring("\u{5b}\u{5b}\u{61}\u{6c}\u{6f}\u{5d}\u{a}\u{5d}\u{61}\u{6c}\u{6f}\u{5d}\u{5d}","\u{61}\u{6c}\u{6f}\u{5d}\u{a}\u{5d}\u{61}\u{6c}\u{6f}",0x2)
33assert("\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}" == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}")
33assert("\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}" == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}")
34−assert("\u{0}\u{0}\u{0}\u{0}" == string.char(0,0,0,0))
34+assert("\u{0}\u{0}\u{0}\u{0}" == string.char(0x0,0x0,0x0,0x0))
35assert("\u{0}\u{7f}" == "\u{0}\u{7f}")
35assert("\u{0}\u{7f}" == "\u{0}\u{7f}")
36assert("\u{80}\u{7ff}" == "\u{c2}\u{80}\u{df}\u{bf}")
36assert("\u{80}\u{7ff}" == "\u{c2}\u{80}\u{df}\u{bf}")
37assert("\u{800}\u{ffff}" == "\u{e0}\u{a0}\u{80}\u{ef}\u{bf}\u{bf}")
37assert("\u{800}\u{ffff}" == "\u{e0}\u{a0}\u{80}\u{ef}\u{bf}\u{bf}")
@@ -76,24 +76,24 @@ lexerror("\u{27}\u{61}\u{6c}\u{6f}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
76lexerror("\u{27}\u{61}\u{6c}\u{6f}\u{20}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{a}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
76lexerror("\u{27}\u{61}\u{6c}\u{6f}\u{20}\u{5c}\u{7a}\u{20}\u{20}\u{a}\u{a}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
77lexerror("\u{27}\u{61}\u{6c}\u{6f}\u{20}\u{5c}\u{7a}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
77lexerror("\u{27}\u{61}\u{6c}\u{6f}\u{20}\u{5c}\u{7a}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
78lexerror("\u{27}\u{61}\u{6c}\u{6f}\u{20}\u{5c}\u{39}\u{38}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
78lexerror("\u{27}\u{61}\u{6c}\u{6f}\u{20}\u{5c}\u{39}\u{38}","\u{3c}\u{65}\u{6f}\u{66}\u{3e}")
79−for i = 0, 255
79+for i = 0x0, 0xff
80do
80do
81local s = string.char(i)
81local s = string.char(i)
82assert(not string.find(s,"\u{5b}\u{61}\u{2d}\u{7a}\u{41}\u{2d}\u{5a}\u{5f}\u{5d}") == not load(s .. "\u{3d}\u{31}",""))
82assert(not string.find(s,"\u{5b}\u{61}\u{2d}\u{7a}\u{41}\u{2d}\u{5a}\u{5f}\u{5d}") == not load(s .. "\u{3d}\u{31}",""))
83assert(not string.find(s,"\u{5b}\u{61}\u{2d}\u{7a}\u{41}\u{2d}\u{5a}\u{5f}\u{30}\u{2d}\u{39}\u{5d}") == not load("\u{61}" .. s .. "\u{31}\u{20}\u{3d}\u{20}\u{31}",""))
83assert(not string.find(s,"\u{5b}\u{61}\u{2d}\u{7a}\u{41}\u{2d}\u{5a}\u{5f}\u{30}\u{2d}\u{39}\u{5d}") == not load("\u{61}" .. s .. "\u{31}\u{20}\u{3d}\u{20}\u{31}",""))
84end
84end
85−local var1 = string.rep("\u{61}",15000) .. "\u{31}"
85+local var1 = string.rep("\u{61}",0x3a98) .. "\u{31}"
86−local var2 = string.rep("\u{61}",15000) .. "\u{32}"
86+local var2 = string.rep("\u{61}",0x3a98) .. "\u{32}"
87local prog = string.format("\u{20}\u{20}\u{25}\u{73}\u{20}\u{3d}\u{20}\u{35}\u{a}\u{20}\u{20}\u{25}\u{73}\u{20}\u{3d}\u{20}\u{25}\u{73}\u{20}\u{2b}\u{20}\u{31}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{73}\u{20}\u{2d}\u{20}\u{25}\u{73}\u{20}\u{65}\u{6e}\u{64}\u{a}",var1,var2,var1,var1,var2)
87local prog = string.format("\u{20}\u{20}\u{25}\u{73}\u{20}\u{3d}\u{20}\u{35}\u{a}\u{20}\u{20}\u{25}\u{73}\u{20}\u{3d}\u{20}\u{25}\u{73}\u{20}\u{2b}\u{20}\u{31}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{28}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{73}\u{20}\u{2d}\u{20}\u{25}\u{73}\u{20}\u{65}\u{6e}\u{64}\u{a}",var1,var2,var1,var1,var2)
88local f = dostring(prog)
88local f = dostring(prog)
89−assert(_G[var1] == 5 and _G[var2] == 6 and f() == - 1)
89+assert(_G[var1] == 0x5 and _G[var2] == 0x6 and f() == - 0x1)
90_G[var1],_G[var2]=nil
90_G[var1],_G[var2]=nil
91print("\u{2b}")
91print("\u{2b}")
92assert("\u{a}\u{9}" == "\u{a}\u{9}")
92assert("\u{a}\u{9}" == "\u{a}\u{9}")
93assert("\u{a}\u{20}\u{24}\u{64}\u{65}\u{62}\u{75}\u{67}" == "\u{a}\u{20}\u{24}\u{64}\u{65}\u{62}\u{75}\u{67}")
93assert("\u{a}\u{20}\u{24}\u{64}\u{65}\u{62}\u{75}\u{67}" == "\u{a}\u{20}\u{24}\u{64}\u{65}\u{62}\u{75}\u{67}")
94assert("\u{20}\u{5b}\u{20}" ~= "\u{20}\u{5d}\u{20}")
94assert("\u{20}\u{5b}\u{20}" ~= "\u{20}\u{5d}\u{20}")
95local b = "\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
95local b = "\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"
96−assert(string.len(b) == 960)
96+assert(string.len(b) == 0x3c0)
97prog="\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{27}\u{2b}\u{27}\u{29}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{31}\u{20}\u{3d}\u{20}\u{5b}\u{5b}\u{22}\u{74}\u{68}\u{69}\u{73}\u{20}\u{69}\u{73}\u{20}\u{61}\u{20}\u{27}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{73}\u{65}\u{76}\u{65}\u{72}\u{61}\u{6c}\u{20}\u{27}\u{71}\u{75}\u{6f}\u{74}\u{65}\u{73}\u{27}\u{22}\u{5d}\u{5d}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{32}\u{20}\u{3d}\u{20}\u{22}\u{27}\u{71}\u{75}\u{6f}\u{74}\u{65}\u{73}\u{27}\u{22}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{66}\u{69}\u{6e}\u{64}\u{28}\u{61}\u{31}\u{2c}\u{20}\u{61}\u{32}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{33}\u{34}\u{29}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{27}\u{2b}\u{27}\u{29}\u{a}\u{a}\u{61}\u{31}\u{20}\u{3d}\u{20}\u{5b}\u{3d}\u{3d}\u{5b}\u{74}\u{65}\u{6d}\u{70}\u{20}\u{3d}\u{20}\u{5b}\u{5b}\u{61}\u{6e}\u{20}\u{61}\u{72}\u{62}\u{69}\u{74}\u{72}\u{61}\u{72}\u{79}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{5d}\u{5d}\u{3b}\u{20}\u{5d}\u{3d}\u{3d}\u{5d}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6c}\u{6f}\u{61}\u{64}\u{28}\u{61}\u{31}\u{29}\u{29}\u{28}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{65}\u{6d}\u{70}\u{20}\u{3d}\u{3d}\u{20}\u{27}\u{61}\u{6e}\u{20}\u{61}\u{72}\u{62}\u{69}\u{74}\u{72}\u{61}\u{72}\u{79}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{27}\u{29}\u{a}\u{5f}\u{47}\u{2e}\u{74}\u{65}\u{6d}\u{70}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{a}\u{2d}\u{2d}\u{20}\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}\u{20}\u{2d}\u{2d}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{22}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{22}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{6c}\u{65}\u{6e}\u{28}\u{62}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{39}\u{36}\u{30}\u{29}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{27}\u{2b}\u{27}\u{29}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{5b}\u{5b}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{5d}\u{5d}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{6c}\u{65}\u{6e}\u{28}\u{61}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{38}\u{36}\u{33}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{73}\u{75}\u{62}\u{28}\u{61}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{34}\u{30}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{73}\u{75}\u{62}\u{28}\u{62}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{34}\u{30}\u{29}\u{29}\u{a}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{a}"
97prog="\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{27}\u{2b}\u{27}\u{29}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{31}\u{20}\u{3d}\u{20}\u{5b}\u{5b}\u{22}\u{74}\u{68}\u{69}\u{73}\u{20}\u{69}\u{73}\u{20}\u{61}\u{20}\u{27}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{73}\u{65}\u{76}\u{65}\u{72}\u{61}\u{6c}\u{20}\u{27}\u{71}\u{75}\u{6f}\u{74}\u{65}\u{73}\u{27}\u{22}\u{5d}\u{5d}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{32}\u{20}\u{3d}\u{20}\u{22}\u{27}\u{71}\u{75}\u{6f}\u{74}\u{65}\u{73}\u{27}\u{22}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{66}\u{69}\u{6e}\u{64}\u{28}\u{61}\u{31}\u{2c}\u{20}\u{61}\u{32}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{33}\u{34}\u{29}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{27}\u{2b}\u{27}\u{29}\u{a}\u{a}\u{61}\u{31}\u{20}\u{3d}\u{20}\u{5b}\u{3d}\u{3d}\u{5b}\u{74}\u{65}\u{6d}\u{70}\u{20}\u{3d}\u{20}\u{5b}\u{5b}\u{61}\u{6e}\u{20}\u{61}\u{72}\u{62}\u{69}\u{74}\u{72}\u{61}\u{72}\u{79}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{5d}\u{5d}\u{3b}\u{20}\u{5d}\u{3d}\u{3d}\u{5d}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{6c}\u{6f}\u{61}\u{64}\u{28}\u{61}\u{31}\u{29}\u{29}\u{28}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{74}\u{65}\u{6d}\u{70}\u{20}\u{3d}\u{3d}\u{20}\u{27}\u{61}\u{6e}\u{20}\u{61}\u{72}\u{62}\u{69}\u{74}\u{72}\u{61}\u{72}\u{79}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{27}\u{29}\u{a}\u{5f}\u{47}\u{2e}\u{74}\u{65}\u{6d}\u{70}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{a}\u{2d}\u{2d}\u{20}\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}\u{20}\u{2d}\u{2d}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{22}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{22}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{6c}\u{65}\u{6e}\u{28}\u{62}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{39}\u{36}\u{30}\u{29}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{27}\u{2b}\u{27}\u{29}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{5b}\u{5b}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{30}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{a}\u{5d}\u{5d}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{6c}\u{65}\u{6e}\u{28}\u{61}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{31}\u{38}\u{36}\u{33}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{73}\u{75}\u{62}\u{28}\u{61}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{34}\u{30}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{73}\u{75}\u{62}\u{28}\u{62}\u{2c}\u{20}\u{31}\u{2c}\u{20}\u{34}\u{30}\u{29}\u{29}\u{a}\u{78}\u{20}\u{3d}\u{20}\u{31}\u{a}"
98print("\u{2b}")
98print("\u{2b}")
99_G.x=nil
99_G.x=nil
@@ -145,15 +145,15 @@ assert(a == "\u{5b}\u{3d}\u{3d}\u{3d}\u{5b}\u{5b}\u{3d}\u{5b}\u{5d}\u{5d}\u{3d}\
145a="\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}"
145a="\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}"
146assert(a == "\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}")
146assert(a == "\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}\u{5d}")
147local x = {"\u{3d}","\u{5b}","\u{5d}","\u{a}"}
147local x = {"\u{3d}","\u{5b}","\u{5d}","\u{a}"}
148−local len = 4
148+local len = 0x4
149local function gen
149local function gen
150(c,n)
150(c,n)
151−if n == 0 then
151+if n == 0x0 then
152coroutine.yield(c)
152coroutine.yield(c)
153else
153else
154for _,a in pairs(x)
154for _,a in pairs(x)
155do
155do
156−gen(c .. a,n - 1)
156+gen(c .. a,n - 0x1)
157end
157end
158end
158end
159end
159end
zod/luau/res/lua/cycled/locals.lua+224−224
@@ -7,14 +7,14 @@ x=nil
7;
7;
8return x
8return x
9end
9end
10−assert(f(10) == nil)
10+assert(f(0xa) == nil)
11local function f
11local function f
12()
12()
13local x
13local x
14;
14;
15return x
15return x
16end
16end
17−assert(f(10) == nil)
17+assert(f(0xa) == nil)
18local function f
18local function f
19(x)
19(x)
20x=nil
20x=nil
@@ -23,66 +23,66 @@ local y
23;
23;
24return x,y
24return x,y
25end
25end
26−assert(f(10) == nil and select(2,f(20)) == nil)
26+assert(f(0xa) == nil and select(0x2,f(0x14)) == nil)
27do
27do
28−local i = 10
28+local i = 0xa
29do
29do
30−local i = 100
30+local i = 0x64
31;
31;
32−assert(i == 100)
32+assert(i == 0x64)
33end
33end
34do
34do
35−local i = 1000
35+local i = 0x3e8
36;
36;
37−assert(i == 1000)
37+assert(i == 0x3e8)
38end
38end
39−assert(i == 10)
39+assert(i == 0xa)
40−if i ~= 10 then
40+if i ~= 0xa then
41−local i = 20
41+local i = 0x14
42else
42else
43−local i = 30
43+local i = 0x1e
44−assert(i == 30)
44+assert(i == 0x1e)
45end
45end
46end
46end
47f=nil
47f=nil
48local f
48local f
49−local x = 1
49+local x = 0x1
50a=nil
50a=nil
51load("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{7d}")()
51load("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{20}\u{3d}\u{20}\u{7b}\u{7d}")()
52assert(a == nil)
52assert(a == nil)
53function f(a)
53function f(a)
54local _1,_2,_3,_4,_5
54local _1,_2,_3,_4,_5
55local _6,_7,_8,_9,_10
55local _6,_7,_8,_9,_10
56−local x = 3
56+local x = 0x3
57local b = a
57local b = a
58local c,d = a,b
58local c,d = a,b
59if (d == b) then
59if (d == b) then
60local x = "\u{71}"
60local x = "\u{71}"
61x=b
61x=b
62−assert(x == 2)
62+assert(x == 0x2)
63else
63else
64assert(nil)
64assert(nil)
65end
65end
66−assert(x == 3)
66+assert(x == 0x3)
67−local f = 10
67+local f = 0xa
68end
68end
69−local b = 10
69+local b = 0xa
70local a
70local a
71;
71;
72repeat
72repeat
73local b
73local b
74;
74;
75−a,b=1,2
75+a,b=0x1,0x2
76;
76;
77−assert(a + 1 == b)
77+assert(a + 0x1 == b)
78;
78;
79−until a + b == 3
79+until a + b == 0x3
80−assert(x == 1)
80+assert(x == 0x1)
81−f(2)
81+f(0x2)
82assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
82assert(type(f) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
83local function getenv
83local function getenv
84(f)
84(f)
85−local a,b = debug.getupvalue(f,1)
85+local a,b = debug.getupvalue(f,0x1)
86assert(a == "\u{5f}\u{45}\u{4e}\u{56}")
86assert(a == "\u{5f}\u{45}\u{4e}\u{56}")
87return b
87return b
88end
88end
@@ -93,33 +93,33 @@ local f = load("\u{61}\u{20}\u{3d}\u{20}\u{33}",nil,nil,c)
93assert(getenv(f) == c)
93assert(getenv(f) == c)
94assert(c.a == nil)
94assert(c.a == nil)
95f()
95f()
96−assert(c.a == 3)
96+assert(c.a == 0x3)
97do
97do
98−local i = 2
98+local i = 0x2
99−local p = 4
99+local p = 0x4
100repeat
100repeat
101−for j = - 3, 3
101+for j = - 0x3, 0x3
102do
102do
103assert(load(string.format("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{20}\u{3d}\u{3d}\u{32}\u{5e}\u{25}\u{73}\u{29}",j,p - j,i),""))()
103assert(load(string.format("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2b}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{20}\u{3d}\u{3d}\u{32}\u{5e}\u{25}\u{73}\u{29}",j,p - j,i),""))()
104assert(load(string.format("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{3d}\u{3d}\u{2d}\u{32}\u{5e}\u{25}\u{73}\u{29}",- j,p - j,i),""))()
104assert(load(string.format("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{3d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{3d}\u{61}\u{2d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{3d}\u{3d}\u{2d}\u{32}\u{5e}\u{25}\u{73}\u{29}",- j,p - j,i),""))()
105assert(load(string.format("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{2c}\u{62}\u{3d}\u{30}\u{2c}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{3d}\u{62}\u{2d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{3d}\u{3d}\u{2d}\u{32}\u{5e}\u{25}\u{73}\u{29}",- j,p - j,i),""))()
105assert(load(string.format("\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{2c}\u{62}\u{3d}\u{30}\u{2c}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{3d}\u{62}\u{2d}\u{25}\u{73}\u{3b}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{3d}\u{3d}\u{2d}\u{32}\u{5e}\u{25}\u{73}\u{29}",- j,p - j,i),""))()
106end
106end
107−p=2 * p
107+p=0x2 * p
108;
108;
109−i=i + 1
109+i=i + 0x1
110−until p <= 0
110+until p <= 0x0
111end
111end
112print("\u{2b}")
112print("\u{2b}")
113if rawget(_G,"\u{54}") then
113if rawget(_G,"\u{54}") then
114collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
114collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
115−local a = {[{}] = 4,[3] = 0,["\u{61}\u{6c}\u{6f}"] = 1,["\u{61}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}"] = 10}
115+local a = {[{}] = 0x4,[0x3] = 0x0,["\u{61}\u{6c}\u{6f}"] = 0x1,["\u{61}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}"] = 0xa}
116local t = T.querytab(a)
116local t = T.querytab(a)
117for k,_ in pairs(a)
117for k,_ in pairs(a)
118do
118do
119a[k]=undef
119a[k]=undef
120end
120end
121collectgarbage()
121collectgarbage()
122−for i = 0, t - 1
122+for i = 0x0, t - 0x1
123do
123do
124local k = querytab(a,i)
124local k = querytab(a,i)
125assert(k == nil or type(k) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" or k == "\u{61}\u{6c}\u{6f}")
125assert(k == nil or type(k) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}" or k == "\u{61}\u{6c}\u{6f}")
@@ -132,22 +132,22 @@ a.x=true
132a.y=true
132a.y=true
133;
133;
134a.z=true
134a.z=true
135−a[1]=true
135+a[0x1]=true
136−a[2]=true
136+a[0x2]=true
137end
137end
138−for i = 1, math.huge
138+for i = 0x1, math.huge
139do
139do
140T.alloccount(i)
140T.alloccount(i)
141local st,msg = pcall(additems)
141local st,msg = pcall(additems)
142T.alloccount()
142T.alloccount()
143−local count = 0
143+local count = 0x0
144for k,v in pairs(a)
144for k,v in pairs(a)
145do
145do
146assert(a[k] == v)
146assert(a[k] == v)
147−count=count + 1
147+count=count + 0x1
148end
148end
149if st then
149if st then
150−assert(count == 5)
150+assert(count == 0x5)
151;
151;
152break
152break
153end
153end
@@ -174,7 +174,7 @@ A=x
174do
174do
175local _ENV = _G
175local _ENV = _G
176;
176;
177−A=1000
177+A=0x3e8
178end
178end
179return function (x)
179return function (x)
180return A .. x
180return A .. x
@@ -184,26 +184,26 @@ end
184assert(getenv(foo) == mt)
184assert(getenv(foo) == mt)
185x=foo("\u{68}\u{69}")
185x=foo("\u{68}\u{69}")
186;
186;
187−assert(mt.A == "\u{68}\u{69}" and A == 1000)
187+assert(mt.A == "\u{68}\u{69}" and A == 0x3e8)
188assert(x("\u{2a}") == mt.A .. "\u{2a}")
188assert(x("\u{2a}") == mt.A .. "\u{2a}")
189do
189do
190−local _ENV = {["\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}"] = assert,["\u{41}"] = 10}
190+local _ENV = {["\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}"] = assert,["\u{41}"] = 0xa}
191;
191;
192do
192do
193−local _ENV = {["\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}"] = assert,["\u{41}"] = 20}
193+local _ENV = {["\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}"] = assert,["\u{41}"] = 0x14}
194;
194;
195−assert(A == 20)
195+assert(A == 0x14)
196;
196;
197x=A
197x=A
198end
198end
199−assert(A == 10 and x == 20)
199+assert(A == 0xa and x == 0x14)
200end
200end
201−assert(x == 20)
201+assert(x == 0x14)
202A=nil
202A=nil
203do
203do
204−local a <const>,b,c <const> = 10,20,30
204+local a <const>,b,c <const> = 0xa,0x14,0x1e
205b=a + c + b
205b=a + c + b
206−assert(a == 10 and b == 60 and c == 30)
206+assert(a == 0xa and b == 0x3c and c == 0x1e)
207local function checkro
207local function checkro
208(name,code)
208(name,code)
209local st,msg = load(code)
209local st,msg = load(code)
@@ -221,7 +221,7 @@ end
221print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}")
221print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}")
222local function stack
222local function stack
223(n)
223(n)
224−n=((n == 0) or stack(n - 1))
224+n=((n == 0x0) or stack(n - 0x1))
225end
225end
226local function func2close
226local function func2close
227(f,x,y)
227(f,x,y)
@@ -237,50 +237,50 @@ local a = {}
237do
237do
238local b <close> = false
238local b <close> = false
239local x <close> = setmetatable({"\u{78}"},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function (self)
239local x <close> = setmetatable({"\u{78}"},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function (self)
240−a[# a + 1]=self[1]
240+a[# a + 0x1]=self[0x1]
241end})
241end})
242local w,y <close>,z = func2close(function (self,err)
242local w,y <close>,z = func2close(function (self,err)
243assert(err == nil)
243assert(err == nil)
244;
244;
245−a[# a + 1]="\u{79}"
245+a[# a + 0x1]="\u{79}"
246−end,10,20)
246+end,0xa,0x14)
247local c <close> = nil
247local c <close> = nil
248−a[# a + 1]="\u{69}\u{6e}"
248+a[# a + 0x1]="\u{69}\u{6e}"
249−assert(w == 10 and z == 20)
249+assert(w == 0xa and z == 0x14)
250end
250end
251−a[# a + 1]="\u{6f}\u{75}\u{74}"
251+a[# a + 0x1]="\u{6f}\u{75}\u{74}"
252−assert(a[1] == "\u{69}\u{6e}" and a[2] == "\u{79}" and a[3] == "\u{78}" and a[4] == "\u{6f}\u{75}\u{74}")
252+assert(a[0x1] == "\u{69}\u{6e}" and a[0x2] == "\u{79}" and a[0x3] == "\u{78}" and a[0x4] == "\u{6f}\u{75}\u{74}")
253end
253end
254do
254do
255local X = false
255local X = false
256local x,closescope = func2close(function (_,msg)
256local x,closescope = func2close(function (_,msg)
257−stack(10)
257+stack(0xa)
258;
258;
259assert(msg == nil)
259assert(msg == nil)
260X=true
260X=true
261−end,100)
261+end,0x64)
262−assert(x == 100)
262+assert(x == 0x64)
263;
263;
264−x=101
264+x=0x65
265;
265;
266local function foo
266local function foo
267(x)
267(x)
268local _ <close> = closescope
268local _ <close> = closescope
269−return x,X,23
269+return x,X,0x17
270end
270end
271local a,b,c = foo(1.5)
271local a,b,c = foo(1.5)
272−assert(a == 1.5 and b == false and c == 23 and X == true)
272+assert(a == 1.5 and b == false and c == 0x17 and X == true)
273X=false
273X=false
274foo=function (x)
274foo=function (x)
275local _ <close> = func2close(function (_,msg)
275local _ <close> = func2close(function (_,msg)
276−assert(debug.getinfo(2).name == "\u{66}\u{6f}\u{6f}")
276+assert(debug.getinfo(0x2).name == "\u{66}\u{6f}\u{6f}")
277assert(msg == nil)
277assert(msg == nil)
278end)
278end)
279local _ <close> = closescope
279local _ <close> = closescope
280−local y = 15
280+local y = 0xf
281return y
281return y
282end
282end
283−assert(foo() == 15 and X == true)
283+assert(foo() == 0xf and X == true)
284X=false
284X=false
285foo=function ()
285foo=function ()
286local x <close> = closescope
286local x <close> = closescope
@@ -315,11 +315,11 @@ return (function ()
315return nil
315return nil
316end),nil,nil,x
316end),nil,nil,x
317end
317end
318−local v <const> = 1
318+local v <const> = 0x1
319−local w <const> = 1
319+local w <const> = 0x1
320−local x <const> = 1
320+local x <const> = 0x1
321−local y <const> = 1
321+local y <const> = 0x1
322−local z <const> = 1
322+local z <const> = 0x1
323for k in a()
323for k in a()
324do
324do
325a=k
325a=k
@@ -331,10 +331,10 @@ local X,Y
331local function foo
331local function foo
332()
332()
333local _ <close> = func2close(function ()
333local _ <close> = func2close(function ()
334−Y=10
334+Y=0xa
335end)
335end)
336assert(X == true and Y == nil)
336assert(X == true and Y == nil)
337−return 1,2,3
337+return 0x1,0x2,0x3
338end
338end
339local function bar
339local function bar
340()
340()
@@ -347,7 +347,7 @@ return foo()
347end
347end
348end
348end
349local a,b,c,d = bar()
349local a,b,c,d = bar()
350−assert(a == 1 and b == 2 and c == 3 and X == false and Y == 10 and d == nil)
350+assert(a == 0x1 and b == 0x2 and c == 0x3 and X == false and Y == 0xa and d == nil)
351end
351end
352do
352do
353local closed = false
353local closed = false
@@ -355,7 +355,7 @@ local function foo
355()
355()
356return function ()
356return function ()
357return true
357return true
358−end,0,0,func2close(function ()
358+end,0x0,0x0,func2close(function ()
359closed=true
359closed=true
360end)
360end)
361end
361end
@@ -414,18 +414,18 @@ local z <close> = func2close(function (self,msg)
414assert(msg == nil)
414assert(msg == nil)
415error("\u{40}\u{7a}")
415error("\u{40}\u{7a}")
416end)
416end)
417−return 200
417+return 0xc8
418end
418end
419local stat,msg = pcall(foo,false)
419local stat,msg = pcall(foo,false)
420assert(string.find(msg,"\u{40}\u{78}"))
420assert(string.find(msg,"\u{40}\u{78}"))
421local function foo
421local function foo
422()
422()
423local x <close> = func2close(function (self,msg)
423local x <close> = func2close(function (self,msg)
424−assert(debug.getinfo(2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
424+assert(debug.getinfo(0x2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
425assert(string.find(msg,"\u{40}\u{78}\u{31}"))
425assert(string.find(msg,"\u{40}\u{78}\u{31}"))
426end)
426end)
427local x1 <close> = func2close(function (self,msg)
427local x1 <close> = func2close(function (self,msg)
428−assert(debug.getinfo(2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
428+assert(debug.getinfo(0x2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
429assert(string.find(msg,"\u{40}\u{79}"))
429assert(string.find(msg,"\u{40}\u{79}"))
430error("\u{40}\u{78}\u{31}")
430error("\u{40}\u{78}\u{31}")
431end)
431end)
@@ -433,18 +433,18 @@ local gc <close> = func2close(function ()
433collectgarbage()
433collectgarbage()
434end)
434end)
435local y <close> = func2close(function (self,msg)
435local y <close> = func2close(function (self,msg)
436−assert(debug.getinfo(2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
436+assert(debug.getinfo(0x2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
437assert(string.find(msg,"\u{40}\u{7a}"))
437assert(string.find(msg,"\u{40}\u{7a}"))
438error("\u{40}\u{79}")
438error("\u{40}\u{79}")
439end)
439end)
440local first = true
440local first = true
441local z <close> = func2close(function (self,msg)
441local z <close> = func2close(function (self,msg)
442−assert(debug.getinfo(2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
442+assert(debug.getinfo(0x2).name == "\u{70}\u{63}\u{61}\u{6c}\u{6c}")
443−assert(first and msg == 4)
443+assert(first and msg == 0x4)
444first=false
444first=false
445error("\u{40}\u{7a}")
445error("\u{40}\u{7a}")
446end)
446end)
447−error(4)
447+error(0x4)
448end
448end
449local stat,msg = pcall(foo,true)
449local stat,msg = pcall(foo,true)
450assert(string.find(msg,"\u{40}\u{78}\u{31}"))
450assert(string.find(msg,"\u{40}\u{78}\u{31}"))
@@ -493,17 +493,17 @@ local function foo
493()
493()
494local a1 <close> = func2close(function (_,msg)
494local a1 <close> = func2close(function (_,msg)
495assert(string.find(msg,"\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}"))
495assert(string.find(msg,"\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}"))
496−error(12)
496+error(0xc)
497end)
497end)
498local a2 <close> = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = print})
498local a2 <close> = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = print})
499local a3 <close> = func2close(function (_,msg)
499local a3 <close> = func2close(function (_,msg)
500assert(msg == nil)
500assert(msg == nil)
501−error(123)
501+error(0x7b)
502end)
502end)
503−getmetatable(a2).__close=4
503+getmetatable(a2).__close=0x4
504end
504end
505local stat,msg = pcall(foo)
505local stat,msg = pcall(foo)
506−assert(not stat and msg == 12)
506+assert(not stat and msg == 0xc)
507end
507end
508do
508do
509local track = {}
509local track = {}
@@ -512,43 +512,43 @@ local function foo
512local x <close> = func2close(function ()
512local x <close> = func2close(function ()
513local xx <close> = func2close(function (_,msg)
513local xx <close> = func2close(function (_,msg)
514assert(msg == nil)
514assert(msg == nil)
515−track[# track + 1]="\u{78}\u{78}"
515+track[# track + 0x1]="\u{78}\u{78}"
516end)
516end)
517−track[# track + 1]="\u{78}"
517+track[# track + 0x1]="\u{78}"
518end)
518end)
519−track[# track + 1]="\u{66}\u{6f}\u{6f}"
519+track[# track + 0x1]="\u{66}\u{6f}\u{6f}"
520−return 20,30,40
520+return 0x14,0x1e,0x28
521end
521end
522local a,b,c,d = foo()
522local a,b,c,d = foo()
523−assert(a == 20 and b == 30 and c == 40 and d == nil)
523+assert(a == 0x14 and b == 0x1e and c == 0x28 and d == nil)
524−assert(track[1] == "\u{66}\u{6f}\u{6f}" and track[2] == "\u{78}" and track[3] == "\u{78}\u{78}")
524+assert(track[0x1] == "\u{66}\u{6f}\u{6f}" and track[0x2] == "\u{78}" and track[0x3] == "\u{78}\u{78}")
525local track = {}
525local track = {}
526local function foo
526local function foo
527()
527()
528local x0 <close> = func2close(function (_,msg)
528local x0 <close> = func2close(function (_,msg)
529−assert(msg == 202)
529+assert(msg == 0xca)
530−track[# track + 1]="\u{78}\u{30}"
530+track[# track + 0x1]="\u{78}\u{30}"
531end)
531end)
532local x <close> = func2close(function ()
532local x <close> = func2close(function ()
533local xx <close> = func2close(function (_,msg)
533local xx <close> = func2close(function (_,msg)
534−assert(msg == 101)
534+assert(msg == 0x65)
535−track[# track + 1]="\u{78}\u{78}"
535+track[# track + 0x1]="\u{78}\u{78}"
536−error(202)
536+error(0xca)
537end)
537end)
538−track[# track + 1]="\u{78}"
538+track[# track + 0x1]="\u{78}"
539−error(101)
539+error(0x65)
540end)
540end)
541−track[# track + 1]="\u{66}\u{6f}\u{6f}"
541+track[# track + 0x1]="\u{66}\u{6f}\u{6f}"
542−return 20,30,40
542+return 0x14,0x1e,0x28
543end
543end
544local st,msg = pcall(foo)
544local st,msg = pcall(foo)
545−assert(not st and msg == 202)
545+assert(not st and msg == 0xca)
546−assert(track[1] == "\u{66}\u{6f}\u{6f}" and track[2] == "\u{78}" and track[3] == "\u{78}\u{78}" and track[4] == "\u{78}\u{30}")
546+assert(track[0x1] == "\u{66}\u{6f}\u{6f}" and track[0x2] == "\u{78}" and track[0x3] == "\u{78}\u{78}" and track[0x4] == "\u{78}\u{30}")
547end
547end
548local function checktable
548local function checktable
549(t1,t2)
549(t1,t2)
550assert(# t1 == # t2)
550assert(# t1 == # t2)
551−for i = 1, # t1
551+for i = 0x1, # t1
552do
552do
553assert(t1[i] == t2[i])
553assert(t1[i] == t2[i])
554end
554end
@@ -556,13 +556,13 @@ end
556do
556do
557local function overflow
557local function overflow
558(n)
558(n)
559−overflow(n + 1)
559+overflow(n + 0x1)
560end
560end
561local function errorh
561local function errorh
562(m)
562(m)
563assert(string.find(m,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
563assert(string.find(m,"\u{73}\u{74}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}"))
564local x <close> = func2close(function (o)
564local x <close> = func2close(function (o)
565−o[1]=10
565+o[0x1]=0xa
566end)
566end)
567return x
567return x
568end
568end
@@ -571,15 +571,15 @@ local st,obj
571local co = coroutine.wrap(function ()
571local co = coroutine.wrap(function ()
572local y <close> = func2close(function (obj,msg)
572local y <close> = func2close(function (obj,msg)
573assert(msg == nil)
573assert(msg == nil)
574−obj[1]=100
574+obj[0x1]=0x64
575flag=obj
575flag=obj
576end)
576end)
577tracegc.stop()
577tracegc.stop()
578−st,obj=xpcall(overflow,errorh,0)
578+st,obj=xpcall(overflow,errorh,0x0)
579tracegc.start()
579tracegc.start()
580end)
580end)
581co()
581co()
582−assert(not st and obj[1] == 10 and flag[1] == 100)
582+assert(not st and obj[0x1] == 0xa and flag[0x1] == 0x64)
583end
583end
584if rawget(_G,"\u{54}") then
584if rawget(_G,"\u{54}") then
585do
585do
@@ -590,12 +590,12 @@ collectgarbage()
590collectgarbage()
590collectgarbage()
591local function loop
591local function loop
592(n)
592(n)
593−if n < 400 then
593+if n < 0x190 then
594−loop(n + 1)
594+loop(n + 0x1)
595end
595end
596end
596end
597local o = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function ()
597local o = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function ()
598−loop(0)
598+loop(0x0)
599end})
599end})
600local script = "\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"
600local script = "\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{3b}\u{20}\u{73}\u{65}\u{74}\u{74}\u{6f}\u{70}\u{20}\u{31}\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}"
601assert(T.testC(script,o) == script)
601assert(T.testC(script,o) == script)
@@ -606,13 +606,13 @@ local y <close> = func2close(function ()
606T.alloccount()
606T.alloccount()
607end)
607end)
608local x <close> = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function ()
608local x <close> = setmetatable({},{["\u{5f}\u{5f}\u{63}\u{6c}\u{6f}\u{73}\u{65}"] = function ()
609−T.alloccount(0)
609+T.alloccount(0x0)
610;
610;
611local x = {}
611local x = {}
612end})
612end})
613−error(1000)
613+error(0x3e8)
614end
614end
615−stack(5)
615+stack(0x5)
616local _,msg = pcall(foo)
616local _,msg = pcall(foo)
617assert(msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
617assert(msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
618local closemsg
618local closemsg
@@ -622,14 +622,14 @@ closemsg=msg
622end)
622end)
623local function enter
623local function enter
624(count)
624(count)
625−stack(10)
625+stack(0xa)
626T.alloccount(count)
626T.alloccount(count)
627closemsg=nil
627closemsg=nil
628return close
628return close
629end
629end
630local function test
630local function test
631()
631()
632−local x <close> = enter(0)
632+local x <close> = enter(0x0)
633local y = {}
633local y = {}
634end
634end
635local _,msg = pcall(test)
635local _,msg = pcall(test)
@@ -639,29 +639,29 @@ local function test
639local xxx <close> = func2close(function (self,msg)
639local xxx <close> = func2close(function (self,msg)
640assert(msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
640assert(msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
641;
641;
642−error(1000)
642+error(0x3e8)
643end)
643end)
644local xx <close> = func2close(function (self,msg)
644local xx <close> = func2close(function (self,msg)
645assert(msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
645assert(msg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
646;
646;
647end)
647end)
648−local x <close> = enter(0)
648+local x <close> = enter(0x0)
649local y = {}
649local y = {}
650end
650end
651local _,msg = pcall(test)
651local _,msg = pcall(test)
652−assert(msg == 1000 and closemsg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
652+assert(msg == 0x3e8 and closemsg == "\u{6e}\u{6f}\u{74}\u{20}\u{65}\u{6e}\u{6f}\u{75}\u{67}\u{68}\u{20}\u{6d}\u{65}\u{6d}\u{6f}\u{72}\u{79}")
653do
653do
654collectgarbage()
654collectgarbage()
655−local s = string.rep("\u{61}",10000)
655+local s = string.rep("\u{61}",0x2710)
656local m = T.totalmem()
656local m = T.totalmem()
657collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
657collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
658s=string.upper(s)
658s=string.upper(s)
659−assert(T.totalmem() - m <= 11000)
659+assert(T.totalmem() - m <= 0x2af8)
660collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
660collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
661end
661end
662do
662do
663−local lim = 10000
663+local lim = 0x2710
664−local extra = 2000
664+local extra = 0x7d0
665local s = string.rep("\u{61}",lim)
665local s = string.rep("\u{61}",lim)
666local a = {s,s}
666local a = {s,s}
667collectgarbage()
667collectgarbage()
@@ -675,12 +675,12 @@ assert(T.totalmem() - m <= extra)
675T.totalmem(m + lim + extra)
675T.totalmem(m + lim + extra)
676assert(not pcall(table.concat,a))
676assert(not pcall(table.concat,a))
677assert(T.totalmem() - m <= extra)
677assert(T.totalmem() - m <= extra)
678−T.totalmem(m + 2 * lim + extra)
678+T.totalmem(m + 0x2 * lim + extra)
679assert(not pcall(table.concat,a))
679assert(not pcall(table.concat,a))
680assert(T.totalmem() - m <= extra)
680assert(T.totalmem() - m <= extra)
681−T.totalmem(m + 4 * lim + extra)
681+T.totalmem(m + 0x4 * lim + extra)
682−assert(# table.concat(a) == 2 * lim)
682+assert(# table.concat(a) == 0x2 * lim)
683−T.totalmem(0)
683+T.totalmem(0x0)
684collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
684collectgarbage("\u{72}\u{65}\u{73}\u{74}\u{61}\u{72}\u{74}")
685print("\u{2b}")
685print("\u{2b}")
686end
686end
@@ -688,76 +688,76 @@ do
688local trace = {}
688local trace = {}
689local function hook
689local function hook
690(event)
690(event)
691−trace[# trace + 1]=event .. "\u{20}" .. (debug.getinfo(2).name or "\u{3f}")
691+trace[# trace + 0x1]=event .. "\u{20}" .. (debug.getinfo(0x2).name or "\u{3f}")
692end
692end
693local x = func2close(function (_,msg)
693local x = func2close(function (_,msg)
694−trace[# trace + 1]="\u{78}"
694+trace[# trace + 0x1]="\u{78}"
695end)
695end)
696local y = func2close(function (_,msg)
696local y = func2close(function (_,msg)
697−trace[# trace + 1]="\u{79}"
697+trace[# trace + 0x1]="\u{79}"
698end)
698end)
699debug.sethook(hook,"\u{72}")
699debug.sethook(hook,"\u{72}")
700local t = {T.testC("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{78}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{32}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{33}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}",x,y)}
700local t = {T.testC("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{78}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{6e}\u{75}\u{6d}\u{20}\u{31}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{70}\u{75}\u{73}\u{68}\u{69}\u{6e}\u{74}\u{20}\u{32}\u{30}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{33}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{23}\u{20}\u{79}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}",x,y)}
701debug.sethook()
701debug.sethook()
702checktable(trace,{"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{65}\u{74}\u{68}\u{6f}\u{6f}\u{6b}","\u{79}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{3f}","\u{78}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{3f}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}"})
702checktable(trace,{"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{65}\u{74}\u{68}\u{6f}\u{6f}\u{6b}","\u{79}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{3f}","\u{78}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{3f}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}"})
703−checktable(t,{10,20})
703+checktable(t,{0xa,0x14})
704end
704end
705end
705end
706do
706do
707local trace = {}
707local trace = {}
708local function hook
708local function hook
709(event)
709(event)
710−trace[# trace + 1]=event .. "\u{20}" .. debug.getinfo(2).name
710+trace[# trace + 0x1]=event .. "\u{20}" .. debug.getinfo(0x2).name
711end
711end
712local function foo
712local function foo
713(...)
713(...)
714local x <close> = func2close(function (_,msg)
714local x <close> = func2close(function (_,msg)
715−trace[# trace + 1]="\u{78}"
715+trace[# trace + 0x1]="\u{78}"
716end)
716end)
717local y <close> = func2close(function (_,msg)
717local y <close> = func2close(function (_,msg)
718debug.sethook(hook,"\u{72}")
718debug.sethook(hook,"\u{72}")
719end)
719end)
720return ...
720return ...
721end
721end
722−local t = {foo(10,20,30)}
722+local t = {foo(0xa,0x14,0x1e)}
723debug.sethook()
723debug.sethook()
724−checktable(t,{10,20,30})
724+checktable(t,{0xa,0x14,0x1e})
725checktable(trace,{"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{65}\u{74}\u{68}\u{6f}\u{6f}\u{6b}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}","\u{78}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{6f}\u{6f}"})
725checktable(trace,{"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{73}\u{65}\u{74}\u{68}\u{6f}\u{6f}\u{6b}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}","\u{78}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{66}\u{6f}\u{6f}"})
726end
726end
727print("\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}")
727print("\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}")
728do
728do
729local trace = {}
729local trace = {}
730local co = coroutine.wrap(function ()
730local co = coroutine.wrap(function ()
731−trace[# trace + 1]="\u{6e}\u{6f}\u{77}\u{58}"
731+trace[# trace + 0x1]="\u{6e}\u{6f}\u{77}\u{58}"
732local x <close> = func2close(function (_,msg)
732local x <close> = func2close(function (_,msg)
733assert(msg == nil)
733assert(msg == nil)
734−trace[# trace + 1]="\u{78}\u{31}"
734+trace[# trace + 0x1]="\u{78}\u{31}"
735coroutine.yield("\u{78}")
735coroutine.yield("\u{78}")
736−trace[# trace + 1]="\u{78}\u{32}"
736+trace[# trace + 0x1]="\u{78}\u{32}"
737end)
737end)
738return pcall(function ()
738return pcall(function ()
739do
739do
740local z <close> = func2close(function (_,msg)
740local z <close> = func2close(function (_,msg)
741assert(msg == nil)
741assert(msg == nil)
742−trace[# trace + 1]="\u{7a}\u{31}"
742+trace[# trace + 0x1]="\u{7a}\u{31}"
743coroutine.yield("\u{7a}")
743coroutine.yield("\u{7a}")
744−trace[# trace + 1]="\u{7a}\u{32}"
744+trace[# trace + 0x1]="\u{7a}\u{32}"
745end)
745end)
746end
746end
747−trace[# trace + 1]="\u{6e}\u{6f}\u{77}\u{59}"
747+trace[# trace + 0x1]="\u{6e}\u{6f}\u{77}\u{59}"
748local y <close> = func2close(function (_,msg)
748local y <close> = func2close(function (_,msg)
749assert(msg == nil)
749assert(msg == nil)
750−trace[# trace + 1]="\u{79}\u{31}"
750+trace[# trace + 0x1]="\u{79}\u{31}"
751coroutine.yield("\u{79}")
751coroutine.yield("\u{79}")
752−trace[# trace + 1]="\u{79}\u{32}"
752+trace[# trace + 0x1]="\u{79}\u{32}"
753end)
753end)
754−return 10,20,30
754+return 0xa,0x14,0x1e
755end)
755end)
756end)
756end)
757assert(co() == "\u{7a}")
757assert(co() == "\u{7a}")
758assert(co() == "\u{79}")
758assert(co() == "\u{79}")
759assert(co() == "\u{78}")
759assert(co() == "\u{78}")
760−checktable({co()},{true,10,20,30})
760+checktable({co()},{true,0xa,0x14,0x1e})
761checktable(trace,{"\u{6e}\u{6f}\u{77}\u{58}","\u{7a}\u{31}","\u{7a}\u{32}","\u{6e}\u{6f}\u{77}\u{59}","\u{79}\u{31}","\u{79}\u{32}","\u{78}\u{31}","\u{78}\u{32}"})
761checktable(trace,{"\u{6e}\u{6f}\u{77}\u{58}","\u{7a}\u{31}","\u{7a}\u{32}","\u{6e}\u{6f}\u{77}\u{59}","\u{79}\u{31}","\u{79}\u{32}","\u{78}\u{31}","\u{78}\u{32}"})
762end
762end
763do
763do
@@ -770,13 +770,13 @@ if extra then
770extrares=co()
770extrares=co()
771end
771end
772local res = table.pack(co())
772local res = table.pack(co())
773−assert(res.n == 2 and res[2] == nil)
773+assert(res.n == 0x2 and res[0x2] == nil)
774local res2 = table.pack(co())
774local res2 = table.pack(co())
775assert(res2.n == t.n)
775assert(res2.n == t.n)
776−for i = 1, # t
776+for i = 0x1, # t
777do
777do
778if t[i] == "\u{78}" then
778if t[i] == "\u{78}" then
779−assert(res2[i] == res[1])
779+assert(res2[i] == res[0x1])
780else
780else
781assert(res2[i] == t[i])
781assert(res2[i] == t[i])
782end
782end
@@ -787,13 +787,13 @@ local function foo
787local x <close> = func2close(coroutine.yield)
787local x <close> = func2close(coroutine.yield)
788local extra <close> = func2close(function (self)
788local extra <close> = func2close(function (self)
789assert(self == extrares)
789assert(self == extrares)
790−coroutine.yield(100)
790+coroutine.yield(0x64)
791end)
791end)
792extrares=extra
792extrares=extra
793−return table.unpack({10,x,30})
793+return table.unpack({0xa,x,0x1e})
794end
794end
795−check(foo,true,10,"\u{78}",30)
795+check(foo,true,0xa,"\u{78}",0x1e)
796−assert(extrares == 100)
796+assert(extrares == 0x64)
797local function foo
797local function foo
798()
798()
799local x <close> = func2close(coroutine.yield)
799local x <close> = func2close(coroutine.yield)
@@ -803,7 +803,7 @@ check(foo,false)
803local function foo
803local function foo
804()
804()
805local x <close> = func2close(coroutine.yield)
805local x <close> = func2close(coroutine.yield)
806−local y,z = 20,30
806+local y,z = 0x14,0x1e
807return x
807return x
808end
808end
809check(foo,false,"\u{78}")
809check(foo,false,"\u{78}")
@@ -811,40 +811,40 @@ local function foo
811()
811()
812local x <close> = func2close(coroutine.yield)
812local x <close> = func2close(coroutine.yield)
813local extra <close> = func2close(coroutine.yield)
813local extra <close> = func2close(coroutine.yield)
814−return table.unpack({},1,100)
814+return table.unpack({},0x1,0x64)
815end
815end
816−check(foo,true,table.unpack({},1,100))
816+check(foo,true,table.unpack({},0x1,0x64))
817end
817end
818do
818do
819local co = coroutine.wrap(function ()
819local co = coroutine.wrap(function ()
820local function foo
820local function foo
821(err)
821(err)
822local z <close> = func2close(function (_,msg)
822local z <close> = func2close(function (_,msg)
823−assert(msg == nil or msg == err + 20)
823+assert(msg == nil or msg == err + 0x14)
824coroutine.yield("\u{7a}")
824coroutine.yield("\u{7a}")
825−return 100,200
825+return 0x64,0xc8
826end)
826end)
827local y <close> = func2close(function (_,msg)
827local y <close> = func2close(function (_,msg)
828−assert(msg == err or (msg == nil and err == 1))
828+assert(msg == err or (msg == nil and err == 0x1))
829coroutine.yield("\u{79}")
829coroutine.yield("\u{79}")
830if err then
830if err then
831−error(err + 20)
831+error(err + 0x14)
832end
832end
833end)
833end)
834local x <close> = func2close(function (_,msg)
834local x <close> = func2close(function (_,msg)
835−assert(msg == err or (msg == nil and err == 1))
835+assert(msg == err or (msg == nil and err == 0x1))
836coroutine.yield("\u{78}")
836coroutine.yield("\u{78}")
837−return 100,200
837+return 0x64,0xc8
838end)
838end)
839−if err == 10 then
839+if err == 0xa then
840error(err)
840error(err)
841else
841else
842−return 10,20
842+return 0xa,0x14
843end
843end
844end
844end
845coroutine.yield(pcall(foo,nil))
845coroutine.yield(pcall(foo,nil))
846−coroutine.yield(pcall(foo,1))
846+coroutine.yield(pcall(foo,0x1))
847−return pcall(foo,10)
847+return pcall(foo,0xa)
848end)
848end)
849local a,b = co()
849local a,b = co()
850assert(a == "\u{78}" and b == nil)
850assert(a == "\u{78}" and b == nil)
@@ -853,7 +853,7 @@ assert(a == "\u{79}" and b == nil)
853a,b=co()
853a,b=co()
854assert(a == "\u{7a}" and b == nil)
854assert(a == "\u{7a}" and b == nil)
855local a,b,c = co()
855local a,b,c = co()
856−assert(a and b == 10 and c == 20)
856+assert(a and b == 0xa and c == 0x14)
857local a,b = co()
857local a,b = co()
858assert(a == "\u{78}" and b == nil)
858assert(a == "\u{78}" and b == nil)
859a,b=co()
859a,b=co()
@@ -861,7 +861,7 @@ assert(a == "\u{79}" and b == nil)
861a,b=co()
861a,b=co()
862assert(a == "\u{7a}" and b == nil)
862assert(a == "\u{7a}" and b == nil)
863local st,msg = co()
863local st,msg = co()
864−assert(not st and msg == 21)
864+assert(not st and msg == 0x15)
865local a,b = co()
865local a,b = co()
866assert(a == "\u{78}" and b == nil)
866assert(a == "\u{78}" and b == nil)
867a,b=co()
867a,b=co()
@@ -869,7 +869,7 @@ assert(a == "\u{79}" and b == nil)
869a,b=co()
869a,b=co()
870assert(a == "\u{7a}" and b == nil)
870assert(a == "\u{7a}" and b == nil)
871local st,msg = co()
871local st,msg = co()
872−assert(not st and msg == 10 + 20)
872+assert(not st and msg == 0xa + 0x14)
873end
873end
874do
874do
875local x = false
875local x = false
@@ -882,64 +882,64 @@ do
882local yv <close> = func2close(function ()
882local yv <close> = func2close(function ()
883y=true
883y=true
884end)
884end)
885−coroutine.yield(100)
885+coroutine.yield(0x64)
886end
886end
887−coroutine.yield(200)
887+coroutine.yield(0xc8)
888−error(23)
888+error(0x17)
889end)
889end)
890local b = co()
890local b = co()
891−assert(b == 100 and not x and not y)
891+assert(b == 0x64 and not x and not y)
892b=co()
892b=co()
893−assert(b == 200 and not x and y)
893+assert(b == 0xc8 and not x and y)
894local a,b = pcall(co)
894local a,b = pcall(co)
895−assert(not a and b == 23 and x and y)
895+assert(not a and b == 0x17 and x and y)
896end
896end
897do
897do
898−local x = 0
898+local x = 0x0
899local co = coroutine.wrap(function ()
899local co = coroutine.wrap(function ()
900local xx <close> = func2close(function (_,msg)
900local xx <close> = func2close(function (_,msg)
901−x=x + 1
901+x=x + 0x1
902;
902;
903assert(string.find(msg,"\u{40}\u{58}\u{58}\u{58}"))
903assert(string.find(msg,"\u{40}\u{58}\u{58}\u{58}"))
904error("\u{40}\u{59}\u{59}\u{59}")
904error("\u{40}\u{59}\u{59}\u{59}")
905end)
905end)
906local xv <close> = func2close(function ()
906local xv <close> = func2close(function ()
907−x=x + 1
907+x=x + 0x1
908;
908;
909error("\u{40}\u{58}\u{58}\u{58}")
909error("\u{40}\u{58}\u{58}\u{58}")
910end)
910end)
911−coroutine.yield(100)
911+coroutine.yield(0x64)
912−error(200)
912+error(0xc8)
913end)
913end)
914−assert(co() == 100)
914+assert(co() == 0x64)
915;
915;
916−assert(x == 0)
916+assert(x == 0x0)
917local st,msg = pcall(co)
917local st,msg = pcall(co)
918;
918;
919−assert(x == 2)
919+assert(x == 0x2)
920assert(not st and string.find(msg,"\u{40}\u{59}\u{59}\u{59}"))
920assert(not st and string.find(msg,"\u{40}\u{59}\u{59}\u{59}"))
921−local x = 0
921+local x = 0x0
922−local y = 0
922+local y = 0x0
923co=coroutine.wrap(function ()
923co=coroutine.wrap(function ()
924local xx <close> = func2close(function (_,err)
924local xx <close> = func2close(function (_,err)
925−y=y + 1
925+y=y + 0x1
926;
926;
927assert(string.find(err,"\u{58}\u{58}\u{58}"))
927assert(string.find(err,"\u{58}\u{58}\u{58}"))
928error("\u{59}\u{59}\u{59}")
928error("\u{59}\u{59}\u{59}")
929end)
929end)
930local xv <close> = func2close(function ()
930local xv <close> = func2close(function ()
931−x=x + 1
931+x=x + 0x1
932;
932;
933error("\u{58}\u{58}\u{58}")
933error("\u{58}\u{58}\u{58}")
934end)
934end)
935−coroutine.yield(100)
935+coroutine.yield(0x64)
936−return 200
936+return 0xc8
937end)
937end)
938−assert(co() == 100)
938+assert(co() == 0x64)
939;
939;
940−assert(x == 0)
940+assert(x == 0x0)
941local st,msg = pcall(co)
941local st,msg = pcall(co)
942−assert(x == 1 and y == 1)
942+assert(x == 0x1 and y == 0x1)
943assert(not st and string.find(msg,"\u{25}\u{77}\u{2b}\u{25}\u{2e}\u{25}\u{77}\u{2b}\u{3a}\u{25}\u{64}\u{2b}\u{3a}\u{20}\u{59}\u{59}\u{59}"))
943assert(not st and string.find(msg,"\u{25}\u{77}\u{2b}\u{25}\u{2e}\u{25}\u{77}\u{2b}\u{3a}\u{25}\u{64}\u{2b}\u{3a}\u{20}\u{59}\u{59}\u{59}"))
944end
944end
945local co
945local co
@@ -956,21 +956,21 @@ collectgarbage()
956if rawget(_G,"\u{54}") then
956if rawget(_G,"\u{54}") then
957print("\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{78}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{43}")
957print("\u{74}\u{6f}\u{2d}\u{62}\u{65}\u{2d}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{64}\u{20}\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{78}\u{20}\u{63}\u{6f}\u{72}\u{6f}\u{75}\u{74}\u{69}\u{6e}\u{65}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{43}")
958do
958do
959−local token = 0
959+local token = 0x0
960−local count = 0
960+local count = 0x0
961local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2e}\u{a}\u{20}\u{20}\u{20}\u{20}")
961local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{32}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2e}\u{a}\u{20}\u{20}\u{20}\u{20}")
962local obj = func2close(function (_,msg)
962local obj = func2close(function (_,msg)
963−count=count + 1
963+count=count + 0x1
964token=coroutine.yield(count,token)
964token=coroutine.yield(count,token)
965end)
965end)
966local co = coroutine.wrap(f)
966local co = coroutine.wrap(f)
967−local ct,res = co(obj,obj,10,20,30,3)
967+local ct,res = co(obj,obj,0xa,0x14,0x1e,0x3)
968−assert(ct == 1 and res == 0)
968+assert(ct == 0x1 and res == 0x0)
969−ct,res=co(100)
969+ct,res=co(0x64)
970−assert(ct == 2 and res == 100)
970+assert(ct == 0x2 and res == 0x64)
971−res={co(200)}
971+res={co(0xc8)}
972−assert(res[1] == 10 and res[2] == 20 and res[3] == 30 and res[4] == nil)
972+assert(res[0x1] == 0xa and res[0x2] == 0x14 and res[0x3] == 0x1e and res[0x4] == nil)
973−assert(token == 200)
973+assert(token == 0xc8)
974end
974end
975do
975do
976local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2e}\u{a}\u{20}\u{20}\u{20}\u{20}")
976local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2e}\u{a}\u{20}\u{20}\u{20}\u{20}")
@@ -978,18 +978,18 @@ local obj = func2close(function ()
978local temp
978local temp
979local x <close> = func2close(function ()
979local x <close> = func2close(function ()
980coroutine.yield(temp)
980coroutine.yield(temp)
981−return 1,2,3
981+return 0x1,0x2,0x3
982end)
982end)
983temp=coroutine.yield("\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{62}\u{6a}")
983temp=coroutine.yield("\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{62}\u{6a}")
984−return 1,2,3
984+return 0x1,0x2,0x3
985end)
985end)
986local co = coroutine.wrap(f)
986local co = coroutine.wrap(f)
987−local res = co(obj,10,30,1)
987+local res = co(obj,0xa,0x1e,0x1)
988assert(res == "\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{62}\u{6a}")
988assert(res == "\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{62}\u{6a}")
989res=co("\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{78}")
989res=co("\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{78}")
990assert(res == "\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{78}")
990assert(res == "\u{63}\u{6c}\u{6f}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{78}")
991res={co()}
991res={co()}
992−assert(res[1] == 30 and res[2] == nil)
992+assert(res[0x1] == 0x1e and res[0x2] == nil)
993end
993end
994do
994do
995local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{73}\u{6c}\u{6f}\u{74}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}")
995local f = T.makeCfunc("\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{74}\u{6f}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{63}\u{6c}\u{6f}\u{73}\u{65}\u{73}\u{6c}\u{6f}\u{74}\u{20}\u{31}\u{a}\u{20}\u{20}\u{20}\u{20}")
@@ -1003,48 +1003,48 @@ assert(not st and string.find(msg,"\u{61}\u{74}\u{74}\u{65}\u{6d}\u{70}\u{74}\u{
1003end
1003end
1004end
1004end
1005do
1005do
1006−local numopen = 0
1006+local numopen = 0x0
1007local function open
1007local function open
1008(x)
1008(x)
1009−numopen=numopen + 1
1009+numopen=numopen + 0x1
1010return function ()
1010return function ()
1011−x=x - 1
1011+x=x - 0x1
1012−if x > 0 then
1012+if x > 0x0 then
1013return x
1013return x
1014end
1014end
1015end,nil,nil,func2close(function ()
1015end,nil,nil,func2close(function ()
1016−numopen=numopen - 1
1016+numopen=numopen - 0x1
1017end)
1017end)
1018end
1018end
1019−local s = 0
1019+local s = 0x0
1020−for i in open(10)
1020+for i in open(0xa)
1021do
1021do
1022s=s + i
1022s=s + i
1023end
1023end
1024−assert(s == 45 and numopen == 0)
1024+assert(s == 0x2d and numopen == 0x0)
1025−local s = 0
1025+local s = 0x0
1026−for i in open(10)
1026+for i in open(0xa)
1027do
1027do
1028−if i < 5 then
1028+if i < 0x5 then
1029break
1029break
1030end
1030end
1031s=s + i
1031s=s + i
1032end
1032end
1033−assert(s == 35 and numopen == 0)
1033+assert(s == 0x23 and numopen == 0x0)
1034−local s = 0
1034+local s = 0x0
1035−for i in open(10)
1035+for i in open(0xa)
1036do
1036do
1037−for j in open(10)
1037+for j in open(0xa)
1038do
1038do
1039−if i + j < 5 then
1039+if i + j < 0x5 then
1040goto endloop
1040goto endloop
1041end
1041end
1042s=s + i
1042s=s + i
1043end
1043end
1044end
1044end
1045::endloop::
1045::endloop::
1046−assert(s == 375 and numopen == 0)
1046+assert(s == 0x177 and numopen == 0x0)
1047end
1047end
1048print("\u{4f}\u{4b}")
1048print("\u{4f}\u{4b}")
1049−return 5,f
1049+return 0x5,f
1050end
1050end
zod/luau/res/lua/cycled/main.lua+14−14
@@ -9,11 +9,11 @@ local otherprog = os.tmpname()
9local out = os.tmpname()
9local out = os.tmpname()
10local progname
10local progname
11do
11do
12−local i = 0
12+local i = 0x0
13while arg[i] do
13while arg[i] do
14−i=i - 1
14+i=i - 0x1
15end
15end
16−progname=arg[i + 1]
16+progname=arg[i + 0x1]
17end
17end
18print("\u{70}\u{72}\u{6f}\u{67}\u{6e}\u{61}\u{6d}\u{65}\u{3a}\u{20}" .. progname)
18print("\u{70}\u{72}\u{6f}\u{67}\u{6e}\u{61}\u{6d}\u{65}\u{3a}\u{20}" .. progname)
19local prepfile = function (s,mod,p)
19local prepfile = function (s,mod,p)
@@ -33,11 +33,11 @@ return t
33end
33end
34local function checkprogout
34local function checkprogout
35(s)
35(s)
36−assert(string.sub(s,- 1) == "\u{a}")
36+assert(string.sub(s,- 0x1) == "\u{a}")
37local t = getoutput()
37local t = getoutput()
38for line in string.gmatch(s,"\u{2e}\u{2d}\u{a}")
38for line in string.gmatch(s,"\u{2e}\u{2d}\u{a}")
39do
39do
40−assert(string.find(t,line,1,true))
40+assert(string.find(t,line,0x1,true))
41end
41end
42end
42end
43local function checkout
43local function checkout
@@ -51,17 +51,17 @@ return t
51end
51end
52local function RUN
52local function RUN
53(p, ...)
53(p, ...)
54−p=string.gsub(p,"\u{6c}\u{75}\u{61}","\u{22}" .. progname .. "\u{22}",1)
54+p=string.gsub(p,"\u{6c}\u{75}\u{61}","\u{22}" .. progname .. "\u{22}",0x1)
55local s = string.format(p,...)
55local s = string.format(p,...)
56assert(os.execute(s))
56assert(os.execute(s))
57end
57end
58local function NoRun
58local function NoRun
59(msg,p, ...)
59(msg,p, ...)
60−p=string.gsub(p,"\u{6c}\u{75}\u{61}","\u{22}" .. progname .. "\u{22}",1)
60+p=string.gsub(p,"\u{6c}\u{75}\u{61}","\u{22}" .. progname .. "\u{22}",0x1)
61local s = string.format(p,...)
61local s = string.format(p,...)
62s=string.format("\u{25}\u{73}\u{20}\u{3e}\u{25}\u{73}\u{20}\u{32}\u{3e}\u{26}\u{31}",s,out)
62s=string.format("\u{25}\u{73}\u{20}\u{3e}\u{25}\u{73}\u{20}\u{32}\u{3e}\u{26}\u{31}",s,out)
63assert(not os.execute(s))
63assert(not os.execute(s))
64−assert(string.find(getoutput(),msg,1,true))
64+assert(string.find(getoutput(),msg,0x1,true))
65end
65end
66RUN("\u{6c}\u{75}\u{61}\u{20}\u{2d}\u{76}")
66RUN("\u{6c}\u{75}\u{61}\u{20}\u{2d}\u{76}")
67print(string.format("\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{20}\u{75}\u{73}\u{65}\u{64}\u{20}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{65}\u{73}\u{65}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{3a}\u{20}\u{25}\u{73}\u{29}",prog))
67print(string.format("\u{28}\u{74}\u{65}\u{6d}\u{70}\u{6f}\u{72}\u{61}\u{72}\u{79}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{20}\u{66}\u{69}\u{6c}\u{65}\u{20}\u{75}\u{73}\u{65}\u{64}\u{20}\u{69}\u{6e}\u{20}\u{74}\u{68}\u{65}\u{73}\u{65}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{3a}\u{20}\u{25}\u{73}\u{29}",prog))
@@ -130,7 +130,7 @@ local function convert
130prepfile("\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{70}\u{61}\u{63}\u{6b}\u{61}\u{67}\u{65}\u{2e}\u{70}\u{61}\u{74}\u{68}\u{29}")
130prepfile("\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{70}\u{61}\u{63}\u{6b}\u{61}\u{67}\u{65}\u{2e}\u{70}\u{61}\u{74}\u{68}\u{29}")
131RUN("\u{65}\u{6e}\u{76}\u{20}\u{4c}\u{55}\u{41}\u{5f}\u{50}\u{41}\u{54}\u{48}\u{3d}\u{22}\u{25}\u{73}\u{22}\u{20}\u{6c}\u{75}\u{61}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",p,prog,out)
131RUN("\u{65}\u{6e}\u{76}\u{20}\u{4c}\u{55}\u{41}\u{5f}\u{50}\u{41}\u{54}\u{48}\u{3d}\u{22}\u{25}\u{73}\u{22}\u{20}\u{6c}\u{75}\u{61}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",p,prog,out)
132local expected = getoutput()
132local expected = getoutput()
133−expected=string.sub(expected,1,- 2)
133+expected=string.sub(expected,0x1,- 0x2)
134if string.find(p,"\u{3b}\u{3b}") then
134if string.find(p,"\u{3b}\u{3b}") then
135p=string.gsub(p,"\u{3b}\u{3b}","\u{3b}" .. defaultpath .. "\u{3b}")
135p=string.gsub(p,"\u{3b}\u{3b}","\u{3b}" .. defaultpath .. "\u{3b}")
136p=string.gsub(p,"\u{5e}\u{3b}","")
136p=string.gsub(p,"\u{5e}\u{3b}","")
@@ -180,7 +180,7 @@ prepfile("\u{2d}\u{2d}\u{20}\u{73}\u{68}\u{6f}\u{75}\u{6c}\u{64}\u{20}\u{62}\u{6
180RUN("\u{6c}\u{75}\u{61}\u{20}\u{2d}\u{57}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",prog,out)
180RUN("\u{6c}\u{75}\u{61}\u{20}\u{2d}\u{57}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",prog,out)
181checkout("\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{a}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{a}\u{32}\u{a}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{33}\u{a}\u{6e}\u{69}\u{6c}\u{a}\u{31}\u{a}")
181checkout("\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{31}\u{a}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{32}\u{a}\u{32}\u{a}\u{63}\u{72}\u{65}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{33}\u{a}\u{6e}\u{69}\u{6c}\u{a}\u{31}\u{a}")
182prepfile("\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{28}\u{7b}\u{2e}\u{2e}\u{2e}\u{7d}\u{29}\u{5b}\u{33}\u{30}\u{5d}\u{29}")
182prepfile("\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{28}\u{7b}\u{2e}\u{2e}\u{2e}\u{7d}\u{29}\u{5b}\u{33}\u{30}\u{5d}\u{29}")
183−RUN("\u{6c}\u{75}\u{61}\u{20}\u{25}\u{73}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",prog,string.rep("\u{20}\u{61}",30),out)
183+RUN("\u{6c}\u{75}\u{61}\u{20}\u{25}\u{73}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",prog,string.rep("\u{20}\u{61}",0x1e),out)
184checkout("\u{61}\u{a}")
184checkout("\u{61}\u{a}")
185RUN("\u{6c}\u{75}\u{61}\u{20}\u{22}\u{2d}\u{65}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{31}\u{29}\u{22}\u{20}\u{2d}\u{65}\u{61}\u{3d}\u{33}\u{20}\u{2d}\u{65}\u{20}\u{22}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{61}\u{29}\u{22}\u{20}\u{3e}\u{20}\u{25}\u{73}",out)
185RUN("\u{6c}\u{75}\u{61}\u{20}\u{22}\u{2d}\u{65}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{31}\u{29}\u{22}\u{20}\u{2d}\u{65}\u{61}\u{3d}\u{33}\u{20}\u{2d}\u{65}\u{20}\u{22}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{61}\u{29}\u{22}\u{20}\u{3e}\u{20}\u{25}\u{73}",out)
186checkout("\u{31}\u{a}\u{33}\u{a}")
186checkout("\u{31}\u{a}\u{33}\u{a}")
@@ -204,7 +204,7 @@ prompt="\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{43}\u{20}\u{3d}\u{20}\u{30}\u{3b}
204prepfile("\u{20}\u{2d}\u{2d}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{32}\u{a}")
204prepfile("\u{20}\u{2d}\u{2d}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{32}\u{a}")
205RUN("\u{6c}\u{75}\u{61}\u{20}\u{2d}\u{65}\u{20}\u{22}\u{25}\u{73}\u{22}\u{20}\u{2d}\u{69}\u{20}\u{3c}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",prompt,prog,out)
205RUN("\u{6c}\u{75}\u{61}\u{20}\u{2d}\u{65}\u{20}\u{22}\u{25}\u{73}\u{22}\u{20}\u{2d}\u{69}\u{20}\u{3c}\u{20}\u{25}\u{73}\u{20}\u{3e}\u{20}\u{25}\u{73}",prompt,prog,out)
206local t = getoutput()
206local t = getoutput()
207−assert(string.find(t,"\u{31}\u{20}\u{2d}\u{2d}\u{a}\u{32}\u{61}\u{20}\u{3d}\u{20}\u{32}\u{a}\u{33}\u{a}",1,true))
207+assert(string.find(t,"\u{31}\u{20}\u{2d}\u{2d}\u{a}\u{32}\u{61}\u{20}\u{3d}\u{20}\u{32}\u{a}\u{33}\u{a}",0x1,true))
208prepfile("\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{20}\u{22}\u{64}\u{65}\u{62}\u{75}\u{67}\u{22}\u{a}\u{6d}\u{20}\u{3d}\u{20}\u{7b}\u{78}\u{3d}\u{30}\u{7d}\u{a}\u{73}\u{65}\u{74}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{28}\u{6d}\u{2c}\u{20}\u{7b}\u{5f}\u{5f}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{28}\u{78}\u{29}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{34}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{2b}\u{20}\u{78}\u{2e}\u{78}\u{29}\u{a}\u{65}\u{6e}\u{64}\u{7d}\u{29}\u{a}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{6d}\u{29}\u{a}")
208prepfile("\u{64}\u{65}\u{62}\u{75}\u{67}\u{20}\u{3d}\u{20}\u{72}\u{65}\u{71}\u{75}\u{69}\u{72}\u{65}\u{20}\u{22}\u{64}\u{65}\u{62}\u{75}\u{67}\u{22}\u{a}\u{6d}\u{20}\u{3d}\u{20}\u{7b}\u{78}\u{3d}\u{30}\u{7d}\u{a}\u{73}\u{65}\u{74}\u{6d}\u{65}\u{74}\u{61}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{28}\u{6d}\u{2c}\u{20}\u{7b}\u{5f}\u{5f}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{20}\u{3d}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{28}\u{78}\u{29}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{28}\u{64}\u{65}\u{62}\u{75}\u{67}\u{2e}\u{67}\u{65}\u{74}\u{69}\u{6e}\u{66}\u{6f}\u{28}\u{34}\u{29}\u{2e}\u{63}\u{75}\u{72}\u{72}\u{65}\u{6e}\u{74}\u{6c}\u{69}\u{6e}\u{65}\u{20}\u{2b}\u{20}\u{78}\u{2e}\u{78}\u{29}\u{a}\u{65}\u{6e}\u{64}\u{7d}\u{29}\u{a}\u{65}\u{72}\u{72}\u{6f}\u{72}\u{28}\u{6d}\u{29}\u{a}")
209NoRun(progname .. "\u{3a}\u{20}\u{36}\u{a}","\u{6c}\u{75}\u{61}\u{20}\u{25}\u{73}",prog)
209NoRun(progname .. "\u{3a}\u{20}\u{36}\u{a}","\u{6c}\u{75}\u{61}\u{20}\u{25}\u{73}",prog)
210prepfile("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{7b}\u{7d}")
210prepfile("\u{65}\u{72}\u{72}\u{6f}\u{72}\u{7b}\u{7d}")
@@ -297,8 +297,8 @@ print("\u{64}\u{6f}\u{6e}\u{65}")
297local f,pid = runback("\u{20}\u{20}\u{20}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{31}\u{35}\u{29}\u{3b}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{66}\u{69}\u{6e}\u{64}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{72}\u{65}\u{70}\u{28}\u{27}\u{61}\u{27}\u{2c}\u{20}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{29}\u{2c}\u{20}\u{27}\u{2e}\u{2a}\u{62}\u{27}\u{29}")
297local f,pid = runback("\u{20}\u{20}\u{20}\u{20}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{28}\u{31}\u{35}\u{29}\u{3b}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{66}\u{69}\u{6e}\u{64}\u{28}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{2e}\u{72}\u{65}\u{70}\u{28}\u{27}\u{61}\u{27}\u{2c}\u{20}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{29}\u{2c}\u{20}\u{27}\u{2e}\u{2a}\u{62}\u{27}\u{29}")
298assert(f:read() == "\u{31}\u{35}")
298assert(f:read() == "\u{31}\u{35}")
299assert(os.execute("\u{73}\u{6c}\u{65}\u{65}\u{70}\u{20}\u{31}"))
299assert(os.execute("\u{73}\u{6c}\u{65}\u{65}\u{70}\u{20}\u{31}"))
300−local n = 100
300+local n = 0x64
301−for i = 0, 100
301+for i = 0x0, 0x64
302do
302do
303if not kill(pid) then
303if not kill(pid) then
304n=i
304n=i
@@ -306,7 +306,7 @@ break
306end
306end
307end
307end
308assert(f:close())
308assert(f:close())
309−assert(n >= 2)
309+assert(n >= 0x2)
310print(string.format("\u{64}\u{6f}\u{6e}\u{65}\u{20}\u{28}\u{77}\u{69}\u{74}\u{68}\u{20}\u{25}\u{64}\u{20}\u{6b}\u{69}\u{6c}\u{6c}\u{73}\u{29}",n))
310print(string.format("\u{64}\u{6f}\u{6e}\u{65}\u{20}\u{28}\u{77}\u{69}\u{74}\u{68}\u{20}\u{25}\u{64}\u{20}\u{6b}\u{69}\u{6c}\u{6c}\u{73}\u{29}",n))
311end
311end
312print("\u{4f}\u{4b}")
312print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/math.lua+382−382
@@ -1,30 +1,30 @@
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{73}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{20}\u{6c}\u{69}\u{62}")
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{73}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{20}\u{6c}\u{69}\u{62}")
2local minint <const> = math.mininteger
2local minint <const> = math.mininteger
3local maxint <const> = math.maxinteger
3local maxint <const> = math.maxinteger
4−local intbits <const> = math.floor(math.log(maxint,2) + 0.5) + 1
4+local intbits <const> = math.floor(math.log(maxint,0x2) + 0.5) + 0x1
5−assert((1 << intbits) == 0)
5+assert((0x1 << intbits) == 0x0)
6−assert(minint == 1 << (intbits - 1))
6+assert(minint == 0x1 << (intbits - 0x1))
7−assert(maxint == minint - 1)
7+assert(maxint == minint - 0x1)
8−local floatbits = 24
8+local floatbits = 0x18
9do
9do
10local p = 2.0 ^ floatbits
10local p = 2.0 ^ floatbits
11while p < p + 1.0 do
11while p < p + 1.0 do
12p=p * 2.0
12p=p * 2.0
13−floatbits=floatbits + 1
13+floatbits=floatbits + 0x1
14end
14end
15end
15end
16local function isNaN
16local function isNaN
17(x)
17(x)
18return (x ~= x)
18return (x ~= x)
19end
19end
20−assert(isNaN(0 / 0))
20+assert(isNaN(0x0 / 0x0))
21−assert(not isNaN(1 / 0))
21+assert(not isNaN(0x1 / 0x0))
22do
22do
23local x = 2.0 ^ floatbits
23local x = 2.0 ^ floatbits
24assert(x > x - 1.0 and x == x + 1.0)
24assert(x > x - 1.0 and x == x + 1.0)
25print(string.format("\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{2c}\u{20}\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{28}\u{6d}\u{61}\u{6e}\u{74}\u{69}\u{73}\u{73}\u{61}\u{29}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}",intbits,floatbits))
25print(string.format("\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{2c}\u{20}\u{25}\u{64}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{28}\u{6d}\u{61}\u{6e}\u{74}\u{69}\u{73}\u{73}\u{61}\u{29}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}",intbits,floatbits))
26end
26end
27−assert(math.type(0) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}" and math.type(0.0) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}" and not math.type("\u{31}\u{30}"))
27+assert(math.type(0x0) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}" and math.type(0.0) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}" and not math.type("\u{31}\u{30}"))
28local function checkerror
28local function checkerror
29(msg,f, ...)
29(msg,f, ...)
30local s,err = pcall(f,...)
30local s,err = pcall(f,...)
@@ -34,7 +34,7 @@ local msgf2i = "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{2e}\u{2a}\u{20}\u{68}\u{6
34local function eq
34local function eq
35(a,b,limit)
35(a,b,limit)
36if not limit then
36if not limit then
37−if floatbits >= 50 then
37+if floatbits >= 0x32 then
38limit=1e-11
38limit=1e-11
39else
39else
40limit=1e-5
40limit=1e-5
@@ -46,21 +46,21 @@ local function eqT
46(a,b)
46(a,b)
47return a == b and math.type(a) == math.type(b)
47return a == b and math.type(a) == math.type(b)
48end
48end
49−assert(0.0 == 0 and 0.0 == 0 and 0.0 == 0 and 20.0 == 20 and 0.2 == 0.2)
49+assert(0.0 == 0x0 and 0.0 == 0x0 and 0.0 == 0x0 and 20.0 == 0x14 and 0.2 == 0.2)
50do
50do
51local a,b,c = "\u{32}","\u{20}\u{33}\u{65}\u{30}\u{20}","\u{20}\u{31}\u{30}\u{20}\u{20}"
51local a,b,c = "\u{32}","\u{20}\u{33}\u{65}\u{30}\u{20}","\u{20}\u{31}\u{30}\u{20}\u{20}"
52−assert(a + b == 5 and - b == - 3 and b + "\u{32}" == 5 and "\u{31}\u{30}" - c == 0)
52+assert(a + b == 0x5 and - b == - 0x3 and b + "\u{32}" == 0x5 and "\u{31}\u{30}" - c == 0x0)
53assert(type(a) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(b) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(c) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
53assert(type(a) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(b) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" and type(c) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
54assert(a == "\u{32}" and b == "\u{20}\u{33}\u{65}\u{30}\u{20}" and c == "\u{20}\u{31}\u{30}\u{20}\u{20}" and - c == - "\u{20}\u{20}\u{31}\u{30}\u{20}")
54assert(a == "\u{32}" and b == "\u{20}\u{33}\u{65}\u{30}\u{20}" and c == "\u{20}\u{31}\u{30}\u{20}\u{20}" and - c == - "\u{20}\u{20}\u{31}\u{30}\u{20}")
55−assert(c % a == 0 and a ^ b == 8)
55+assert(c % a == 0x0 and a ^ b == 0x8)
56−a=0
56+a=0x0
57−assert(a == - a and 0 == - 0)
57+assert(a == - a and 0x0 == - 0x0)
58end
58end
59do
59do
60−local x = - 1
60+local x = - 0x1
61−local mz = 0 / x
61+local mz = 0x0 / x
62−local t = {[0] = 10,20,30,40,50}
62+local t = {[0x0] = 0xa,0x14,0x1e,0x28,0x32}
63−assert(t[mz] == t[0] and t[- 0] == t[0])
63+assert(t[mz] == t[0x0] and t[- 0x0] == t[0x0])
64end
64end
65do
65do
66local a,b = math.modf(3.5)
66local a,b = math.modf(3.5)
@@ -71,31 +71,31 @@ a,b=math.modf(- 3e23)
71assert(a == - 3e23 and b == 0.0)
71assert(a == - 3e23 and b == 0.0)
72a,b=math.modf(3e35)
72a,b=math.modf(3e35)
73assert(a == 3e35 and b == 0.0)
73assert(a == 3e35 and b == 0.0)
74−a,b=math.modf(- 1 / 0)
74+a,b=math.modf(- 0x1 / 0x0)
75−assert(a == - 1 / 0 and b == 0.0)
75+assert(a == - 0x1 / 0x0 and b == 0.0)
76−a,b=math.modf(1 / 0)
76+a,b=math.modf(0x1 / 0x0)
77−assert(a == 1 / 0 and b == 0.0)
77+assert(a == 0x1 / 0x0 and b == 0.0)
78−a,b=math.modf(0 / 0)
78+a,b=math.modf(0x0 / 0x0)
79assert(isNaN(a) and isNaN(b))
79assert(isNaN(a) and isNaN(b))
80−a,b=math.modf(3)
80+a,b=math.modf(0x3)
81−assert(eqT(a,3) and eqT(b,0.0))
81+assert(eqT(a,0x3) and eqT(b,0.0))
82a,b=math.modf(minint)
82a,b=math.modf(minint)
83assert(eqT(a,minint) and eqT(b,0.0))
83assert(eqT(a,minint) and eqT(b,0.0))
84end
84end
85assert(math.huge > 1e31)
85assert(math.huge > 1e31)
86assert(- math.huge < - 1e31)
86assert(- math.huge < - 1e31)
87−assert(minint < minint + 1)
87+assert(minint < minint + 0x1)
88−assert(maxint - 1 < maxint)
88+assert(maxint - 0x1 < maxint)
89−assert(0 - minint == minint)
89+assert(0x0 - minint == minint)
90−assert(minint * minint == 0)
90+assert(minint * minint == 0x0)
91assert(maxint * maxint * maxint == maxint)
91assert(maxint * maxint * maxint == maxint)
92−for _,i in pairs({- 16,- 15,- 3,- 2,- 1,0,1,2,3,15})
92+for _,i in pairs({- 0x10,- 0xf,- 0x3,- 0x2,- 0x1,0x0,0x1,0x2,0x3,0xf})
93do
93do
94−for _,j in pairs({- 16,- 15,- 3,- 2,- 1,1,2,3,15})
94+for _,j in pairs({- 0x10,- 0xf,- 0x3,- 0x2,- 0x1,0x1,0x2,0x3,0xf})
95do
95do
96−for _,ti in pairs({0,0.0})
96+for _,ti in pairs({0x0,0.0})
97do
97do
98−for _,tj in pairs({0,0.0})
98+for _,tj in pairs({0x0,0.0})
99do
99do
100local x = i + ti
100local x = i + ti
101local y = j + tj
101local y = j + tj
@@ -104,22 +104,22 @@ end
104end
104end
105end
105end
106end
106end
107−assert(1 // 0.0 == 1 / 0)
107+assert(0x1 // 0.0 == 0x1 / 0x0)
108−assert(- 1 // 0.0 == - 1 / 0)
108+assert(- 0x1 // 0.0 == - 0x1 / 0x0)
109assert(eqT(3.5 // 1.5,2.0))
109assert(eqT(3.5 // 1.5,2.0))
110assert(eqT(3.5 // - 1.5,- 3.0))
110assert(eqT(3.5 // - 1.5,- 3.0))
111do
111do
112local x,y
112local x,y
113−x=1
113+x=0x1
114;
114;
115−assert(x // 0.0 == 1 / 0)
115+assert(x // 0.0 == 0x1 / 0x0)
116x=1.0
116x=1.0
117;
117;
118−assert(x // 0 == 1 / 0)
118+assert(x // 0x0 == 0x1 / 0x0)
119x=3.5
119x=3.5
120;
120;
121−assert(eqT(x // 1,3.0))
121+assert(eqT(x // 0x1,3.0))
122−assert(eqT(x // - 1,- 4.0))
122+assert(eqT(x // - 0x1,- 4.0))
123x=3.5
123x=3.5
124;
124;
125y=1.5
125y=1.5
@@ -131,63 +131,63 @@ y=- 1.5
131;
131;
132assert(eqT(x // y,- 3.0))
132assert(eqT(x // y,- 3.0))
133end
133end
134−assert(maxint // maxint == 1)
134+assert(maxint // maxint == 0x1)
135−assert(maxint // 1 == maxint)
135+assert(maxint // 0x1 == maxint)
136−assert((maxint - 1) // maxint == 0)
136+assert((maxint - 0x1) // maxint == 0x0)
137−assert(maxint // (maxint - 1) == 1)
137+assert(maxint // (maxint - 0x1) == 0x1)
138−assert(minint // minint == 1)
138+assert(minint // minint == 0x1)
139−assert(minint // minint == 1)
139+assert(minint // minint == 0x1)
140−assert((minint + 1) // minint == 0)
140+assert((minint + 0x1) // minint == 0x0)
141−assert(minint // (minint + 1) == 1)
141+assert(minint // (minint + 0x1) == 0x1)
142−assert(minint // 1 == minint)
142+assert(minint // 0x1 == minint)
143−assert(minint // - 1 == - minint)
143+assert(minint // - 0x1 == - minint)
144−assert(minint // - 2 == 2 ^ (intbits - 2))
144+assert(minint // - 0x2 == 0x2 ^ (intbits - 0x2))
145−assert(maxint // - 1 == - maxint)
145+assert(maxint // - 0x1 == - maxint)
146do
146do
147−assert(2 ^ - 3 == 1 / 2 ^ 3)
147+assert(0x2 ^ - 0x3 == 0x1 / 0x2 ^ 0x3)
148−assert(eq((- 3) ^ - 3,1 / (- 3) ^ 3))
148+assert(eq((- 0x3) ^ - 0x3,0x1 / (- 0x3) ^ 0x3))
149−for i = - 3, 3
149+for i = - 0x3, 0x3
150do
150do
151−for j = - 3, 3
151+for j = - 0x3, 0x3
152do
152do
153−if not _port or i ~= 0 or j > 0 then
153+if not _port or i ~= 0x0 or j > 0x0 then
154−assert(eq(i ^ j,1 / i ^ (- j)))
154+assert(eq(i ^ j,0x1 / i ^ (- j)))
155end
155end
156end
156end
157end
157end
158end
158end
159if floatbits < intbits then
159if floatbits < intbits then
160−assert(2.0 ^ floatbits == (1 << floatbits))
160+assert(2.0 ^ floatbits == (0x1 << floatbits))
161−assert(2.0 ^ floatbits - 1.0 == (1 << floatbits) - 1.0)
161+assert(2.0 ^ floatbits - 1.0 == (0x1 << floatbits) - 1.0)
162−assert(2.0 ^ floatbits - 1.0 ~= (1 << floatbits))
162+assert(2.0 ^ floatbits - 1.0 ~= (0x1 << floatbits))
163−assert(2.0 ^ floatbits + 1.0 ~= (1 << floatbits) + 1)
163+assert(2.0 ^ floatbits + 1.0 ~= (0x1 << floatbits) + 0x1)
164else
164else
165assert(maxint == maxint + 0.0)
165assert(maxint == maxint + 0.0)
166−assert(maxint - 1 == maxint - 1.0)
166+assert(maxint - 0x1 == maxint - 1.0)
167−assert(minint + 1 == minint + 1.0)
167+assert(minint + 0x1 == minint + 1.0)
168assert(maxint ~= maxint - 1.0)
168assert(maxint ~= maxint - 1.0)
169end
169end
170−assert(maxint + 0.0 == 2.0 ^ (intbits - 1) - 1.0)
170+assert(maxint + 0.0 == 2.0 ^ (intbits - 0x1) - 1.0)
171assert(minint + 0.0 == minint)
171assert(minint + 0.0 == minint)
172−assert(minint + 0.0 == - 2.0 ^ (intbits - 1))
172+assert(minint + 0.0 == - 2.0 ^ (intbits - 0x1))
173−assert(1 < 1.1)
173+assert(0x1 < 1.1)
174;
174;
175−assert(not (1 < 0.9))
175+assert(not (0x1 < 0.9))
176−assert(1 <= 1.1)
176+assert(0x1 <= 1.1)
177;
177;
178−assert(not (1 <= 0.9))
178+assert(not (0x1 <= 0.9))
179−assert(- 1 < - 0.9)
179+assert(- 0x1 < - 0.9)
180;
180;
181−assert(not (- 1 < - 1.1))
181+assert(not (- 0x1 < - 1.1))
182−assert(1 <= 1.1)
182+assert(0x1 <= 1.1)
183;
183;
184−assert(not (- 1 <= - 1.1))
184+assert(not (- 0x1 <= - 1.1))
185−assert(- 1 < - 0.9)
185+assert(- 0x1 < - 0.9)
186;
186;
187−assert(not (- 1 < - 1.1))
187+assert(not (- 0x1 < - 1.1))
188−assert(- 1 <= - 0.9)
188+assert(- 0x1 <= - 0.9)
189;
189;
190−assert(not (- 1 <= - 1.1))
190+assert(not (- 0x1 <= - 1.1))
191assert(minint <= minint + 0.0)
191assert(minint <= minint + 0.0)
192assert(minint + 0.0 <= minint)
192assert(minint + 0.0 <= minint)
193assert(not (minint < minint + 0.0))
193assert(not (minint < minint + 0.0))
@@ -195,29 +195,29 @@ assert(not (minint + 0.0 < minint))
195assert(maxint < minint * - 1.0)
195assert(maxint < minint * - 1.0)
196assert(maxint <= minint * - 1.0)
196assert(maxint <= minint * - 1.0)
197do
197do
198−local fmaxi1 = 2 ^ (intbits - 1)
198+local fmaxi1 = 0x2 ^ (intbits - 0x1)
199assert(maxint < fmaxi1)
199assert(maxint < fmaxi1)
200assert(maxint <= fmaxi1)
200assert(maxint <= fmaxi1)
201assert(not (fmaxi1 <= maxint))
201assert(not (fmaxi1 <= maxint))
202−assert(minint <= - 2 ^ (intbits - 1))
202+assert(minint <= - 0x2 ^ (intbits - 0x1))
203−assert(- 2 ^ (intbits - 1) <= minint)
203+assert(- 0x2 ^ (intbits - 0x1) <= minint)
204end
204end
205if floatbits < intbits then
205if floatbits < intbits then
206print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{20}\u{28}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{20}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{29}")
206print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{20}\u{28}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{20}\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{20}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{29}")
207−local fmax = 2 ^ floatbits
207+local fmax = 0x2 ^ floatbits
208−local ifmax = fmax | 0
208+local ifmax = fmax | 0x0
209−assert(fmax < ifmax + 1)
209+assert(fmax < ifmax + 0x1)
210−assert(fmax - 1 < ifmax)
210+assert(fmax - 0x1 < ifmax)
211−assert(- (fmax - 1) > - ifmax)
211+assert(- (fmax - 0x1) > - ifmax)
212−assert(not (fmax <= ifmax - 1))
212+assert(not (fmax <= ifmax - 0x1))
213−assert(- fmax > - (ifmax + 1))
213+assert(- fmax > - (ifmax + 0x1))
214−assert(not (- fmax >= - (ifmax - 1)))
214+assert(not (- fmax >= - (ifmax - 0x1)))
215−assert(fmax / 2 - 0.5 < ifmax // 2)
215+assert(fmax / 0x2 - 0.5 < ifmax // 0x2)
216−assert(- (fmax / 2 - 0.5) > - ifmax // 2)
216+assert(- (fmax / 0x2 - 0.5) > - ifmax // 0x2)
217−assert(maxint < 2 ^ intbits)
217+assert(maxint < 0x2 ^ intbits)
218−assert(minint > - 2 ^ intbits)
218+assert(minint > - 0x2 ^ intbits)
219−assert(maxint <= 2 ^ intbits)
219+assert(maxint <= 0x2 ^ intbits)
220−assert(minint >= - 2 ^ intbits)
220+assert(minint >= - 0x2 ^ intbits)
221else
221else
222print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{20}\u{28}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{20}\u{63}\u{61}\u{6e}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{20}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{29}")
222print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{20}\u{28}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{20}\u{63}\u{61}\u{6e}\u{20}\u{72}\u{65}\u{70}\u{72}\u{65}\u{73}\u{65}\u{6e}\u{74}\u{20}\u{61}\u{6c}\u{6c}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{73}\u{29}")
223assert(maxint < maxint + 1.0)
223assert(maxint < maxint + 1.0)
@@ -248,16 +248,16 @@ assert(not (minint + 0.5 <= minint))
248assert(not (minint <= minint - 1.0))
248assert(not (minint <= minint - 1.0))
249end
249end
250do
250do
251−local NaN <const> = 0 / 0
251+local NaN <const> = 0x0 / 0x0
252−assert(not (NaN < 0))
252+assert(not (NaN < 0x0))
253assert(not (NaN > minint))
253assert(not (NaN > minint))
254−assert(not (NaN <= - 9))
254+assert(not (NaN <= - 0x9))
255assert(not (NaN <= maxint))
255assert(not (NaN <= maxint))
256assert(not (NaN < maxint))
256assert(not (NaN < maxint))
257assert(not (minint <= NaN))
257assert(not (minint <= NaN))
258assert(not (minint < NaN))
258assert(not (minint < NaN))
259−assert(not (4 <= NaN))
259+assert(not (0x4 <= NaN))
260−assert(not (4 < NaN))
260+assert(not (0x4 < NaN))
261end
261end
262local function checkcompt
262local function checkcompt
263(msg,code)
263(msg,code)
@@ -265,9 +265,9 @@ checkerror(msg,assert(load(code)))
265end
265end
266checkcompt("\u{64}\u{69}\u{76}\u{69}\u{64}\u{65}\u{20}\u{62}\u{79}\u{20}\u{7a}\u{65}\u{72}\u{6f}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{20}\u{2f}\u{2f}\u{20}\u{30}")
266checkcompt("\u{64}\u{69}\u{76}\u{69}\u{64}\u{65}\u{20}\u{62}\u{79}\u{20}\u{7a}\u{65}\u{72}\u{6f}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{20}\u{2f}\u{2f}\u{20}\u{30}")
267checkcompt(msgf2i,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{2e}\u{33}\u{20}\u{3e}\u{3e}\u{20}\u{30}")
267checkcompt(msgf2i,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{2e}\u{33}\u{20}\u{3e}\u{3e}\u{20}\u{30}")
268−checkcompt(msgf2i,("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{2e}\u{30}\u{5e}\u{25}\u{64}\u{20}\u{26}\u{20}\u{31}"):format(intbits - 1))
268+checkcompt(msgf2i,("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{2e}\u{30}\u{5e}\u{25}\u{64}\u{20}\u{26}\u{20}\u{31}"):format(intbits - 0x1))
269checkcompt("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{68}\u{75}\u{67}\u{65}\u{27}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{68}\u{75}\u{67}\u{65}\u{20}\u{3c}\u{3c}\u{20}\u{31}")
269checkcompt("\u{66}\u{69}\u{65}\u{6c}\u{64}\u{20}\u{27}\u{68}\u{75}\u{67}\u{65}\u{27}","\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{6d}\u{61}\u{74}\u{68}\u{2e}\u{68}\u{75}\u{67}\u{65}\u{20}\u{3c}\u{3c}\u{20}\u{31}")
270−checkcompt(msgf2i,("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{7c}\u{20}\u{32}\u{2e}\u{30}\u{5e}\u{25}\u{64}"):format(intbits - 1))
270+checkcompt(msgf2i,("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{20}\u{7c}\u{20}\u{32}\u{2e}\u{30}\u{5e}\u{25}\u{64}"):format(intbits - 0x1))
271checkcompt(msgf2i,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{2e}\u{33}\u{20}\u{7e}\u{20}\u{30}\u{2e}\u{30}")
271checkcompt(msgf2i,"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{32}\u{2e}\u{33}\u{20}\u{7e}\u{20}\u{30}\u{2e}\u{30}")
272local function f2i
272local function f2i
273(x)
273(x)
@@ -275,17 +275,17 @@ return x | x
275end
275end
276checkerror(msgf2i,f2i,math.huge)
276checkerror(msgf2i,f2i,math.huge)
277checkerror(msgf2i,f2i,- math.huge)
277checkerror(msgf2i,f2i,- math.huge)
278−checkerror(msgf2i,f2i,0 / 0)
278+checkerror(msgf2i,f2i,0x0 / 0x0)
279if floatbits < intbits then
279if floatbits < intbits then
280assert(maxint + 1.0 == maxint + 0.0)
280assert(maxint + 1.0 == maxint + 0.0)
281assert(minint - 1.0 == minint + 0.0)
281assert(minint - 1.0 == minint + 0.0)
282checkerror(msgf2i,f2i,maxint + 0.0)
282checkerror(msgf2i,f2i,maxint + 0.0)
283−assert(f2i(2.0 ^ (intbits - 2)) == 1 << (intbits - 2))
283+assert(f2i(2.0 ^ (intbits - 0x2)) == 0x1 << (intbits - 0x2))
284−assert(f2i(- 2.0 ^ (intbits - 2)) == - (1 << (intbits - 2)))
284+assert(f2i(- 2.0 ^ (intbits - 0x2)) == - (0x1 << (intbits - 0x2)))
285−assert((2.0 ^ (floatbits - 1) + 1.0) // 1 == (1 << (floatbits - 1)) + 1)
285+assert((2.0 ^ (floatbits - 0x1) + 1.0) // 0x1 == (0x1 << (floatbits - 0x1)) + 0x1)
286−local mf = maxint - (1 << (floatbits - intbits)) + 1
286+local mf = maxint - (0x1 << (floatbits - intbits)) + 0x1
287assert(f2i(mf + 0.0) == mf)
287assert(f2i(mf + 0.0) == mf)
288−mf=mf + 1
288+mf=mf + 0x1
289assert(f2i(mf + 0.0) ~= mf)
289assert(f2i(mf + 0.0) ~= mf)
290else
290else
291assert(maxint + 1.0 > maxint)
291assert(maxint + 1.0 > maxint)
@@ -295,10 +295,10 @@ checkerror("\u{6e}\u{6f}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u
295checkerror("\u{6e}\u{6f}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u{72}\u{65}\u{70}",f2i,minint - 1.0)
295checkerror("\u{6e}\u{6f}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u{72}\u{65}\u{70}",f2i,minint - 1.0)
296end
296end
297assert(f2i(minint + 0.0) == minint)
297assert(f2i(minint + 0.0) == minint)
298−assert("\u{32}" + 1 == 3)
298+assert("\u{32}" + 0x1 == 0x3)
299−assert("\u{32}\u{20}" + 1 == 3)
299+assert("\u{32}\u{20}" + 0x1 == 0x3)
300−assert("\u{20}\u{2d}\u{32}\u{20}" + 1 == - 1)
300+assert("\u{20}\u{2d}\u{32}\u{20}" + 0x1 == - 0x1)
301−assert("\u{20}\u{2d}\u{30}\u{78}\u{61}\u{20}" + 1 == - 9)
301+assert("\u{20}\u{2d}\u{30}\u{78}\u{61}\u{20}" + 0x1 == - 0x9)
302do
302do
303assert(eqT(tonumber(tostring(maxint)),maxint))
303assert(eqT(tonumber(tostring(maxint)),maxint))
304assert(eqT(tonumber(tostring(minint)),minint))
304assert(eqT(tonumber(tostring(minint)),minint))
@@ -307,84 +307,84 @@ local function incd
307local s = string.format("\u{25}\u{64}",n)
307local s = string.format("\u{25}\u{64}",n)
308s=string.gsub(s,"\u{25}\u{64}\u{24}",function (d)
308s=string.gsub(s,"\u{25}\u{64}\u{24}",function (d)
309assert(d ~= "\u{39}")
309assert(d ~= "\u{39}")
310−return string.char(string.byte(d) + 1)
310+return string.char(string.byte(d) + 0x1)
311end)
311end)
312return s
312return s
313end
313end
314assert(eqT(tonumber(incd(maxint)),maxint + 1.0))
314assert(eqT(tonumber(incd(maxint)),maxint + 1.0))
315assert(eqT(tonumber(incd(minint)),minint - 1.0))
315assert(eqT(tonumber(incd(minint)),minint - 1.0))
316−assert(eqT(tonumber("\u{31}" .. string.rep("\u{30}",30)),1e30))
316+assert(eqT(tonumber("\u{31}" .. string.rep("\u{30}",0x1e)),1e30))
317−assert(eqT(tonumber("\u{2d}\u{31}" .. string.rep("\u{30}",30)),- 1e30))
317+assert(eqT(tonumber("\u{2d}\u{31}" .. string.rep("\u{30}",0x1e)),- 1e30))
318−assert(eqT(tonumber("\u{30}\u{78}\u{31}" .. string.rep("\u{30}",30)),0))
318+assert(eqT(tonumber("\u{30}\u{78}\u{31}" .. string.rep("\u{30}",0x1e)),0x0))
319assert(minint == load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. minint)())
319assert(minint == load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. minint)())
320assert(eqT(maxint,load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. maxint)()))
320assert(eqT(maxint,load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}" .. maxint)()))
321−assert(eqT(1e22,10000000000000000000000))
321+assert(eqT(1e22,1e22))
322−assert(eqT(- 1e22,- 10000000000000000000000))
322+assert(eqT(- 1e22,- 1e22))
323end
323end
324assert(tonumber(3.4) == 3.4)
324assert(tonumber(3.4) == 3.4)
325−assert(eqT(tonumber(3),3))
325+assert(eqT(tonumber(0x3),0x3))
326assert(eqT(tonumber(maxint),maxint) and eqT(tonumber(minint),minint))
326assert(eqT(tonumber(maxint),maxint) and eqT(tonumber(minint),minint))
327−assert(tonumber(1 / 0) == 1 / 0)
327+assert(tonumber(0x1 / 0x0) == 0x1 / 0x0)
328−assert(tonumber("\u{30}") == 0)
328+assert(tonumber("\u{30}") == 0x0)
329assert(not tonumber(""))
329assert(not tonumber(""))
330assert(not tonumber("\u{20}\u{20}"))
330assert(not tonumber("\u{20}\u{20}"))
331assert(not tonumber("\u{2d}"))
331assert(not tonumber("\u{2d}"))
332assert(not tonumber("\u{20}\u{20}\u{2d}\u{30}\u{78}\u{20}"))
332assert(not tonumber("\u{20}\u{20}\u{2d}\u{30}\u{78}\u{20}"))
333assert(not tonumber({}))
333assert(not tonumber({}))
334−assert(tonumber("\u{2b}\u{30}\u{2e}\u{30}\u{31}") == 1 / 100 and tonumber("\u{2b}\u{2e}\u{30}\u{31}") == 0.01 and tonumber("\u{2e}\u{30}\u{31}") == 0.01 and tonumber("\u{2d}\u{31}\u{2e}") == - 1 and tonumber("\u{2b}\u{31}\u{2e}") == 1)
334+assert(tonumber("\u{2b}\u{30}\u{2e}\u{30}\u{31}") == 0x1 / 0x64 and tonumber("\u{2b}\u{2e}\u{30}\u{31}") == 0.01 and tonumber("\u{2e}\u{30}\u{31}") == 0.01 and tonumber("\u{2d}\u{31}\u{2e}") == - 0x1 and tonumber("\u{2b}\u{31}\u{2e}") == 0x1)
335assert(not tonumber("\u{2b}\u{20}\u{30}\u{2e}\u{30}\u{31}") and not tonumber("\u{2b}\u{2e}\u{65}\u{31}") and not tonumber("\u{31}\u{65}") and not tonumber("\u{31}\u{2e}\u{30}\u{65}\u{2b}") and not tonumber("\u{2e}"))
335assert(not tonumber("\u{2b}\u{20}\u{30}\u{2e}\u{30}\u{31}") and not tonumber("\u{2b}\u{2e}\u{65}\u{31}") and not tonumber("\u{31}\u{65}") and not tonumber("\u{31}\u{2e}\u{30}\u{65}\u{2b}") and not tonumber("\u{2e}"))
336−assert(tonumber("\u{2d}\u{30}\u{31}\u{32}") == - 10 - 2)
336+assert(tonumber("\u{2d}\u{30}\u{31}\u{32}") == - 0xa - 0x2)
337−assert(tonumber("\u{2d}\u{31}\u{2e}\u{32}\u{65}\u{32}") == - - - 120)
337+assert(tonumber("\u{2d}\u{31}\u{2e}\u{32}\u{65}\u{32}") == - - - 0x78)
338−assert(tonumber("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}") == (1 << (4 * 12)) - 1)
338+assert(tonumber("\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}") == (0x1 << (0x4 * 0xc)) - 0x1)
339−assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",(intbits // 4))) == - 1)
339+assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",(intbits // 0x4))) == - 0x1)
340−assert(tonumber("\u{2d}\u{30}\u{78}" .. string.rep("\u{66}",(intbits // 4))) == 1)
340+assert(tonumber("\u{2d}\u{30}\u{78}" .. string.rep("\u{66}",(intbits // 0x4))) == 0x1)
341−assert(tonumber("\u{20}\u{20}\u{30}\u{30}\u{31}\u{30}\u{31}\u{30}\u{20}\u{20}",2) == 10)
341+assert(tonumber("\u{20}\u{20}\u{30}\u{30}\u{31}\u{30}\u{31}\u{30}\u{20}\u{20}",0x2) == 0xa)
342−assert(tonumber("\u{20}\u{20}\u{30}\u{30}\u{31}\u{30}\u{31}\u{30}\u{20}\u{20}",10) == 1010)
342+assert(tonumber("\u{20}\u{20}\u{30}\u{30}\u{31}\u{30}\u{31}\u{30}\u{20}\u{20}",0xa) == 0x3f2)
343−assert(tonumber("\u{20}\u{20}\u{2d}\u{31}\u{30}\u{31}\u{30}\u{20}\u{20}",2) == - 10)
343+assert(tonumber("\u{20}\u{20}\u{2d}\u{31}\u{30}\u{31}\u{30}\u{20}\u{20}",0x2) == - 0xa)
344−assert(tonumber("\u{31}\u{30}",36) == 36)
344+assert(tonumber("\u{31}\u{30}",0x24) == 0x24)
345−assert(tonumber("\u{20}\u{20}\u{2d}\u{31}\u{30}\u{20}\u{20}",36) == - 36)
345+assert(tonumber("\u{20}\u{20}\u{2d}\u{31}\u{30}\u{20}\u{20}",0x24) == - 0x24)
346−assert(tonumber("\u{20}\u{20}\u{2b}\u{31}\u{5a}\u{20}\u{20}",36) == 36 + 35)
346+assert(tonumber("\u{20}\u{20}\u{2b}\u{31}\u{5a}\u{20}\u{20}",0x24) == 0x24 + 0x23)
347−assert(tonumber("\u{20}\u{20}\u{2d}\u{31}\u{7a}\u{20}\u{20}",36) == - 36 + - 35)
347+assert(tonumber("\u{20}\u{20}\u{2d}\u{31}\u{7a}\u{20}\u{20}",0x24) == - 0x24 + - 0x23)
348−assert(tonumber("\u{2d}\u{66}\u{46}\u{66}\u{61}",16) == - (10 + (16 * (15 + (16 * (15 + (16 * 15)))))))
348+assert(tonumber("\u{2d}\u{66}\u{46}\u{66}\u{61}",0x10) == - (0xa + (0x10 * (0xf + (0x10 * (0xf + (0x10 * 0xf)))))))
349−assert(tonumber(string.rep("\u{31}",(intbits - 2)),2) + 1 == 2 ^ (intbits - 2))
349+assert(tonumber(string.rep("\u{31}",(intbits - 0x2)),0x2) + 0x1 == 0x2 ^ (intbits - 0x2))
350−assert(tonumber("\u{66}\u{66}\u{66}\u{66}\u{46}\u{46}\u{46}\u{46}",16) + 1 == (1 << 32))
350+assert(tonumber("\u{66}\u{66}\u{66}\u{66}\u{46}\u{46}\u{46}\u{46}",0x10) + 0x1 == (0x1 << 0x20))
351−assert(tonumber("\u{30}\u{66}\u{66}\u{66}\u{66}\u{46}\u{46}\u{46}\u{46}",16) + 1 == (1 << 32))
351+assert(tonumber("\u{30}\u{66}\u{66}\u{66}\u{66}\u{46}\u{46}\u{46}\u{46}",0x10) + 0x1 == (0x1 << 0x20))
352−assert(tonumber("\u{2d}\u{30}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{46}\u{46}\u{46}\u{46}",16) - 1 == - (1 << 40))
352+assert(tonumber("\u{2d}\u{30}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{46}\u{46}\u{46}\u{46}",0x10) - 0x1 == - (0x1 << 0x28))
353−for i = 2, 36
353+for i = 0x2, 0x24
354do
354do
355local i2 = i * i
355local i2 = i * i
356local i10 = i2 * i2 * i2 * i2 * i2
356local i10 = i2 * i2 * i2 * i2 * i2
357assert(tonumber("\u{9}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{9}",i) == i10)
357assert(tonumber("\u{9}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{9}",i) == i10)
358end
358end
359if not _soft then
359if not _soft then
360−assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",13) .. "\u{2e}\u{30}") == 2.0 ^ (4 * 13) - 1)
360+assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",0xd) .. "\u{2e}\u{30}") == 2.0 ^ (0x4 * 0xd) - 0x1)
361−assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",150) .. "\u{2e}\u{30}") == 2.0 ^ (4 * 150) - 1)
361+assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",0x96) .. "\u{2e}\u{30}") == 2.0 ^ (0x4 * 0x96) - 0x1)
362−assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",300) .. "\u{2e}\u{30}") == 2.0 ^ (4 * 300) - 1)
362+assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",0x12c) .. "\u{2e}\u{30}") == 2.0 ^ (0x4 * 0x12c) - 0x1)
363−assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",500) .. "\u{2e}\u{30}") == 2.0 ^ (4 * 500) - 1)
363+assert(tonumber("\u{30}\u{78}" .. string.rep("\u{66}",0x1f4) .. "\u{2e}\u{30}") == 2.0 ^ (0x4 * 0x1f4) - 0x1)
364−assert(tonumber("\u{30}\u{78}\u{33}\u{2e}" .. string.rep("\u{30}",1000)) == 3)
364+assert(tonumber("\u{30}\u{78}\u{33}\u{2e}" .. string.rep("\u{30}",0x3e8)) == 0x3)
365−assert(tonumber("\u{30}\u{78}" .. string.rep("\u{30}",1000) .. "\u{61}") == 10)
365+assert(tonumber("\u{30}\u{78}" .. string.rep("\u{30}",0x3e8) .. "\u{61}") == 0xa)
366−assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",13) .. "\u{31}") == 2.0 ^ (- 4 * 14))
366+assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",0xd) .. "\u{31}") == 2.0 ^ (- 0x4 * 0xe))
367−assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",150) .. "\u{31}") == 2.0 ^ (- 4 * 151))
367+assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",0x96) .. "\u{31}") == 2.0 ^ (- 0x4 * 0x97))
368−assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",300) .. "\u{31}") == 2.0 ^ (- 4 * 301))
368+assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",0x12c) .. "\u{31}") == 2.0 ^ (- 0x4 * 0x12d))
369−assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",500) .. "\u{31}") == 2.0 ^ (- 4 * 501))
369+assert(tonumber("\u{30}\u{78}\u{30}\u{2e}" .. string.rep("\u{30}",0x1f4) .. "\u{31}") == 2.0 ^ (- 0x4 * 0x1f5))
370−assert(tonumber("\u{30}\u{78}\u{65}\u{30}\u{33}" .. string.rep("\u{30}",1000) .. "\u{70}\u{2d}\u{34}\u{30}\u{30}\u{30}") == 3587.0)
370+assert(tonumber("\u{30}\u{78}\u{65}\u{30}\u{33}" .. string.rep("\u{30}",0x3e8) .. "\u{70}\u{2d}\u{34}\u{30}\u{30}\u{30}") == 3587.0)
371−assert(tonumber("\u{30}\u{78}\u{2e}" .. string.rep("\u{30}",1000) .. "\u{37}\u{34}\u{70}\u{34}\u{30}\u{30}\u{34}") == 7.25)
371+assert(tonumber("\u{30}\u{78}\u{2e}" .. string.rep("\u{30}",0x3e8) .. "\u{37}\u{34}\u{70}\u{34}\u{30}\u{30}\u{34}") == 7.25)
372end
372end
373local function f
373local function f
374(...)
374(...)
375−if select("\u{23}",...) == 1 then
375+if select("\u{23}",...) == 0x1 then
376return (...)
376return (...)
377else
377else
378return "\u{2a}\u{2a}\u{2a}"
378return "\u{2a}\u{2a}\u{2a}"
379end
379end
380end
380end
381−assert(not f(tonumber("\u{66}\u{46}\u{66}\u{61}",15)))
381+assert(not f(tonumber("\u{66}\u{46}\u{66}\u{61}",0xf)))
382−assert(not f(tonumber("\u{30}\u{39}\u{39}",8)))
382+assert(not f(tonumber("\u{30}\u{39}\u{39}",0x8)))
383−assert(not f(tonumber("\u{31}\u{0}",2)))
383+assert(not f(tonumber("\u{31}\u{0}",0x2)))
384−assert(not f(tonumber("",8)))
384+assert(not f(tonumber("",0x8)))
385−assert(not f(tonumber("\u{20}\u{20}",9)))
385+assert(not f(tonumber("\u{20}\u{20}",0x9)))
386−assert(not f(tonumber("\u{20}\u{20}",9)))
386+assert(not f(tonumber("\u{20}\u{20}",0x9)))
387−assert(not f(tonumber("\u{30}\u{78}\u{66}",10)))
387+assert(not f(tonumber("\u{30}\u{78}\u{66}",0xa)))
388assert(not f(tonumber("\u{69}\u{6e}\u{66}")))
388assert(not f(tonumber("\u{69}\u{6e}\u{66}")))
389assert(not f(tonumber("\u{20}\u{49}\u{4e}\u{46}\u{20}")))
389assert(not f(tonumber("\u{20}\u{49}\u{4e}\u{46}\u{20}")))
390assert(not f(tonumber("\u{4e}\u{61}\u{6e}")))
390assert(not f(tonumber("\u{4e}\u{61}\u{6e}")))
@@ -392,7 +392,7 @@ assert(not f(tonumber("\u{6e}\u{61}\u{6e}")))
392assert(not f(tonumber("\u{20}\u{20}")))
392assert(not f(tonumber("\u{20}\u{20}")))
393assert(not f(tonumber("")))
393assert(not f(tonumber("")))
394assert(not f(tonumber("\u{31}\u{20}\u{20}\u{61}")))
394assert(not f(tonumber("\u{31}\u{20}\u{20}\u{61}")))
395−assert(not f(tonumber("\u{31}\u{20}\u{20}\u{61}",2)))
395+assert(not f(tonumber("\u{31}\u{20}\u{20}\u{61}",0x2)))
396assert(not f(tonumber("\u{31}\u{0}")))
396assert(not f(tonumber("\u{31}\u{0}")))
397assert(not f(tonumber("\u{31}\u{20}\u{0}")))
397assert(not f(tonumber("\u{31}\u{20}\u{0}")))
398assert(not f(tonumber("\u{31}\u{0}\u{20}")))
398assert(not f(tonumber("\u{31}\u{0}\u{20}")))
@@ -411,164 +411,164 @@ assert(not tonumber("\u{2d}\u{20}\u{30}\u{78}\u{61}\u{61}"))
411assert(not tonumber("\u{2d}\u{30}\u{78}\u{61}\u{61}\u{50}\u{20}"))
411assert(not tonumber("\u{2d}\u{30}\u{78}\u{61}\u{61}\u{50}\u{20}"))
412assert(not tonumber("\u{30}\u{78}\u{30}\u{2e}\u{35}\u{31}\u{70}"))
412assert(not tonumber("\u{30}\u{78}\u{30}\u{2e}\u{35}\u{31}\u{70}"))
413assert(not tonumber("\u{30}\u{78}\u{35}\u{70}\u{2b}\u{2d}\u{32}"))
413assert(not tonumber("\u{30}\u{78}\u{35}\u{70}\u{2b}\u{2d}\u{32}"))
414−assert(16 == 16 and 4095 == 2 ^ 12 - 1 and 251 == 251)
414+assert(0x10 == 0x10 and 0xfff == 0x2 ^ 0xc - 0x1 and 0xfb == 0xfb)
415−assert(0.0 == 0 and 0.0 == 0)
415+assert(0.0 == 0x0 and 0.0 == 0x0)
416−assert(4294967295 == (1 << 32) - 1)
416+assert(0xffffffff == (0x1 << 0x20) - 0x1)
417−assert(tonumber("\u{2b}\u{30}\u{78}\u{32}") == 2)
417+assert(tonumber("\u{2b}\u{30}\u{78}\u{32}") == 0x2)
418−assert(tonumber("\u{2d}\u{30}\u{78}\u{61}\u{41}") == - 170)
418+assert(tonumber("\u{2d}\u{30}\u{78}\u{61}\u{41}") == - 0xaa)
419−assert(tonumber("\u{2d}\u{30}\u{78}\u{66}\u{66}\u{46}\u{46}\u{46}\u{66}\u{66}\u{66}") == - (1 << 32) + 1)
419+assert(tonumber("\u{2d}\u{30}\u{78}\u{66}\u{66}\u{46}\u{46}\u{46}\u{66}\u{66}\u{66}") == - (0x1 << 0x20) + 0x1)
420−assert(0.0 == 0 and 14 + 1 == 15 and 14 - 1 == 13)
420+assert(0.0 == 0x0 and 0xe + 0x1 == 0xf and 0xe - 0x1 == 0xd)
421−assert(tonumber("\u{20}\u{20}\u{30}\u{78}\u{32}\u{2e}\u{35}\u{20}\u{20}") == 37 / 16)
421+assert(tonumber("\u{20}\u{20}\u{30}\u{78}\u{32}\u{2e}\u{35}\u{20}\u{20}") == 0x25 / 0x10)
422−assert(tonumber("\u{20}\u{20}\u{2d}\u{30}\u{78}\u{32}\u{2e}\u{35}\u{20}\u{20}") == - 37 / 16)
422+assert(tonumber("\u{20}\u{20}\u{2d}\u{30}\u{78}\u{32}\u{2e}\u{35}\u{20}\u{20}") == - 0x25 / 0x10)
423−assert(tonumber("\u{20}\u{20}\u{2b}\u{30}\u{78}\u{30}\u{2e}\u{35}\u{31}\u{70}\u{2b}\u{38}\u{20}\u{20}") == 81)
423+assert(tonumber("\u{20}\u{20}\u{2b}\u{30}\u{78}\u{30}\u{2e}\u{35}\u{31}\u{70}\u{2b}\u{38}\u{20}\u{20}") == 0x51)
424−assert(0.9999999997671694 == 1 - "\u{30}\u{78}\u{2e}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}")
424+assert(0.9999999997671694 == 0x1 - "\u{30}\u{78}\u{2e}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}")
425−assert("\u{30}\u{78}\u{41}\u{2e}\u{61}" + 0 == 10 + 10 / 16)
425+assert("\u{30}\u{78}\u{41}\u{2e}\u{61}" + 0x0 == 0xa + 0xa / 0x10)
426−assert(170.0 == 170)
426+assert(170.0 == 0xaa)
427−assert(1.0 == 1)
427+assert(1.0 == 0x1)
428assert(1.0625 == "\u{30}\u{78}\u{31}\u{2e}" + "\u{2b}\u{30}\u{78}\u{2e}\u{31}")
428assert(1.0625 == "\u{30}\u{78}\u{31}\u{2e}" + "\u{2b}\u{30}\u{78}\u{2e}\u{31}")
429assert(11259375.0 == 11259375.0)
429assert(11259375.0 == 11259375.0)
430assert(1.1 == 1.0 + 0.1)
430assert(1.1 == 1.0 + 0.1)
431assert(100.0 == 100.0 and 0.01 == 0.01)
431assert(100.0 == 100.0 and 0.01 == 0.01)
432−assert(1111111111 - 1111111110 == 1.0)
432+assert(0x423a35c7 - 0x423a35c6 == 1.0)
433assert(1.1 == "\u{31}\u{2e}" + "\u{2e}\u{31}")
433assert(1.1 == "\u{31}\u{2e}" + "\u{2e}\u{31}")
434assert(tonumber("\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}") - tonumber("\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{30}") == tonumber("\u{20}\u{20}\u{2b}\u{30}\u{2e}\u{30}\u{30}\u{31}\u{65}\u{2b}\u{33}\u{20}\u{a}\u{9}"))
434assert(tonumber("\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}") - tonumber("\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{31}\u{30}") == tonumber("\u{20}\u{20}\u{2b}\u{30}\u{2e}\u{30}\u{30}\u{31}\u{65}\u{2b}\u{33}\u{20}\u{a}\u{9}"))
435assert(1e-31 > 9e-32 and 9e29 < 1e30)
435assert(1e-31 > 9e-32 and 9e29 < 1e30)
436assert(0.123456 > 0.123455)
436assert(0.123456 > 0.123455)
437−assert(tonumber("\u{2b}\u{31}\u{2e}\u{32}\u{33}\u{45}\u{31}\u{38}") == 1.23 * 10.0 ^ 18)
437+assert(tonumber("\u{2b}\u{31}\u{2e}\u{32}\u{33}\u{45}\u{31}\u{38}") == 1.23 * 10.0 ^ 0x12)
438−assert(not (1 < 1) and (1 < 2) and not (2 < 1))
438+assert(not (0x1 < 0x1) and (0x1 < 0x2) and not (0x2 < 0x1))
439assert(not ("\u{61}" < "\u{61}") and ("\u{61}" < "\u{62}") and not ("\u{62}" < "\u{61}"))
439assert(not ("\u{61}" < "\u{61}") and ("\u{61}" < "\u{62}") and not ("\u{62}" < "\u{61}"))
440−assert((1 <= 1) and (1 <= 2) and not (2 <= 1))
440+assert((0x1 <= 0x1) and (0x1 <= 0x2) and not (0x2 <= 0x1))
441assert(("\u{61}" <= "\u{61}") and ("\u{61}" <= "\u{62}") and not ("\u{62}" <= "\u{61}"))
441assert(("\u{61}" <= "\u{61}") and ("\u{61}" <= "\u{62}") and not ("\u{62}" <= "\u{61}"))
442−assert(not (1 > 1) and not (1 > 2) and (2 > 1))
442+assert(not (0x1 > 0x1) and not (0x1 > 0x2) and (0x2 > 0x1))
443assert(not ("\u{61}" > "\u{61}") and not ("\u{61}" > "\u{62}") and ("\u{62}" > "\u{61}"))
443assert(not ("\u{61}" > "\u{61}") and not ("\u{61}" > "\u{62}") and ("\u{62}" > "\u{61}"))
444−assert((1 >= 1) and not (1 >= 2) and (2 >= 1))
444+assert((0x1 >= 0x1) and not (0x1 >= 0x2) and (0x2 >= 0x1))
445assert(("\u{61}" >= "\u{61}") and not ("\u{61}" >= "\u{62}") and ("\u{62}" >= "\u{61}"))
445assert(("\u{61}" >= "\u{61}") and not ("\u{61}" >= "\u{62}") and ("\u{62}" >= "\u{61}"))
446assert(1.3 < 1.4 and 1.3 <= 1.4 and not (1.3 < 1.3) and 1.3 <= 1.3)
446assert(1.3 < 1.4 and 1.3 <= 1.4 and not (1.3 < 1.3) and 1.3 <= 1.3)
447−assert(eqT(- 4 % 3,2))
447+assert(eqT(- 0x4 % 0x3,0x2))
448−assert(eqT(4 % - 3,- 2))
448+assert(eqT(0x4 % - 0x3,- 0x2))
449−assert(eqT(- 4.0 % 3,2.0))
449+assert(eqT(- 4.0 % 0x3,2.0))
450−assert(eqT(4 % - 3.0,- 2.0))
450+assert(eqT(0x4 % - 3.0,- 2.0))
451−assert(eqT(4 % - 5,- 1))
451+assert(eqT(0x4 % - 0x5,- 0x1))
452−assert(eqT(4 % - 5.0,- 1.0))
452+assert(eqT(0x4 % - 5.0,- 1.0))
453−assert(eqT(4 % 5,4))
453+assert(eqT(0x4 % 0x5,0x4))
454−assert(eqT(4 % 5.0,4.0))
454+assert(eqT(0x4 % 5.0,4.0))
455−assert(eqT(- 4 % - 5,- 4))
455+assert(eqT(- 0x4 % - 0x5,- 0x4))
456−assert(eqT(- 4 % - 5.0,- 4.0))
456+assert(eqT(- 0x4 % - 5.0,- 4.0))
457−assert(eqT(- 4 % 5,1))
457+assert(eqT(- 0x4 % 0x5,0x1))
458−assert(eqT(- 4 % 5.0,1.0))
458+assert(eqT(- 0x4 % 5.0,1.0))
459−assert(eqT(4.25 % 4,0.25))
459+assert(eqT(4.25 % 0x4,0.25))
460−assert(eqT(10.0 % 2,0.0))
460+assert(eqT(10.0 % 0x2,0.0))
461−assert(eqT(- 10.0 % 2,0.0))
461+assert(eqT(- 10.0 % 0x2,0.0))
462−assert(eqT(- 10.0 % - 2,0.0))
462+assert(eqT(- 10.0 % - 0x2,0.0))
463−assert(math.pi - math.pi % 1 == 3)
463+assert(math.pi - math.pi % 0x1 == 0x3)
464assert(math.pi - math.pi % 1e-3 == 3.141)
464assert(math.pi - math.pi % 1e-3 == 3.141)
465do
465do
466−local i,j = 0,20000
466+local i,j = 0x0,0x4e20
467while i < j do
467while i < j do
468−local m = (i + j) // 2
468+local m = (i + j) // 0x2
469−if 10 ^ - m > 0 then
469+if 0xa ^ - m > 0x0 then
470−i=m + 1
470+i=m + 0x1
471else
471else
472j=m
472j=m
473end
473end
474end
474end
475−local b = 10 ^ - (i - (i // 10))
475+local b = 0xa ^ - (i - (i // 0xa))
476−assert(b > 0 and b * b == 0)
476+assert(b > 0x0 and b * b == 0x0)
477−local delta = b / 1000
477+local delta = b / 0x3e8
478−assert(eq((2.1 * b) % (2 * b),(0.1 * b),delta))
478+assert(eq((2.1 * b) % (0x2 * b),(0.1 * b),delta))
479−assert(eq((- 2.1 * b) % (2 * b),(2 * b) - (0.1 * b),delta))
479+assert(eq((- 2.1 * b) % (0x2 * b),(0x2 * b) - (0.1 * b),delta))
480−assert(eq((2.1 * b) % (- 2 * b),(0.1 * b) - (2 * b),delta))
480+assert(eq((2.1 * b) % (- 0x2 * b),(0.1 * b) - (0x2 * b),delta))
481−assert(eq((- 2.1 * b) % (- 2 * b),(- 0.1 * b),delta))
481+assert(eq((- 2.1 * b) % (- 0x2 * b),(- 0.1 * b),delta))
482end
482end
483−for i = - 10, 10
483+for i = - 0xa, 0xa
484do
484do
485−for j = - 10, 10
485+for j = - 0xa, 0xa
486do
486do
487−if j ~= 0 then
487+if j ~= 0x0 then
488assert((i + 0.0) % j == i % j)
488assert((i + 0.0) % j == i % j)
489end
489end
490end
490end
491end
491end
492−for i = 0, 10
492+for i = 0x0, 0xa
493do
493do
494−for j = - 10, 10
494+for j = - 0xa, 0xa
495do
495do
496−if j ~= 0 then
496+if j ~= 0x0 then
497−assert((2 ^ i) % j == (1 << i) % j)
497+assert((0x2 ^ i) % j == (0x1 << i) % j)
498end
498end
499end
499end
500end
500end
501do
501do
502−local i = 10
502+local i = 0xa
503−while (1 << i) > 0 do
503+while (0x1 << i) > 0x0 do
504−assert((1 << i) % 3 == i % 2 + 1)
504+assert((0x1 << i) % 0x3 == i % 0x2 + 0x1)
505−i=i + 1
505+i=i + 0x1
506end
506end
507−i=10
507+i=0xa
508−while 2 ^ i < math.huge do
508+while 0x2 ^ i < math.huge do
509−assert(2 ^ i % 3 == i % 2 + 1)
509+assert(0x2 ^ i % 0x3 == i % 0x2 + 0x1)
510−i=i + 1
510+i=i + 0x1
511end
511end
512end
512end
513−assert(eqT(minint % minint,0))
513+assert(eqT(minint % minint,0x0))
514−assert(eqT(maxint % maxint,0))
514+assert(eqT(maxint % maxint,0x0))
515−assert((minint + 1) % minint == minint + 1)
515+assert((minint + 0x1) % minint == minint + 0x1)
516−assert((maxint - 1) % maxint == maxint - 1)
516+assert((maxint - 0x1) % maxint == maxint - 0x1)
517−assert(minint % maxint == maxint - 1)
517+assert(minint % maxint == maxint - 0x1)
518−assert(minint % - 1 == 0)
518+assert(minint % - 0x1 == 0x0)
519−assert(minint % - 2 == 0)
519+assert(minint % - 0x2 == 0x0)
520−assert(maxint % - 2 == - 1)
520+assert(maxint % - 0x2 == - 0x1)
521if not _port then
521if not _port then
522local function anan
522local function anan
523(x)
523(x)
524assert(isNaN(x))
524assert(isNaN(x))
525end
525end
526−anan(0.0 % 0)
526+anan(0.0 % 0x0)
527−anan(1.3 % 0)
527+anan(1.3 % 0x0)
528−anan(math.huge % 1)
528+anan(math.huge % 0x1)
529anan(math.huge % 1e30)
529anan(math.huge % 1e30)
530anan(- math.huge % 1e30)
530anan(- math.huge % 1e30)
531anan(- math.huge % - 1e30)
531anan(- math.huge % - 1e30)
532−assert(1 % math.huge == 1)
532+assert(0x1 % math.huge == 0x1)
533assert(1e30 % math.huge == 1e30)
533assert(1e30 % math.huge == 1e30)
534assert(1e30 % - math.huge == - math.huge)
534assert(1e30 % - math.huge == - math.huge)
535−assert(- 1 % math.huge == math.huge)
535+assert(- 0x1 % math.huge == math.huge)
536−assert(- 1 % - math.huge == - 1)
536+assert(- 0x1 % - math.huge == - 0x1)
537−end
537+end
538−assert(math.ult(3,4))
538+assert(math.ult(0x3,0x4))
539−assert(not math.ult(4,4))
539+assert(not math.ult(0x4,0x4))
540−assert(math.ult(- 2,- 1))
540+assert(math.ult(- 0x2,- 0x1))
541−assert(math.ult(2,- 1))
541+assert(math.ult(0x2,- 0x1))
542−assert(not math.ult(- 2,- 2))
542+assert(not math.ult(- 0x2,- 0x2))
543assert(math.ult(maxint,minint))
543assert(math.ult(maxint,minint))
544assert(not math.ult(minint,maxint))
544assert(not math.ult(minint,maxint))
545−assert(eq(math.sin(- 9.8) ^ 2 + math.cos(- 9.8) ^ 2,1))
545+assert(eq(math.sin(- 9.8) ^ 0x2 + math.cos(- 9.8) ^ 0x2,0x1))
546−assert(eq(math.tan(math.pi / 4),1))
546+assert(eq(math.tan(math.pi / 0x4),0x1))
547−assert(eq(math.sin(math.pi / 2),1) and eq(math.cos(math.pi / 2),0))
547+assert(eq(math.sin(math.pi / 0x2),0x1) and eq(math.cos(math.pi / 0x2),0x0))
548−assert(eq(math.atan(1),math.pi / 4) and eq(math.acos(0),math.pi / 2) and eq(math.asin(1),math.pi / 2))
548+assert(eq(math.atan(0x1),math.pi / 0x4) and eq(math.acos(0x0),math.pi / 0x2) and eq(math.asin(0x1),math.pi / 0x2))
549−assert(eq(math.deg(math.pi / 2),90) and eq(math.rad(90),math.pi / 2))
549+assert(eq(math.deg(math.pi / 0x2),0x5a) and eq(math.rad(0x5a),math.pi / 0x2))
550assert(math.abs(- 10.43) == 10.43)
550assert(math.abs(- 10.43) == 10.43)
551assert(eqT(math.abs(minint),minint))
551assert(eqT(math.abs(minint),minint))
552assert(eqT(math.abs(maxint),maxint))
552assert(eqT(math.abs(maxint),maxint))
553assert(eqT(math.abs(- maxint),maxint))
553assert(eqT(math.abs(- maxint),maxint))
554−assert(eq(math.atan(1,0),math.pi / 2))
554+assert(eq(math.atan(0x1,0x0),math.pi / 0x2))
555−assert(math.fmod(10,3) == 1)
555+assert(math.fmod(0xa,0x3) == 0x1)
556−assert(eq(math.sqrt(10) ^ 2,10))
556+assert(eq(math.sqrt(0xa) ^ 0x2,0xa))
557−assert(eq(math.log(2,10),math.log(2) / math.log(10)))
557+assert(eq(math.log(0x2,0xa),math.log(0x2) / math.log(0xa)))
558−assert(eq(math.log(2,2),1))
558+assert(eq(math.log(0x2,0x2),0x1))
559−assert(eq(math.log(9,3),2))
559+assert(eq(math.log(0x9,0x3),0x2))
560−assert(eq(math.exp(0),1))
560+assert(eq(math.exp(0x0),0x1))
561−assert(eq(math.sin(10),math.sin(10 % (2 * math.pi))))
561+assert(eq(math.sin(0xa),math.sin(0xa % (0x2 * math.pi))))
562assert(tonumber("\u{20}\u{31}\u{2e}\u{33}\u{65}\u{2d}\u{32}\u{20}") == 0.013)
562assert(tonumber("\u{20}\u{31}\u{2e}\u{33}\u{65}\u{2d}\u{32}\u{20}") == 0.013)
563assert(tonumber("\u{20}\u{2d}\u{31}\u{2e}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}\u{20}") == - 1.00000000000001)
563assert(tonumber("\u{20}\u{2d}\u{31}\u{2e}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}\u{20}") == - 1.00000000000001)
564−assert(8388609 + - 8388609 == 0)
564+assert(0x800001 + - 0x800001 == 0x0)
565−assert(8388608 + - 8388608 == 0)
565+assert(0x800000 + - 0x800000 == 0x0)
566−assert(8388607 + - 8388607 == 0)
566+assert(0x7fffff + - 0x7fffff == 0x0)
567−do
567+do
568−assert(eqT(math.floor(3.4),3))
568+assert(eqT(math.floor(3.4),0x3))
569−assert(eqT(math.ceil(3.4),4))
569+assert(eqT(math.ceil(3.4),0x4))
570−assert(eqT(math.floor(- 3.4),- 4))
570+assert(eqT(math.floor(- 3.4),- 0x4))
571−assert(eqT(math.ceil(- 3.4),- 3))
571+assert(eqT(math.ceil(- 3.4),- 0x3))
572assert(eqT(math.floor(maxint),maxint))
572assert(eqT(math.floor(maxint),maxint))
573assert(eqT(math.ceil(maxint),maxint))
573assert(eqT(math.ceil(maxint),maxint))
574assert(eqT(math.floor(minint),minint))
574assert(eqT(math.floor(minint),minint))
@@ -579,12 +579,12 @@ assert(math.floor(1e50) == 1e50)
579assert(math.ceil(1e50) == 1e50)
579assert(math.ceil(1e50) == 1e50)
580assert(math.floor(- 1e50) == - 1e50)
580assert(math.floor(- 1e50) == - 1e50)
581assert(math.ceil(- 1e50) == - 1e50)
581assert(math.ceil(- 1e50) == - 1e50)
582−for _,p in pairs({31,32,63,64})
582+for _,p in pairs({0x1f,0x20,0x3f,0x40})
583do
583do
584−assert(math.floor(2 ^ p) == 2 ^ p)
584+assert(math.floor(0x2 ^ p) == 0x2 ^ p)
585−assert(math.floor(2 ^ p + 0.5) == 2 ^ p)
585+assert(math.floor(0x2 ^ p + 0.5) == 0x2 ^ p)
586−assert(math.ceil(2 ^ p) == 2 ^ p)
586+assert(math.ceil(0x2 ^ p) == 0x2 ^ p)
587−assert(math.ceil(2 ^ p - 0.5) == 2 ^ p)
587+assert(math.ceil(0x2 ^ p - 0.5) == 0x2 ^ p)
588end
588end
589checkerror("\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.floor,{})
589checkerror("\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.floor,{})
590checkerror("\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.ceil,print)
590checkerror("\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.ceil,print)
@@ -602,80 +602,80 @@ assert(not math.tointeger(math.huge))
602assert(math.floor(- math.huge) == - math.huge)
602assert(math.floor(- math.huge) == - math.huge)
603assert(math.ceil(- math.huge) == - math.huge)
603assert(math.ceil(- math.huge) == - math.huge)
604assert(not math.tointeger(- math.huge))
604assert(not math.tointeger(- math.huge))
605−assert(math.tointeger("\u{33}\u{34}\u{2e}\u{30}") == 34)
605+assert(math.tointeger("\u{33}\u{34}\u{2e}\u{30}") == 0x22)
606assert(not math.tointeger("\u{33}\u{34}\u{2e}\u{33}"))
606assert(not math.tointeger("\u{33}\u{34}\u{2e}\u{33}"))
607assert(not math.tointeger({}))
607assert(not math.tointeger({}))
608−assert(not math.tointeger(0 / 0))
608+assert(not math.tointeger(0x0 / 0x0))
609end
609end
610−for i = - 6, 6
610+for i = - 0x6, 0x6
611do
611do
612−for j = - 6, 6
612+for j = - 0x6, 0x6
613do
613do
614−if j ~= 0 then
614+if j ~= 0x0 then
615local mi = math.fmod(i,j)
615local mi = math.fmod(i,j)
616local mf = math.fmod(i + 0.0,j)
616local mf = math.fmod(i + 0.0,j)
617assert(mi == mf)
617assert(mi == mf)
618assert(math.type(mi) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}" and math.type(mf) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
618assert(math.type(mi) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}" and math.type(mf) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
619−if (i >= 0 and j >= 0) or (i <= 0 and j <= 0) or mi == 0 then
619+if (i >= 0x0 and j >= 0x0) or (i <= 0x0 and j <= 0x0) or mi == 0x0 then
620assert(eqT(mi,i % j))
620assert(eqT(mi,i % j))
621end
621end
622end
622end
623end
623end
624end
624end
625−assert(eqT(math.fmod(minint,minint),0))
625+assert(eqT(math.fmod(minint,minint),0x0))
626−assert(eqT(math.fmod(maxint,maxint),0))
626+assert(eqT(math.fmod(maxint,maxint),0x0))
627−assert(eqT(math.fmod(minint + 1,minint),minint + 1))
627+assert(eqT(math.fmod(minint + 0x1,minint),minint + 0x1))
628−assert(eqT(math.fmod(maxint - 1,maxint),maxint - 1))
628+assert(eqT(math.fmod(maxint - 0x1,maxint),maxint - 0x1))
629−checkerror("\u{7a}\u{65}\u{72}\u{6f}",math.fmod,3,0)
629+checkerror("\u{7a}\u{65}\u{72}\u{6f}",math.fmod,0x3,0x0)
630do
630do
631checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.max)
631checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.max)
632checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.min)
632checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",math.min)
633−assert(eqT(math.max(3),3))
633+assert(eqT(math.max(0x3),0x3))
634−assert(eqT(math.max(3,5,9,1),9))
634+assert(eqT(math.max(0x3,0x5,0x9,0x1),0x9))
635assert(math.max(maxint,1e61) == 1e61)
635assert(math.max(maxint,1e61) == 1e61)
636−assert(eqT(math.max(minint,minint + 1),minint + 1))
636+assert(eqT(math.max(minint,minint + 0x1),minint + 0x1))
637−assert(eqT(math.min(3),3))
637+assert(eqT(math.min(0x3),0x3))
638−assert(eqT(math.min(3,5,9,1),1))
638+assert(eqT(math.min(0x3,0x5,0x9,0x1),0x1))
639assert(math.min(3.2,5.9,- 9.2,1.1) == - 9.2)
639assert(math.min(3.2,5.9,- 9.2,1.1) == - 9.2)
640assert(math.min(1.9,1.7,1.72) == 1.7)
640assert(math.min(1.9,1.7,1.72) == 1.7)
641assert(math.min(- 1e61,minint) == - 1e61)
641assert(math.min(- 1e61,minint) == - 1e61)
642−assert(eqT(math.min(maxint,maxint - 1),maxint - 1))
642+assert(eqT(math.min(maxint,maxint - 0x1),maxint - 0x1))
643−assert(eqT(math.min(maxint - 2,maxint,maxint - 1),maxint - 2))
643+assert(eqT(math.min(maxint - 0x2,maxint,maxint - 0x1),maxint - 0x2))
644end
644end
645local a,b = "\u{31}\u{30}","\u{32}\u{30}"
645local a,b = "\u{31}\u{30}","\u{32}\u{30}"
646−assert(a * b == 200 and a + b == 30 and a - b == - 10 and a / b == 0.5 and - b == - 20)
646+assert(a * b == 0xc8 and a + b == 0x1e and a - b == - 0xa and a / b == 0.5 and - b == - 0x14)
647assert(a == "\u{31}\u{30}" and b == "\u{32}\u{30}")
647assert(a == "\u{31}\u{30}" and b == "\u{32}\u{30}")
648do
648do
649print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{4e}\u{61}\u{4e}")
649print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{2d}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{4e}\u{61}\u{4e}")
650local mz <const> = - 0.0
650local mz <const> = - 0.0
651local z <const> = 0.0
651local z <const> = 0.0
652assert(mz == z)
652assert(mz == z)
653−assert(1 / mz < 0 and 0 < 1 / z)
653+assert(0x1 / mz < 0x0 and 0x0 < 0x1 / z)
654−local a = {[mz] = 1}
654+local a = {[mz] = 0x1}
655−assert(a[z] == 1 and a[mz] == 1)
655+assert(a[z] == 0x1 and a[mz] == 0x1)
656−a[z]=2
656+a[z]=0x2
657−assert(a[z] == 2 and a[mz] == 2)
657+assert(a[z] == 0x2 and a[mz] == 0x2)
658−local inf = math.huge * 2 + 1
658+local inf = math.huge * 0x2 + 0x1
659−local mz <const> = - 1 / inf
659+local mz <const> = - 0x1 / inf
660−local z <const> = 1 / inf
660+local z <const> = 0x1 / inf
661assert(mz == z)
661assert(mz == z)
662−assert(1 / mz < 0 and 0 < 1 / z)
662+assert(0x1 / mz < 0x0 and 0x0 < 0x1 / z)
663local NaN <const> = inf - inf
663local NaN <const> = inf - inf
664assert(NaN ~= NaN)
664assert(NaN ~= NaN)
665assert(not (NaN < NaN))
665assert(not (NaN < NaN))
666assert(not (NaN <= NaN))
666assert(not (NaN <= NaN))
667assert(not (NaN > NaN))
667assert(not (NaN > NaN))
668assert(not (NaN >= NaN))
668assert(not (NaN >= NaN))
669−assert(not (0 < NaN) and not (NaN < 0))
669+assert(not (0x0 < NaN) and not (NaN < 0x0))
670−local NaN1 <const> = 0 / 0
670+local NaN1 <const> = 0x0 / 0x0
671assert(NaN ~= NaN1 and not (NaN <= NaN1) and not (NaN1 <= NaN))
671assert(NaN ~= NaN1 and not (NaN <= NaN1) and not (NaN1 <= NaN))
672local a = {}
672local a = {}
673−assert(not pcall(rawset,a,NaN,1))
673+assert(not pcall(rawset,a,NaN,0x1))
674assert(a[NaN] == undef)
674assert(a[NaN] == undef)
675−a[1]=1
675+a[0x1]=0x1
676−assert(not pcall(rawset,a,NaN,1))
676+assert(not pcall(rawset,a,NaN,0x1))
677assert(a[NaN] == undef)
677assert(a[NaN] == undef)
678−local a1,a2,a3,a4,a5 = 0,0,"\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}",0,"\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}"
678+local a1,a2,a3,a4,a5 = 0x0,0x0,"\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}",0x0,"\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}"
679assert(a1 == a2 and a2 == a4 and a1 ~= a3)
679assert(a1 == a2 and a2 == a4 and a1 ~= a3)
680assert(a3 == a5)
680assert(a3 == a5)
681end
681end
@@ -686,62 +686,62 @@ local function testnear
686return (math.abs(val - ref) < ref * tol)
686return (math.abs(val - ref) < ref * tol)
687end
687end
688do
688do
689−local h <const> = 2054176933
689+local h <const> = 0x7a7040a5
690−local l <const> = 2737031638
690+local l <const> = 0xa323c9d6
691−math.randomseed(1007)
691+math.randomseed(0x3ef)
692−local res = (h << 32 | l) & ~ (~ 0 << intbits)
692+local res = (h << 0x20 | l) & ~ (~ 0x0 << intbits)
693−assert(random(0) == res)
693+assert(random(0x0) == res)
694−math.randomseed(1007,0)
694+math.randomseed(0x3ef,0x0)
695local res
695local res
696−if floatbits <= 32 then
696+if floatbits <= 0x20 then
697−res=(h >> (32 - floatbits)) % 2 ^ 32
697+res=(h >> (0x20 - floatbits)) % 0x2 ^ 0x20
698else
698else
699−res=(h % 2 ^ 32) * 2 ^ (floatbits - 32) + ((l >> (64 - floatbits)) % 2 ^ 32)
699+res=(h % 0x2 ^ 0x20) * 0x2 ^ (floatbits - 0x20) + ((l >> (0x40 - floatbits)) % 0x2 ^ 0x20)
700end
700end
701local rand = random()
701local rand = random()
702−assert(eq(rand,0.4782753376376966,2 ^ - floatbits))
702+assert(eq(rand,0.4782753376376966,0x2 ^ - floatbits))
703−assert(rand * 2 ^ floatbits == res)
703+assert(rand * 0x2 ^ floatbits == res)
704end
704end
705do
705do
706local x,y = math.randomseed()
706local x,y = math.randomseed()
707−local res = math.random(0)
707+local res = math.random(0x0)
708x,y=math.randomseed(x,y)
708x,y=math.randomseed(x,y)
709−assert(math.random(0) == res)
709+assert(math.random(0x0) == res)
710math.randomseed(x,y)
710math.randomseed(x,y)
711−assert(math.random(0) == res)
711+assert(math.random(0x0) == res)
712print(string.format("\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}\u{20}\u{73}\u{65}\u{65}\u{64}\u{73}\u{3a}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{25}\u{64}",x,y))
712print(string.format("\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}\u{20}\u{73}\u{65}\u{65}\u{64}\u{73}\u{3a}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{25}\u{64}",x,y))
713end
713end
714do
714do
715−local randbits = math.min(floatbits,64)
715+local randbits = math.min(floatbits,0x40)
716−local mult = 2 ^ randbits
716+local mult = 0x2 ^ randbits
717local counts = {}
717local counts = {}
718−for i = 1, randbits
718+for i = 0x1, randbits
719do
719do
720−counts[i]=0
720+counts[i]=0x0
721end
721end
722local up = - math.huge
722local up = - math.huge
723local low = math.huge
723local low = math.huge
724−local rounds = 100 * randbits
724+local rounds = 0x64 * randbits
725−local totalrounds = 0
725+local totalrounds = 0x0
726::doagain::
726::doagain::
727−for i = 0, rounds
727+for i = 0x0, rounds
728do
728do
729local t = random()
729local t = random()
730−assert(0 <= t and t < 1)
730+assert(0x0 <= t and t < 0x1)
731up=max(up,t)
731up=max(up,t)
732low=min(low,t)
732low=min(low,t)
733−assert(t * mult % 1 == 0)
733+assert(t * mult % 0x1 == 0x0)
734local bit = i % randbits
734local bit = i % randbits
735−if (t * 2 ^ bit) % 1 >= 0.5 then
735+if (t * 0x2 ^ bit) % 0x1 >= 0.5 then
736−counts[bit + 1]=counts[bit + 1] + 1
736+counts[bit + 0x1]=counts[bit + 0x1] + 0x1
737end
737end
738end
738end
739totalrounds=totalrounds + rounds
739totalrounds=totalrounds + rounds
740−if not (eq(up,1,1e-3) and eq(low,0,1e-3)) then
740+if not (eq(up,0x1,1e-3) and eq(low,0x0,1e-3)) then
741goto doagain
741goto doagain
742end
742end
743−local expected = (totalrounds / randbits / 2)
743+local expected = (totalrounds / randbits / 0x2)
744−for i = 1, randbits
744+for i = 0x1, randbits
745do
745do
746if not testnear(counts[i],expected,0.1) then
746if not testnear(counts[i],expected,0.1) then
747goto doagain
747goto doagain
@@ -750,31 +750,31 @@ end
750print(string.format("\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{20}\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{64}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}\u{3a}\u{20}\u{5b}\u{25}\u{66}\u{2c}\u{20}\u{25}\u{66}\u{5d}",totalrounds,low,up))
750print(string.format("\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{20}\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{64}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}\u{3a}\u{20}\u{5b}\u{25}\u{66}\u{2c}\u{20}\u{25}\u{66}\u{5d}",totalrounds,low,up))
751end
751end
752do
752do
753−local up = 0
753+local up = 0x0
754−local low = 0
754+local low = 0x0
755local counts = {}
755local counts = {}
756−for i = 1, intbits
756+for i = 0x1, intbits
757do
757do
758−counts[i]=0
758+counts[i]=0x0
759end
759end
760−local rounds = 100 * intbits
760+local rounds = 0x64 * intbits
761−local totalrounds = 0
761+local totalrounds = 0x0
762::doagain::
762::doagain::
763−for i = 0, rounds
763+for i = 0x0, rounds
764do
764do
765−local t = random(0)
765+local t = random(0x0)
766up=max(up,t)
766up=max(up,t)
767low=min(low,t)
767low=min(low,t)
768local bit = i % intbits
768local bit = i % intbits
769−counts[bit + 1]=counts[bit + 1] + ((t >> bit) & 1)
769+counts[bit + 0x1]=counts[bit + 0x1] + ((t >> bit) & 0x1)
770end
770end
771totalrounds=totalrounds + rounds
771totalrounds=totalrounds + rounds
772−local lim = maxint >> 10
772+local lim = maxint >> 0xa
773if not (maxint - up < lim and low - minint < lim) then
773if not (maxint - up < lim and low - minint < lim) then
774goto doagain
774goto doagain
775end
775end
776−local expected = (totalrounds / intbits / 2)
776+local expected = (totalrounds / intbits / 0x2)
777−for i = 1, intbits
777+for i = 0x1, intbits
778do
778do
779if not testnear(counts[i],expected,0.1) then
779if not testnear(counts[i],expected,0.1) then
780goto doagain
780goto doagain
@@ -783,17 +783,17 @@ end
783print(string.format("\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{64}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}\u{3a}\u{20}\u{5b}\u{6d}\u{69}\u{6e}\u{69}\u{6e}\u{74}\u{20}\u{2b}\u{20}\u{25}\u{2e}\u{30}\u{66}\u{70}\u{70}\u{6d}\u{2c}\u{20}\u{6d}\u{61}\u{78}\u{69}\u{6e}\u{74}\u{20}\u{2d}\u{20}\u{25}\u{2e}\u{30}\u{66}\u{70}\u{70}\u{6d}\u{5d}",totalrounds,(minint - low) / minint * 1e6,(maxint - up) / maxint * 1e6))
783print(string.format("\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{64}\u{20}\u{63}\u{61}\u{6c}\u{6c}\u{73}\u{3a}\u{20}\u{5b}\u{6d}\u{69}\u{6e}\u{69}\u{6e}\u{74}\u{20}\u{2b}\u{20}\u{25}\u{2e}\u{30}\u{66}\u{70}\u{70}\u{6d}\u{2c}\u{20}\u{6d}\u{61}\u{78}\u{69}\u{6e}\u{74}\u{20}\u{2d}\u{20}\u{25}\u{2e}\u{30}\u{66}\u{70}\u{70}\u{6d}\u{5d}",totalrounds,(minint - low) / minint * 1e6,(maxint - up) / maxint * 1e6))
784end
784end
785do
785do
786−local count = {0,0,0,0,0,0}
786+local count = {0x0,0x0,0x0,0x0,0x0,0x0}
787−local rep = 200
787+local rep = 0xc8
788−local totalrep = 0
788+local totalrep = 0x0
789::doagain::
789::doagain::
790−for i = 1, rep * 6
790+for i = 0x1, rep * 0x6
791do
791do
792−local r = random(6)
792+local r = random(0x6)
793−count[r]=count[r] + 1
793+count[r]=count[r] + 0x1
794end
794end
795totalrep=totalrep + rep
795totalrep=totalrep + rep
796−for i = 1, 6
796+for i = 0x1, 0x6
797do
797do
798if not testnear(count[i],totalrep,0.05) then
798if not testnear(count[i],totalrep,0.05) then
799goto doagain
799goto doagain
@@ -805,45 +805,45 @@ local function aux
805(x1,x2)
805(x1,x2)
806local mark = {}
806local mark = {}
807;
807;
808−local count = 0
808+local count = 0x0
809while true do
809while true do
810local t = random(x1,x2)
810local t = random(x1,x2)
811assert(x1 <= t and t <= x2)
811assert(x1 <= t and t <= x2)
812if not mark[t] then
812if not mark[t] then
813mark[t]=true
813mark[t]=true
814−count=count + 1
814+count=count + 0x1
815−if count == x2 - x1 + 1 then
815+if count == x2 - x1 + 0x1 then
816goto ok
816goto ok
817end
817end
818end
818end
819end
819end
820::ok::
820::ok::
821end
821end
822−aux(- 10,0)
822+aux(- 0xa,0x0)
823−aux(1,6)
823+aux(0x1,0x6)
824−aux(1,2)
824+aux(0x1,0x2)
825−aux(1,13)
825+aux(0x1,0xd)
826−aux(1,31)
826+aux(0x1,0x1f)
827−aux(1,32)
827+aux(0x1,0x20)
828−aux(1,33)
828+aux(0x1,0x21)
829−aux(- 10,10)
829+aux(- 0xa,0xa)
830−aux(- 10,- 10)
830+aux(- 0xa,- 0xa)
831aux(minint,minint)
831aux(minint,minint)
832aux(maxint,maxint)
832aux(maxint,maxint)
833−aux(minint,minint + 9)
833+aux(minint,minint + 0x9)
834−aux(maxint - 3,maxint)
834+aux(maxint - 0x3,maxint)
835end
835end
836do
836do
837local function aux
837local function aux
838(p1,p2)
838(p1,p2)
839local max = minint
839local max = minint
840local min = maxint
840local min = maxint
841−local n = 100
841+local n = 0x64
842local mark = {}
842local mark = {}
843;
843;
844−local count = 0
844+local count = 0x0
845::doagain::
845::doagain::
846−for _ = 1, n
846+for _ = 0x1, n
847do
847do
848local t = random(p1,p2)
848local t = random(p1,p2)
849if not mark[t] then
849if not mark[t] then
@@ -851,29 +851,29 @@ assert(p1 <= t and t <= p2)
851max=math.max(max,t)
851max=math.max(max,t)
852min=math.min(min,t)
852min=math.min(min,t)
853mark[t]=true
853mark[t]=true
854−count=count + 1
854+count=count + 0x1
855end
855end
856end
856end
857if not (count >= n * 0.8) then
857if not (count >= n * 0.8) then
858goto doagain
858goto doagain
859end
859end
860−local diff = (p2 - p1) >> 4
860+local diff = (p2 - p1) >> 0x4
861if not (min < p1 + diff and max > p2 - diff) then
861if not (min < p1 + diff and max > p2 - diff) then
862goto doagain
862goto doagain
863end
863end
864end
864end
865−aux(0,maxint)
865+aux(0x0,maxint)
866−aux(1,maxint)
866+aux(0x1,maxint)
867−aux(3,maxint // 3)
867+aux(0x3,maxint // 0x3)
868−aux(minint,- 1)
868+aux(minint,- 0x1)
869−aux(minint // 2,maxint // 2)
869+aux(minint // 0x2,maxint // 0x2)
870aux(minint,maxint)
870aux(minint,maxint)
871−aux(minint + 1,maxint)
871+aux(minint + 0x1,maxint)
872−aux(minint,maxint - 1)
872+aux(minint,maxint - 0x1)
873−aux(0,1 << (intbits - 5))
873+aux(0x0,0x1 << (intbits - 0x5))
874end
874end
875−assert(not pcall(random,1,2,3))
875+assert(not pcall(random,0x1,0x2,0x3))
876−assert(not pcall(random,minint + 1,minint))
876+assert(not pcall(random,minint + 0x1,minint))
877−assert(not pcall(random,maxint,maxint - 1))
877+assert(not pcall(random,maxint,maxint - 0x1))
878assert(not pcall(random,maxint,minint))
878assert(not pcall(random,maxint,minint))
879print("\u{4f}\u{4b}")
879print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/nextvar.lua+370−370
@@ -16,72 +16,72 @@ assert(nil)
16end
16end
17end
17end
18local a = {}
18local a = {}
19−for i = 1, 100
19+for i = 0x1, 0x64
20do
20do
21a[i .. "\u{2b}"]=true
21a[i .. "\u{2b}"]=true
22end
22end
23−for i = 1, 100
23+for i = 0x1, 0x64
24do
24do
25a[i .. "\u{2b}"]=undef
25a[i .. "\u{2b}"]=undef
26end
26end
27−for i = 1, 100
27+for i = 0x1, 0x64
28do
28do
29a[i]=true
29a[i]=true
30assert(# a == i)
30assert(# a == i)
31end
31end
32do
32do
33local a = {}
33local a = {}
34−for i = 1, 100
34+for i = 0x1, 0x64
35do
35do
36a[i]=i
36a[i]=i
37end
37end
38−check(a,128,0)
38+check(a,0x80,0x0)
39−for i = 5, 95
39+for i = 0x5, 0x5f
40do
40do
41a[i]=nil
41a[i]=nil
42end
42end
43−check(a,128,0)
43+check(a,0x80,0x0)
44−a.x=1
44+a.x=0x1
45−check(a,4,8)
45+check(a,0x4,0x8)
46−for i = 1, 4
46+for i = 0x1, 0x4
47do
47do
48assert(a[i] == i)
48assert(a[i] == i)
49end
49end
50−for i = 5, 95
50+for i = 0x5, 0x5f
51do
51do
52assert(a[i] == nil)
52assert(a[i] == nil)
53end
53end
54−for i = 96, 100
54+for i = 0x60, 0x64
55do
55do
56assert(a[i] == i)
56assert(a[i] == i)
57end
57end
58−assert(a.x == 1)
58+assert(a.x == 0x1)
59end
59end
60−local x = 0
60+local x = 0x0
61−for k,v in ipairs({10,20,30,["\u{78}"] = 12})
61+for k,v in ipairs({0xa,0x14,0x1e,["\u{78}"] = 0xc})
62do
62do
63−x=x + 1
63+x=x + 0x1
64−assert(k == x and v == x * 10)
64+assert(k == x and v == x * 0xa)
65end
65end
66−for _ in ipairs({["\u{78}"] = 12,["\u{79}"] = 24})
66+for _ in ipairs({["\u{78}"] = 0xc,["\u{79}"] = 0x18})
67do
67do
68assert(nil)
68assert(nil)
69end
69end
70x=false
70x=false
71−local i = 0
71+local i = 0x0
72for k,v in ipairs({true,false,true,false})
72for k,v in ipairs({true,false,true,false})
73do
73do
74−i=i + 1
74+i=i + 0x1
75x=not x
75x=not x
76assert(x == v)
76assert(x == v)
77end
77end
78−assert(i == 4)
78+assert(i == 0x4)
79assert(type(ipairs({})) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and ipairs({}) == ipairs({}))
79assert(type(ipairs({})) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and ipairs({}) == ipairs({}))
80do
80do
81local f = ipairs({})
81local f = ipairs({})
82−local k,v = f({[math.mininteger] = 10},math.maxinteger)
82+local k,v = f({[math.mininteger] = 0xa},math.maxinteger)
83−assert(k == math.mininteger and v == 10)
83+assert(k == math.mininteger and v == 0xa)
84−k,v=f({[math.mininteger] = 10},k)
84+k,v=f({[math.mininteger] = 0xa},k)
85assert(k == nil)
85assert(k == nil)
86end
86end
87if not T then
87if not T then
@@ -89,42 +89,42 @@ if not T then
89else
89else
90local function mp2
90local function mp2
91(n)
91(n)
92−local mp = 2 ^ math.ceil(math.log(n,2))
92+local mp = 0x2 ^ math.ceil(math.log(n,0x2))
93−assert(n == 0 or (mp / 2 < n and n <= mp))
93+assert(n == 0x0 or (mp / 0x2 < n and n <= mp))
94return mp
94return mp
95end
95end
96do
96do
97−local s = 0
97+local s = 0x0
98for _ in pairs(math)
98for _ in pairs(math)
99do
99do
100−s=s + 1
100+s=s + 0x1
101end
101end
102−check(math,0,mp2(s))
102+check(math,0x0,mp2(s))
103end
103end
104−local sizes = {0,1,2,3,4,5,7,8,9,15,16,17,30,31,32,33,34,254,255,256,500,1000}
104+local sizes = {0x0,0x1,0x2,0x3,0x4,0x5,0x7,0x8,0x9,0xf,0x10,0x11,0x1e,0x1f,0x20,0x21,0x22,0xfe,0xff,0x100,0x1f4,0x3e8}
105for _,sa in ipairs(sizes)
105for _,sa in ipairs(sizes)
106do
106do
107local arr = {"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{7b}"}
107local arr = {"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{7b}"}
108−for i = 1, sa
108+for i = 0x1, sa
109do
109do
110−arr[1 + i]="\u{31}\u{2c}"
110+arr[0x1 + i]="\u{31}\u{2c}"
111end
111end
112for _,sh in ipairs(sizes)
112for _,sh in ipairs(sizes)
113do
113do
114−for j = 1, sh
114+for j = 0x1, sh
115do
115do
116−arr[1 + sa + j]=string.format("\u{6b}\u{25}\u{78}\u{3d}\u{25}\u{64}\u{2c}",j,j)
116+arr[0x1 + sa + j]=string.format("\u{6b}\u{25}\u{78}\u{3d}\u{25}\u{64}\u{2c}",j,j)
117end
117end
118−arr[1 + sa + sh + 1]="\u{7d}"
118+arr[0x1 + sa + sh + 0x1]="\u{7d}"
119local prog = table.concat(arr)
119local prog = table.concat(arr)
120local f = assert(load(prog))
120local f = assert(load(prog))
121collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
121collectgarbage("\u{73}\u{74}\u{6f}\u{70}")
122f()
122f()
123−if sa == 0 or sh == 0 then
123+if sa == 0x0 or sh == 0x0 then
124−T.alloccount(2)
124+T.alloccount(0x2)
125;
125;
126else
126else
127−T.alloccount(3)
127+T.alloccount(0x3)
128;
128;
129end
129end
130local t = f()
130local t = f()
@@ -136,158 +136,158 @@ check(t,sa,mp2(sh))
136end
136end
137end
137end
138local a = {}
138local a = {}
139−for i = 1, sizes[# sizes]
139+for i = 0x1, sizes[# sizes]
140do
140do
141a[i]=i
141a[i]=i
142end
142end
143for k in ipairs(sizes)
143for k in ipairs(sizes)
144do
144do
145−local t = {table.unpack(a,1,k)}
145+local t = {table.unpack(a,0x1,k)}
146assert(# t == k)
146assert(# t == k)
147−check(t,k,0)
147+check(t,k,0x0)
148−t={1,2,3,table.unpack(a,1,k)}
148+t={0x1,0x2,0x3,table.unpack(a,0x1,k)}
149−check(t,k + 3,0)
149+check(t,k + 0x3,0x0)
150−assert(# t == k + 3)
150+assert(# t == k + 0x3)
151end
151end
152−local lim = 130
152+local lim = 0x82
153local a = {}
153local a = {}
154;
154;
155−a[2]=1
155+a[0x2]=0x1
156;
156;
157−check(a,0,1)
157+check(a,0x0,0x1)
158a={}
158a={}
159;
159;
160−a[0]=1
160+a[0x0]=0x1
161;
161;
162−check(a,0,1)
162+check(a,0x0,0x1)
163;
163;
164−a[2]=1
164+a[0x2]=0x1
165;
165;
166−check(a,0,2)
166+check(a,0x0,0x2)
167a={}
167a={}
168;
168;
169−a[0]=1
169+a[0x0]=0x1
170;
170;
171−a[1]=1
171+a[0x1]=0x1
172;
172;
173−check(a,1,1)
173+check(a,0x1,0x1)
174a={}
174a={}
175−for i = 1, lim
175+for i = 0x1, lim
176do
176do
177−a[i]=1
177+a[i]=0x1
178assert(# a == i)
178assert(# a == i)
179−check(a,mp2(i),0)
179+check(a,mp2(i),0x0)
180end
180end
181a={}
181a={}
182−for i = 1, lim
182+for i = 0x1, lim
183do
183do
184−a["\u{61}" .. i]=1
184+a["\u{61}" .. i]=0x1
185−assert(# a == 0)
185+assert(# a == 0x0)
186−check(a,0,mp2(i))
186+check(a,0x0,mp2(i))
187end
187end
188a={}
188a={}
189−for i = 1, 16
189+for i = 0x1, 0x10
190do
190do
191a[i]=i
191a[i]=i
192end
192end
193−check(a,16,0)
193+check(a,0x10,0x0)
194do
194do
195−for i = 1, 11
195+for i = 0x1, 0xb
196do
196do
197a[i]=undef
197a[i]=undef
198end
198end
199−for i = 30, 50
199+for i = 0x1e, 0x32
200do
200do
201a[i]=true
201a[i]=true
202;
202;
203a[i]=undef
203a[i]=undef
204end
204end
205−check(a,0,8)
205+check(a,0x0,0x8)
206−a[10]=1
206+a[0xa]=0x1
207−for i = 30, 50
207+for i = 0x1e, 0x32
208do
208do
209a[i]=true
209a[i]=true
210;
210;
211a[i]=undef
211a[i]=undef
212end
212end
213−check(a,0,8)
213+check(a,0x0,0x8)
214−for i = 1, 14
214+for i = 0x1, 0xe
215do
215do
216a[i]=true
216a[i]=true
217;
217;
218a[i]=undef
218a[i]=undef
219end
219end
220−for i = 18, 50
220+for i = 0x12, 0x32
221do
221do
222a[i]=true
222a[i]=true
223;
223;
224a[i]=undef
224a[i]=undef
225end
225end
226−check(a,0,4)
226+check(a,0x0,0x4)
227end
227end
228−for i = 1, lim
228+for i = 0x1, lim
229do
229do
230local a = {}
230local a = {}
231−for i = i, 1, - 1
231+for i = i, 0x1, - 0x1
232do
232do
233a[i]=i
233a[i]=i
234end
234end
235−check(a,mp2(i),0)
235+check(a,mp2(i),0x0)
236end
236end
237−lim=35
237+lim=0x23
238local function foo
238local function foo
239(n, ...)
239(n, ...)
240local arg = {...}
240local arg = {...}
241−check(arg,n,0)
241+check(arg,n,0x0)
242assert(select("\u{23}",...) == n)
242assert(select("\u{23}",...) == n)
243−arg[n + 1]=true
243+arg[n + 0x1]=true
244−check(arg,mp2(n + 1),0)
244+check(arg,mp2(n + 0x1),0x0)
245arg.x=true
245arg.x=true
246−check(arg,mp2(n + 1),1)
246+check(arg,mp2(n + 0x1),0x1)
247end
247end
248local a = {}
248local a = {}
249−for i = 1, lim
249+for i = 0x1, lim
250do
250do
251a[i]=true
251a[i]=true
252;
252;
253foo(i,table.unpack(a))
253foo(i,table.unpack(a))
254end
254end
255local a = {}
255local a = {}
256−for i = 1, 64
256+for i = 0x1, 0x40
257do
257do
258a[i]=true
258a[i]=true
259end
259end
260−for i = 1, 64
260+for i = 0x1, 0x40
261do
261do
262a[i]=nil
262a[i]=nil
263end
263end
264−assert(T.querytab(a) == 64)
264+assert(T.querytab(a) == 0x40)
265−a[32]=true
265+a[0x20]=true
266;
266;
267−a[48]=true
267+a[0x30]=true
268;
268;
269−a[51]=true
269+a[0x33]=true
270−assert(# a == 48)
270+assert(# a == 0x30)
271−assert(select(4,T.querytab(a)) == 48)
271+assert(select(0x4,T.querytab(a)) == 0x30)
272−a[50]=true
272+a[0x32]=true
273−assert(select(4,T.querytab(a)) == 50)
273+assert(select(0x4,T.querytab(a)) == 0x32)
274−assert(# a == 51)
274+assert(# a == 0x33)
275end
275end
276−assert(# {} == 0)
276+assert(# {} == 0x0)
277−assert(# {nil} == 0)
277+assert(# {nil} == 0x0)
278−assert(# {nil,nil} == 0)
278+assert(# {nil,nil} == 0x0)
279−assert(# {nil,nil,nil} == 0)
279+assert(# {nil,nil,nil} == 0x0)
280−assert(# {nil,nil,nil,nil} == 0)
280+assert(# {nil,nil,nil,nil} == 0x0)
281−assert(# {1,2,3,nil,nil} == 3)
281+assert(# {0x1,0x2,0x3,nil,nil} == 0x3)
282print("\u{2b}")
282print("\u{2b}")
283local nofind = {}
283local nofind = {}
284−a,b,c=1,2,3
284+a,b,c=0x1,0x2,0x3
285a,b,c=nil
285a,b,c=nil
286assert(next({}) == next({}))
286assert(next({}) == next({}))
287local function find
287local function find
288(name)
288(name)
289local n,v
289local n,v
290−while 1 do
290+while 0x1 do
291n,v=next(_G,n)
291n,v=next(_G,n)
292if not n then
292if not n then
293return nofind
293return nofind
@@ -315,26 +315,26 @@ assert(nofind == find("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"))
315assert(not find1("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"))
315assert(not find1("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"))
316_G["\u{72}\u{65}\u{74}" .. "\u{75}\u{72}\u{6e}"]=undef
316_G["\u{72}\u{65}\u{74}" .. "\u{75}\u{72}\u{6e}"]=undef
317assert(nofind == find("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"))
317assert(nofind == find("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}"))
318−_G["\u{78}\u{78}\u{78}"]=1
318+_G["\u{78}\u{78}\u{78}"]=0x1
319assert(xxx == find("\u{78}\u{78}\u{78}"))
319assert(xxx == find("\u{78}\u{78}\u{78}"))
320−checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6b}\u{65}\u{79}",next,{10,20},3)
320+checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6b}\u{65}\u{79}",next,{0xa,0x14},0x3)
321checkerror("\u{62}\u{61}\u{64}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}",pairs)
321checkerror("\u{62}\u{61}\u{64}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}",pairs)
322checkerror("\u{62}\u{61}\u{64}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}",ipairs)
322checkerror("\u{62}\u{61}\u{64}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}",ipairs)
323print("\u{2b}")
323print("\u{2b}")
324a={}
324a={}
325−for i = 0, 10000
325+for i = 0x0, 0x2710
326do
326do
327−if math.fmod(i,10) ~= 0 then
327+if math.fmod(i,0xa) ~= 0x0 then
328a["\u{78}" .. i]=i
328a["\u{78}" .. i]=i
329end
329end
330end
330end
331−n={["\u{6e}"] = 0}
331+n={["\u{6e}"] = 0x0}
332for i,v in pairs(a)
332for i,v in pairs(a)
333do
333do
334−n.n=n.n + 1
334+n.n=n.n + 0x1
335assert(i and v and a[i] == v)
335assert(i and v and a[i] == v)
336end
336end
337−assert(n.n == 9000)
337+assert(n.n == 0x2328)
338a=nil
338a=nil
339do
339do
340local a = {}
340local a = {}
@@ -371,48 +371,48 @@ do
371assert(b[k] == v)
371assert(b[k] == v)
372end
372end
373end
373end
374−checknext({1,["\u{78}"] = 1,["\u{79}"] = 2,["\u{7a}"] = 3})
374+checknext({0x1,["\u{78}"] = 0x1,["\u{79}"] = 0x2,["\u{7a}"] = 0x3})
375−checknext({1,2,["\u{78}"] = 1,["\u{79}"] = 2,["\u{7a}"] = 3})
375+checknext({0x1,0x2,["\u{78}"] = 0x1,["\u{79}"] = 0x2,["\u{7a}"] = 0x3})
376−checknext({1,2,3,["\u{78}"] = 1,["\u{79}"] = 2,["\u{7a}"] = 3})
376+checknext({0x1,0x2,0x3,["\u{78}"] = 0x1,["\u{79}"] = 0x2,["\u{7a}"] = 0x3})
377−checknext({1,2,3,4,["\u{78}"] = 1,["\u{79}"] = 2,["\u{7a}"] = 3})
377+checknext({0x1,0x2,0x3,0x4,["\u{78}"] = 0x1,["\u{79}"] = 0x2,["\u{7a}"] = 0x3})
378−checknext({1,2,3,4,5,["\u{78}"] = 1,["\u{79}"] = 2,["\u{7a}"] = 3})
378+checknext({0x1,0x2,0x3,0x4,0x5,["\u{78}"] = 0x1,["\u{79}"] = 0x2,["\u{7a}"] = 0x3})
379−assert(# {} == 0)
379+assert(# {} == 0x0)
380−assert(# {[- 1] = 2} == 0)
380+assert(# {[- 0x1] = 0x2} == 0x0)
381−for i = 0, 40
381+for i = 0x0, 0x28
382do
382do
383local a = {}
383local a = {}
384−for j = 1, i
384+for j = 0x1, i
385do
385do
386a[j]=j
386a[j]=j
387end
387end
388assert(# a == i)
388assert(# a == i)
389end
389end
390function table.maxn(t)
390function table.maxn(t)
391−local max = 0
391+local max = 0x0
392for k in pairs(t)
392for k in pairs(t)
393do
393do
394max=(type(k) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}") and math.max(max,k) or max
394max=(type(k) == "\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}") and math.max(max,k) or max
395end
395end
396return max
396return max
397end
397end
398−assert(table.maxn({}) == 0)
398+assert(table.maxn({}) == 0x0)
399−assert(table.maxn({["\u{31}\u{30}\u{30}\u{30}"] = true}) == 0)
399+assert(table.maxn({["\u{31}\u{30}\u{30}\u{30}"] = true}) == 0x0)
400−assert(table.maxn({["\u{31}\u{30}\u{30}\u{30}"] = true,[24.5] = 3}) == 24.5)
400+assert(table.maxn({["\u{31}\u{30}\u{30}\u{30}"] = true,[24.5] = 0x3}) == 24.5)
401−assert(table.maxn({[1000] = true}) == 1000)
401+assert(table.maxn({[0x3e8] = true}) == 0x3e8)
402−assert(table.maxn({[10] = true,[100 * math.pi] = print}) == 100 * math.pi)
402+assert(table.maxn({[0xa] = true,[0x64 * math.pi] = print}) == 0x64 * math.pi)
403table.maxn=nil
403table.maxn=nil
404a={}
404a={}
405−for i = 0, 50
405+for i = 0x0, 0x32
406do
406do
407−a[2 ^ i]=true
407+a[0x2 ^ i]=true
408end
408end
409assert(a[# a])
409assert(a[# a])
410print("\u{2b}")
410print("\u{2b}")
411do
411do
412−local a = {[1] = 1,[1.1] = 2,["\u{78}"] = 3,[string.rep("\u{78}",1000)] = 4,[print] = 5,[checkerror] = 6,[coroutine.running()] = 7,[true] = 8,[io.stdin] = 9,[{}] = 10}
412+local a = {[0x1] = 0x1,[1.1] = 0x2,["\u{78}"] = 0x3,[string.rep("\u{78}",0x3e8)] = 0x4,[print] = 0x5,[checkerror] = 0x6,[coroutine.running()] = 0x7,[true] = 0x8,[io.stdin] = 0x9,[{}] = 0xa}
413local b = {}
413local b = {}
414;
414;
415−for i = 1, 10
415+for i = 0x1, 0xa
416do
416do
417b[i]=true
417b[i]=true
418end
418end
@@ -424,17 +424,17 @@ b[v]=undef
424end
424end
425assert(next(b) == nil)
425assert(next(b) == nil)
426end
426end
427−local t = {[{1}] = 1,[{2}] = 2,[string.rep("\u{78}\u{20}",4)] = 3,[100.3] = 4,[4] = 5}
427+local t = {[{0x1}] = 0x1,[{0x2}] = 0x2,[string.rep("\u{78}\u{20}",0x4)] = 0x3,[100.3] = 0x4,[0x4] = 0x5}
428−local n = 0
428+local n = 0x0
429for k,v in pairs(t)
429for k,v in pairs(t)
430do
430do
431−n=n + 1
431+n=n + 0x1
432assert(t[k] == v)
432assert(t[k] == v)
433t[k]=undef
433t[k]=undef
434collectgarbage()
434collectgarbage()
435assert(t[k] == undef)
435assert(t[k] == undef)
436end
436end
437−assert(n == 5)
437+assert(n == 0x5)
438do
438do
439print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{78}\u{20}\u{47}\u{43}\u{20}\u{6f}\u{66}\u{20}\u{64}\u{65}\u{6c}\u{65}\u{74}\u{65}\u{64}\u{20}\u{6b}\u{65}\u{79}\u{73}")
439print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{78}\u{20}\u{47}\u{43}\u{20}\u{6f}\u{66}\u{20}\u{64}\u{65}\u{6c}\u{65}\u{74}\u{65}\u{64}\u{20}\u{6b}\u{65}\u{79}\u{73}")
440local co = coroutine.wrap(function (t)
440local co = coroutine.wrap(function (t)
@@ -443,139 +443,139 @@ do
443local k1 = next(t)
443local k1 = next(t)
444assert(k == k1)
444assert(k == k1)
445t[k]=nil
445t[k]=nil
446−local expected = (type(k) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and k[1] or type(k) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and k() or string.sub(k,1,1))
446+local expected = (type(k) == "\u{74}\u{61}\u{62}\u{6c}\u{65}" and k[0x1] or type(k) == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}" and k() or string.sub(k,0x1,0x1))
447assert(expected == v)
447assert(expected == v)
448coroutine.yield(v)
448coroutine.yield(v)
449end
449end
450end)
450end)
451local t = {}
451local t = {}
452−t[{1}]=1
452+t[{0x1}]=0x1
453−t[{2}]=2
453+t[{0x2}]=0x2
454−t[string.rep("\u{61}",50)]="\u{61}"
454+t[string.rep("\u{61}",0x32)]="\u{61}"
455−t[string.rep("\u{62}",50)]="\u{62}"
455+t[string.rep("\u{62}",0x32)]="\u{62}"
456−t[{3}]=3
456+t[{0x3}]=0x3
457−t[string.rep("\u{63}",10)]="\u{63}"
457+t[string.rep("\u{63}",0xa)]="\u{63}"
458t[function ()
458t[function ()
459−return 10
459+return 0xa
460−end]=10
460+end]=0xa
461−local count = 7
461+local count = 0x7
462while co(t) do
462while co(t) do
463collectgarbage("\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}")
463collectgarbage("\u{63}\u{6f}\u{6c}\u{6c}\u{65}\u{63}\u{74}")
464−count=count - 1
464+count=count - 0x1
465end
465end
466−assert(count == 0 and next(t) == nil)
466+assert(count == 0x0 and next(t) == nil)
467end
467end
468local function test
468local function test
469(a)
469(a)
470−assert(not pcall(table.insert,a,2,20))
470+assert(not pcall(table.insert,a,0x2,0x14))
471;
471;
472−table.insert(a,10)
472+table.insert(a,0xa)
473;
473;
474−table.insert(a,2,20)
474+table.insert(a,0x2,0x14)
475;
475;
476−table.insert(a,1,- 1)
476+table.insert(a,0x1,- 0x1)
477;
477;
478−table.insert(a,40)
478+table.insert(a,0x28)
479;
479;
480−table.insert(a,# a + 1,50)
480+table.insert(a,# a + 0x1,0x32)
481−table.insert(a,2,- 2)
481+table.insert(a,0x2,- 0x2)
482−assert(a[2] ~= undef)
482+assert(a[0x2] ~= undef)
483assert(a["\u{32}"] == undef)
483assert(a["\u{32}"] == undef)
484−assert(not pcall(table.insert,a,0,20))
484+assert(not pcall(table.insert,a,0x0,0x14))
485;
485;
486−assert(not pcall(table.insert,a,# a + 2,20))
486+assert(not pcall(table.insert,a,# a + 0x2,0x14))
487;
487;
488−assert(table.remove(a,1) == - 1)
488+assert(table.remove(a,0x1) == - 0x1)
489−assert(table.remove(a,1) == - 2)
489+assert(table.remove(a,0x1) == - 0x2)
490−assert(table.remove(a,1) == 10)
490+assert(table.remove(a,0x1) == 0xa)
491−assert(table.remove(a,1) == 20)
491+assert(table.remove(a,0x1) == 0x14)
492−assert(table.remove(a,1) == 40)
492+assert(table.remove(a,0x1) == 0x28)
493−assert(table.remove(a,1) == 50)
493+assert(table.remove(a,0x1) == 0x32)
494−assert(table.remove(a,1) == nil)
494+assert(table.remove(a,0x1) == nil)
495assert(table.remove(a) == nil)
495assert(table.remove(a) == nil)
496assert(table.remove(a,# a) == nil)
496assert(table.remove(a,# a) == nil)
497end
497end
498−a={["\u{6e}"] = 0,[- 7] = "\u{62}\u{61}\u{6e}"}
498+a={["\u{6e}"] = 0x0,[- 0x7] = "\u{62}\u{61}\u{6e}"}
499test(a)
499test(a)
500−assert(a.n == 0 and a[- 7] == "\u{62}\u{61}\u{6e}")
500+assert(a.n == 0x0 and a[- 0x7] == "\u{62}\u{61}\u{6e}")
501−a={[- 7] = "\u{62}\u{61}\u{6e}"}
501+a={[- 0x7] = "\u{62}\u{61}\u{6e}"}
502;
502;
503test(a)
503test(a)
504−assert(a.n == nil and # a == 0 and a[- 7] == "\u{62}\u{61}\u{6e}")
504+assert(a.n == nil and # a == 0x0 and a[- 0x7] == "\u{62}\u{61}\u{6e}")
505−a={[- 1] = "\u{62}\u{61}\u{6e}"}
505+a={[- 0x1] = "\u{62}\u{61}\u{6e}"}
506test(a)
506test(a)
507−assert(# a == 0 and table.remove(a) == nil and a[- 1] == "\u{62}\u{61}\u{6e}")
507+assert(# a == 0x0 and table.remove(a) == nil and a[- 0x1] == "\u{62}\u{61}\u{6e}")
508−a={[0] = "\u{62}\u{61}\u{6e}"}
508+a={[0x0] = "\u{62}\u{61}\u{6e}"}
509−assert(# a == 0 and table.remove(a) == "\u{62}\u{61}\u{6e}" and a[0] == undef)
509+assert(# a == 0x0 and table.remove(a) == "\u{62}\u{61}\u{6e}" and a[0x0] == undef)
510−table.insert(a,1,10)
510+table.insert(a,0x1,0xa)
511;
511;
512−table.insert(a,1,20)
512+table.insert(a,0x1,0x14)
513;
513;
514−table.insert(a,1,- 1)
514+table.insert(a,0x1,- 0x1)
515−assert(table.remove(a) == 10)
515+assert(table.remove(a) == 0xa)
516−assert(table.remove(a) == 20)
516+assert(table.remove(a) == 0x14)
517−assert(table.remove(a) == - 1)
517+assert(table.remove(a) == - 0x1)
518assert(table.remove(a) == nil)
518assert(table.remove(a) == nil)
519a={"\u{63}","\u{64}"}
519a={"\u{63}","\u{64}"}
520−table.insert(a,3,"\u{61}")
520+table.insert(a,0x3,"\u{61}")
521table.insert(a,"\u{62}")
521table.insert(a,"\u{62}")
522−assert(table.remove(a,1) == "\u{63}")
522+assert(table.remove(a,0x1) == "\u{63}")
523−assert(table.remove(a,1) == "\u{64}")
523+assert(table.remove(a,0x1) == "\u{64}")
524−assert(table.remove(a,1) == "\u{61}")
524+assert(table.remove(a,0x1) == "\u{61}")
525−assert(table.remove(a,1) == "\u{62}")
525+assert(table.remove(a,0x1) == "\u{62}")
526−assert(table.remove(a,1) == nil)
526+assert(table.remove(a,0x1) == nil)
527−assert(# a == 0 and a.n == nil)
527+assert(# a == 0x0 and a.n == nil)
528−a={10,20,30,40}
528+a={0xa,0x14,0x1e,0x28}
529−assert(table.remove(a,# a + 1) == nil)
529+assert(table.remove(a,# a + 0x1) == nil)
530−assert(not pcall(table.remove,a,0))
530+assert(not pcall(table.remove,a,0x0))
531−assert(a[# a] == 40)
531+assert(a[# a] == 0x28)
532−assert(table.remove(a,# a) == 40)
532+assert(table.remove(a,# a) == 0x28)
533−assert(a[# a] == 30)
533+assert(a[# a] == 0x1e)
534−assert(table.remove(a,2) == 20)
534+assert(table.remove(a,0x2) == 0x14)
535−assert(a[# a] == 30 and # a == 2)
535+assert(a[# a] == 0x1e and # a == 0x2)
536do
536do
537local function test
537local function test
538(proxy,t)
538(proxy,t)
539−for i = 1, 10
539+for i = 0x1, 0xa
540do
540do
541−table.insert(proxy,1,i)
541+table.insert(proxy,0x1,i)
542end
542end
543−assert(# proxy == 10 and # t == 10 and proxy[1] ~= undef)
543+assert(# proxy == 0xa and # t == 0xa and proxy[0x1] ~= undef)
544−for i = 1, 10
544+for i = 0x1, 0xa
545do
545do
546−assert(t[i] == 11 - i)
546+assert(t[i] == 0xb - i)
547end
547end
548table.sort(proxy)
548table.sort(proxy)
549−for i = 1, 10
549+for i = 0x1, 0xa
550do
550do
551assert(t[i] == i and proxy[i] == i)
551assert(t[i] == i and proxy[i] == i)
552end
552end
553assert(table.concat(proxy,"\u{2c}") == "\u{31}\u{2c}\u{32}\u{2c}\u{33}\u{2c}\u{34}\u{2c}\u{35}\u{2c}\u{36}\u{2c}\u{37}\u{2c}\u{38}\u{2c}\u{39}\u{2c}\u{31}\u{30}")
553assert(table.concat(proxy,"\u{2c}") == "\u{31}\u{2c}\u{32}\u{2c}\u{33}\u{2c}\u{34}\u{2c}\u{35}\u{2c}\u{36}\u{2c}\u{37}\u{2c}\u{38}\u{2c}\u{39}\u{2c}\u{31}\u{30}")
554−for i = 1, 8
554+for i = 0x1, 0x8
555do
555do
556−assert(table.remove(proxy,1) == i)
556+assert(table.remove(proxy,0x1) == i)
557end
557end
558−assert(# proxy == 2 and # t == 2)
558+assert(# proxy == 0x2 and # t == 0x2)
559local a,b,c = table.unpack(proxy)
559local a,b,c = table.unpack(proxy)
560−assert(a == 9 and b == 10 and c == nil)
560+assert(a == 0x9 and b == 0xa and c == nil)
561end
561end
562local t = {}
562local t = {}
563local proxy = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
563local proxy = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
564return # t
564return # t
565end,["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = t,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = t})
565end,["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = t,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = t})
566test(proxy,t)
566test(proxy,t)
567−local count = 0
567+local count = 0x0
568t=setmetatable({},{["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k,v)
568t=setmetatable({},{["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k,v)
569−count=count + 1
569+count=count + 0x1
570;
570;
571rawset(t,k,v)
571rawset(t,k,v)
572end})
572end})
573test(t,t)
573test(t,t)
574−assert(count == 10)
574+assert(count == 0xa)
575t=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,k)
575t=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,k)
576−return k + 1
576+return k + 0x1
577end,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function (_)
577end,["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function (_)
578−return 5
578+return 0x5
579end})
579end})
580assert(table.concat(t,"\u{3b}") == "\u{32}\u{3b}\u{33}\u{3b}\u{34}\u{3b}\u{35}\u{3b}\u{36}")
580assert(table.concat(t,"\u{3b}") == "\u{32}\u{3b}\u{33}\u{3b}\u{34}\u{3b}\u{35}\u{3b}\u{36}")
581end
581end
@@ -583,323 +583,323 @@ do
583local t = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
583local t = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
584return math.maxinteger
584return math.maxinteger
585end})
585end})
586−table.insert(t,20)
586+table.insert(t,0x14)
587local k,v = next(t)
587local k,v = next(t)
588−assert(k == math.mininteger and v == 20)
588+assert(k == math.mininteger and v == 0x14)
589end
589end
590if not T then
590if not T then
591(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{6c}\u{69}\u{62}\u{72}\u{61}\u{72}\u{79}\u{20}\u{6f}\u{6e}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
591(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{6c}\u{69}\u{62}\u{72}\u{61}\u{72}\u{79}\u{20}\u{6f}\u{6e}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
592else
592else
593local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
593local debug = require("\u{64}\u{65}\u{62}\u{75}\u{67}")
594−local tab = {10,20,30}
594+local tab = {0xa,0x14,0x1e}
595local mt = {}
595local mt = {}
596−local u = T.newuserdata(0)
596+local u = T.newuserdata(0x0)
597−checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,40)
597+checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,0x28)
598checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
598checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
599debug.setmetatable(u,mt)
599debug.setmetatable(u,mt)
600−checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,40)
600+checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,0x28)
601checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
601checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
602mt.__index=tab
602mt.__index=tab
603−checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,40)
603+checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,0x28)
604checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
604checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
605mt.__newindex=tab
605mt.__newindex=tab
606−checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,40)
606+checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.insert,u,0x28)
607checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
607checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.remove,u)
608mt.__len=function ()
608mt.__len=function ()
609return # tab
609return # tab
610end
610end
611−table.insert(u,40)
611+table.insert(u,0x28)
612−assert(# u == 4 and # tab == 4 and u[4] == 40 and tab[4] == 40)
612+assert(# u == 0x4 and # tab == 0x4 and u[0x4] == 0x28 and tab[0x4] == 0x28)
613−assert(table.remove(u) == 40)
613+assert(table.remove(u) == 0x28)
614−table.insert(u,1,50)
614+table.insert(u,0x1,0x32)
615−assert(# u == 4 and # tab == 4 and u[4] == 30 and tab[1] == 50)
615+assert(# u == 0x4 and # tab == 0x4 and u[0x4] == 0x1e and tab[0x1] == 0x32)
616mt.__newindex=nil
616mt.__newindex=nil
617mt.__len=nil
617mt.__len=nil
618local tab2 = {}
618local tab2 = {}
619−local u2 = T.newuserdata(0)
619+local u2 = T.newuserdata(0x0)
620debug.setmetatable(u2,{["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,k,v)
620debug.setmetatable(u2,{["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,k,v)
621tab2[k]=v
621tab2[k]=v
622end})
622end})
623−table.move(u,1,4,1,u2)
623+table.move(u,0x1,0x4,0x1,u2)
624−assert(# tab2 == 4 and tab2[1] == tab[1] and tab2[4] == tab[4])
624+assert(# tab2 == 0x4 and tab2[0x1] == tab[0x1] and tab2[0x4] == tab[0x4])
625end
625end
626print("\u{2b}")
626print("\u{2b}")
627a={}
627a={}
628−for i = 1, 1000
628+for i = 0x1, 0x3e8
629do
629do
630a[i]=i
630a[i]=i
631;
631;
632−a[i - 1]=undef
632+a[i - 0x1]=undef
633end
633end
634−assert(next(a,nil) == 1000 and next(a,1000) == nil)
634+assert(next(a,nil) == 0x3e8 and next(a,0x3e8) == nil)
635assert(next({}) == nil)
635assert(next({}) == nil)
636assert(next({},nil) == nil)
636assert(next({},nil) == nil)
637for a,b in pairs({})
637for a,b in pairs({})
638do
638do
639error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
639error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
640end
640end
641−for i = 1, 0
641+for i = 0x1, 0x0
642do
642do
643error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
643error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
644end
644end
645−for i = 0, 1, - 1
645+for i = 0x0, 0x1, - 0x1
646do
646do
647error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
647error("\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{65}\u{72}\u{65}")
648end
648end
649a=nil
649a=nil
650;
650;
651−for i = 1, 1
651+for i = 0x1, 0x1
652do
652do
653assert(not a)
653assert(not a)
654;
654;
655−a=1
655+a=0x1
656end
656end
657;
657;
658assert(a)
658assert(a)
659a=nil
659a=nil
660;
660;
661−for i = 1, 1, - 1
661+for i = 0x1, 0x1, - 0x1
662do
662do
663assert(not a)
663assert(not a)
664;
664;
665−a=1
665+a=0x1
666end
666end
667;
667;
668assert(a)
668assert(a)
669do
669do
670print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{6e}\u{75}\u{6d}\u{65}\u{72}\u{69}\u{63}\u{20}\u{66}\u{6f}\u{72}")
670print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{6e}\u{75}\u{6d}\u{65}\u{72}\u{69}\u{63}\u{20}\u{66}\u{6f}\u{72}")
671local a
671local a
672−a=0
672+a=0x0
673;
673;
674−for i = 1, 1, 1
674+for i = 0x1, 0x1, 0x1
675do
675do
676−a=a + 1
676+a=a + 0x1
677end
677end
678;
678;
679−assert(a == 1)
679+assert(a == 0x1)
680−a=0
680+a=0x0
681;
681;
682−for i = 10000, 1e4, - 1
682+for i = 0x2710, 1e4, - 0x1
683do
683do
684−a=a + 1
684+a=a + 0x1
685end
685end
686;
686;
687−assert(a == 1)
687+assert(a == 0x1)
688−a=0
688+a=0x0
689;
689;
690−for i = 1, 0.99999, 1
690+for i = 0x1, 0.99999, 0x1
691do
691do
692−a=a + 1
692+a=a + 0x1
693end
693end
694;
694;
695−assert(a == 0)
695+assert(a == 0x0)
696−a=0
696+a=0x0
697;
697;
698−for i = 9999, 1e4, - 1
698+for i = 0x270f, 1e4, - 0x1
699do
699do
700−a=a + 1
700+a=a + 0x1
701end
701end
702;
702;
703−assert(a == 0)
703+assert(a == 0x0)
704−a=0
704+a=0x0
705;
705;
706−for i = 1, 0.99999, - 1
706+for i = 0x1, 0.99999, - 0x1
707do
707do
708−a=a + 1
708+a=a + 0x1
709end
709end
710;
710;
711−assert(a == 1)
711+assert(a == 0x1)
712−a=0
712+a=0x0
713;
713;
714−for i = 0, 0.999999999, 0.1
714+for i = 0x0, 0.999999999, 0.1
715do
715do
716−a=a + 1
716+a=a + 0x1
717end
717end
718;
718;
719−assert(a == 10)
719+assert(a == 0xa)
720−a=0
720+a=0x0
721;
721;
722−for i = 1.0, 1, 1
722+for i = 1.0, 0x1, 0x1
723do
723do
724−a=a + 1
724+a=a + 0x1
725end
725end
726;
726;
727−assert(a == 1)
727+assert(a == 0x1)
728−a=0
728+a=0x0
729;
729;
730−for i = - 1.5, - 1.5, 1
730+for i = - 1.5, - 1.5, 0x1
731do
731do
732−a=a + 1
732+a=a + 0x1
733end
733end
734;
734;
735−assert(a == 1)
735+assert(a == 0x1)
736−a=0
736+a=0x0
737;
737;
738−for i = 1e6, 1e6, - 1
738+for i = 1e6, 1e6, - 0x1
739do
739do
740−a=a + 1
740+a=a + 0x1
741end
741end
742;
742;
743−assert(a == 1)
743+assert(a == 0x1)
744−a=0
744+a=0x0
745;
745;
746−for i = 1.0, 0.99999, 1
746+for i = 1.0, 0.99999, 0x1
747do
747do
748−a=a + 1
748+a=a + 0x1
749end
749end
750;
750;
751−assert(a == 0)
751+assert(a == 0x0)
752−a=0
752+a=0x0
753;
753;
754−for i = 99999, 1e5, - 1.0
754+for i = 0x1869f, 1e5, - 1.0
755do
755do
756−a=a + 1
756+a=a + 0x1
757end
757end
758;
758;
759−assert(a == 0)
759+assert(a == 0x0)
760−a=0
760+a=0x0
761;
761;
762−for i = 1.0, 0.99999, - 1
762+for i = 1.0, 0.99999, - 0x1
763do
763do
764−a=a + 1
764+a=a + 0x1
765end
765end
766;
766;
767−assert(a == 1)
767+assert(a == 0x1)
768end
768end
769do
769do
770local a
770local a
771−a=0
771+a=0x0
772;
772;
773−for i = 1, 10
773+for i = 0x1, 0xa
774do
774do
775−a=a + 1
775+a=a + 0x1
776;
776;
777i="\u{78}"
777i="\u{78}"
778end
778end
779;
779;
780−assert(a == 10)
780+assert(a == 0xa)
781−a=0
781+a=0x0
782;
782;
783−for i = 10.0, 1, - 1
783+for i = 10.0, 0x1, - 0x1
784do
784do
785−a=a + 1
785+a=a + 0x1
786;
786;
787i="\u{78}"
787i="\u{78}"
788end
788end
789;
789;
790−assert(a == 10)
790+assert(a == 0xa)
791end
791end
792−a=0
792+a=0x0
793;
793;
794for i = "\u{31}\u{30}", "\u{31}", "\u{2d}\u{32}"
794for i = "\u{31}\u{30}", "\u{31}", "\u{2d}\u{32}"
795do
795do
796−a=a + 1
796+a=a + 0x1
797end
797end
798;
798;
799−assert(a == 5)
799+assert(a == 0x5)
800do
800do
801local c
801local c
802local function checkfloat
802local function checkfloat
803(i)
803(i)
804assert(math.type(i) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
804assert(math.type(i) == "\u{66}\u{6c}\u{6f}\u{61}\u{74}")
805−c=c + 1
805+c=c + 0x1
806end
806end
807−c=0
807+c=0x0
808;
808;
809−for i = 1.0, 10
809+for i = 1.0, 0xa
810do
810do
811checkfloat(i)
811checkfloat(i)
812end
812end
813−assert(c == 10)
813+assert(c == 0xa)
814−c=0
814+c=0x0
815;
815;
816−for i = - 1, - 10, - 1.0
816+for i = - 0x1, - 0xa, - 1.0
817do
817do
818checkfloat(i)
818checkfloat(i)
819end
819end
820−assert(c == 10)
820+assert(c == 0xa)
821local function checkint
821local function checkint
822(i)
822(i)
823assert(math.type(i) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}")
823assert(math.type(i) == "\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}")
824−c=c + 1
824+c=c + 0x1
825end
825end
826local m = math.maxinteger
826local m = math.maxinteger
827−c=0
827+c=0x0
828;
828;
829−for i = m, m - 10, - 1
829+for i = m, m - 0xa, - 0x1
830do
830do
831checkint(i)
831checkint(i)
832end
832end
833−assert(c == 11)
833+assert(c == 0xb)
834−c=0
834+c=0x0
835;
835;
836−for i = 1, 10.9
836+for i = 0x1, 10.9
837do
837do
838checkint(i)
838checkint(i)
839end
839end
840−assert(c == 10)
840+assert(c == 0xa)
841−c=0
841+c=0x0
842;
842;
843−for i = 10, 1e-3, - 1
843+for i = 0xa, 1e-3, - 0x1
844do
844do
845checkint(i)
845checkint(i)
846end
846end
847−assert(c == 10)
847+assert(c == 0xa)
848−c=0
848+c=0x0
849;
849;
850−for i = 1, "\u{31}\u{30}\u{2e}\u{38}"
850+for i = 0x1, "\u{31}\u{30}\u{2e}\u{38}"
851do
851do
852checkint(i)
852checkint(i)
853end
853end
854−assert(c == 10)
854+assert(c == 0xa)
855−c=0
855+c=0x0
856;
856;
857−for i = 9, "\u{33}\u{2e}\u{34}", - 1
857+for i = 0x9, "\u{33}\u{2e}\u{34}", - 0x1
858do
858do
859checkint(i)
859checkint(i)
860end
860end
861−assert(c == 6)
861+assert(c == 0x6)
862−c=0
862+c=0x0
863;
863;
864−for i = 0, "\u{20}\u{2d}\u{33}\u{2e}\u{34}\u{20}\u{20}", - 1
864+for i = 0x0, "\u{20}\u{2d}\u{33}\u{2e}\u{34}\u{20}\u{20}", - 0x1
865do
865do
866checkint(i)
866checkint(i)
867end
867end
868−assert(c == 4)
868+assert(c == 0x4)
869−c=0
869+c=0x0
870;
870;
871−for i = 100, "\u{39}\u{36}\u{2e}\u{33}", - 2
871+for i = 0x64, "\u{39}\u{36}\u{2e}\u{33}", - 0x2
872do
872do
873checkint(i)
873checkint(i)
874end
874end
875−assert(c == 2)
875+assert(c == 0x2)
876−c=0
876+c=0x0
877;
877;
878−for i = 1, math.huge
878+for i = 0x1, math.huge
879do
879do
880−if i > 10 then
880+if i > 0xa then
881break
881break
882end
882end
883;
883;
884checkint(i)
884checkint(i)
885end
885end
886−assert(c == 10)
886+assert(c == 0xa)
887−c=0
887+c=0x0
888;
888;
889−for i = - 1, - math.huge, - 1
889+for i = - 0x1, - math.huge, - 0x1
890do
890do
891−if i < - 10 then
891+if i < - 0xa then
892break
892break
893end
893end
894;
894;
895checkint(i)
895checkint(i)
896end
896end
897−assert(c == 10)
897+assert(c == 0xa)
898for i = math.mininteger, - 1e101
898for i = math.mininteger, - 1e101
899do
899do
900assert(false)
900assert(false)
901end
901end
902−for i = math.maxinteger, 1e101, - 1
902+for i = math.maxinteger, 1e101, - 0x1
903do
903do
904assert(false)
904assert(false)
905end
905end
@@ -907,26 +907,26 @@ end
907do
907do
908local function checkfor
908local function checkfor
909(from,to,step,t)
909(from,to,step,t)
910−local c = 0
910+local c = 0x0
911for i = from, to, step
911for i = from, to, step
912do
912do
913−c=c + 1
913+c=c + 0x1
914assert(i == t[c])
914assert(i == t[c])
915end
915end
916assert(c == # t)
916assert(c == # t)
917end
917end
918local maxi = math.maxinteger
918local maxi = math.maxinteger
919local mini = math.mininteger
919local mini = math.mininteger
920−checkfor(mini,maxi,maxi,{mini,- 1,maxi - 1})
920+checkfor(mini,maxi,maxi,{mini,- 0x1,maxi - 0x1})
921−checkfor(mini,math.huge,maxi,{mini,- 1,maxi - 1})
921+checkfor(mini,math.huge,maxi,{mini,- 0x1,maxi - 0x1})
922−checkfor(maxi,mini,mini,{maxi,- 1})
922+checkfor(maxi,mini,mini,{maxi,- 0x1})
923−checkfor(maxi,mini,- maxi,{maxi,0,- maxi})
923+checkfor(maxi,mini,- maxi,{maxi,0x0,- maxi})
924−checkfor(maxi,- math.huge,mini,{maxi,- 1})
924+checkfor(maxi,- math.huge,mini,{maxi,- 0x1})
925−checkfor(maxi,mini,1,{})
925+checkfor(maxi,mini,0x1,{})
926−checkfor(mini,maxi,- 1,{})
926+checkfor(mini,maxi,- 0x1,{})
927−checkfor(maxi - 6,maxi,3,{maxi - 6,maxi - 3,maxi})
927+checkfor(maxi - 0x6,maxi,0x3,{maxi - 0x6,maxi - 0x3,maxi})
928−checkfor(mini + 4,mini,- 2,{mini + 4,mini + 2,mini})
928+checkfor(mini + 0x4,mini,- 0x2,{mini + 0x4,mini + 0x2,mini})
929−local step = maxi // 10
929+local step = maxi // 0xa
930local c = mini
930local c = mini
931for i = mini, maxi, step
931for i = mini, maxi, step
932do
932do
@@ -945,19 +945,19 @@ checkfor(mini,mini,maxi,{mini})
945checkfor(mini,mini,mini,{mini})
945checkfor(mini,mini,mini,{mini})
946end
946end
947checkerror("\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{73}\u{74}\u{65}\u{70}\u{20}\u{69}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}",function ()
947checkerror("\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{73}\u{74}\u{65}\u{70}\u{20}\u{69}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}",function ()
948−for i = 1, 10, 0
948+for i = 0x1, 0xa, 0x0
949do
949do
950
950
951end
951end
952end)
952end)
953checkerror("\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{73}\u{74}\u{65}\u{70}\u{20}\u{69}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}",function ()
953checkerror("\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{73}\u{74}\u{65}\u{70}\u{20}\u{69}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}",function ()
954−for i = 1, - 10, 0
954+for i = 0x1, - 0xa, 0x0
955do
955do
956
956
957end
957end
958end)
958end)
959checkerror("\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{73}\u{74}\u{65}\u{70}\u{20}\u{69}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}",function ()
959checkerror("\u{27}\u{66}\u{6f}\u{72}\u{27}\u{20}\u{73}\u{74}\u{65}\u{70}\u{20}\u{69}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}",function ()
960−for i = 1.0, - 10, 0.0
960+for i = 1.0, - 0xa, 0.0
961do
961do
962
962
963end
963end
@@ -967,25 +967,25 @@ local function f
967(n,p)
967(n,p)
968local t = {}
968local t = {}
969;
969;
970−for i = 1, p
970+for i = 0x1, p
971do
971do
972−t[i]=i * 10
972+t[i]=i * 0xa
973end
973end
974return function (_,n, ...)
974return function (_,n, ...)
975−assert(select("\u{23}",...) == 0)
975+assert(select("\u{23}",...) == 0x0)
976−if n > 0 then
976+if n > 0x0 then
977−n=n - 1
977+n=n - 0x1
978return n,table.unpack(t)
978return n,table.unpack(t)
979end
979end
980end,nil,n
980end,nil,n
981end
981end
982−local x = 0
982+local x = 0x0
983−for n,a,b,c,d in f(5,3)
983+for n,a,b,c,d in f(0x5,0x3)
984do
984do
985−x=x + 1
985+x=x + 0x1
986−assert(a == 10 and b == 20 and c == 30 and d == nil)
986+assert(a == 0xa and b == 0x14 and c == 0x1e and d == nil)
987end
987end
988−assert(x == 5)
988+assert(x == 0x5)
989a={}
989a={}
990do
990do
991local x,y,z = pairs(a)
991local x,y,z = pairs(a)
@@ -994,62 +994,62 @@ end
994local function foo
994local function foo
995(e,i)
995(e,i)
996assert(e == a)
996assert(e == a)
997−if i <= 10 then
997+if i <= 0xa then
998−return i + 1,i + 2
998+return i + 0x1,i + 0x2
999end
999end
1000end
1000end
1001local function foo1
1001local function foo1
1002(e,i)
1002(e,i)
1003−i=i + 1
1003+i=i + 0x1
1004assert(e == a)
1004assert(e == a)
1005if i <= e.n then
1005if i <= e.n then
1006return i,a[i]
1006return i,a[i]
1007end
1007end
1008end
1008end
1009setmetatable(a,{["\u{5f}\u{5f}\u{70}\u{61}\u{69}\u{72}\u{73}"] = function (x)
1009setmetatable(a,{["\u{5f}\u{5f}\u{70}\u{61}\u{69}\u{72}\u{73}"] = function (x)
1010−return foo,x,0
1010+return foo,x,0x0
1011end})
1011end})
1012−local i = 0
1012+local i = 0x0
1013for k,v in pairs(a)
1013for k,v in pairs(a)
1014do
1014do
1015−i=i + 1
1015+i=i + 0x1
1016−assert(k == i and v == k + 1)
1016+assert(k == i and v == k + 0x1)
1017end
1017end
1018−a.n=5
1018+a.n=0x5
1019−a[3]=30
1019+a[0x3]=0x1e
1020−a={["\u{6e}"] = 10}
1020+a={["\u{6e}"] = 0xa}
1021setmetatable(a,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k)
1021setmetatable(a,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k)
1022if k <= t.n then
1022if k <= t.n then
1023−return k * 10
1023+return k * 0xa
1024end
1024end
1025end})
1025end})
1026−i=0
1026+i=0x0
1027for k,v in ipairs(a)
1027for k,v in ipairs(a)
1028do
1028do
1029−i=i + 1
1029+i=i + 0x1
1030−assert(k == i and v == i * 10)
1030+assert(k == i and v == i * 0xa)
1031end
1031end
1032assert(i == a.n)
1032assert(i == a.n)
1033do
1033do
1034−local t = setmetatable({10,20,30},{["\u{5f}\u{5f}\u{70}\u{61}\u{69}\u{72}\u{73}"] = function (t)
1034+local t = setmetatable({0xa,0x14,0x1e},{["\u{5f}\u{5f}\u{70}\u{61}\u{69}\u{72}\u{73}"] = function (t)
1035local inc = coroutine.yield()
1035local inc = coroutine.yield()
1036return function (t,i)
1036return function (t,i)
1037−if i > 1 then
1037+if i > 0x1 then
1038return i - inc,t[i - inc]
1038return i - inc,t[i - inc]
1039else
1039else
1040return nil
1040return nil
1041end
1041end
1042−end,t,# t + 1
1042+end,t,# t + 0x1
1043end})
1043end})
1044local res = {}
1044local res = {}
1045local co = coroutine.wrap(function ()
1045local co = coroutine.wrap(function ()
1046for i,p in pairs(t)
1046for i,p in pairs(t)
1047do
1047do
1048−res[# res + 1]=p
1048+res[# res + 0x1]=p
1049end
1049end
1050end)
1050end)
1051co()
1051co()
1052−co(1)
1052+co(0x1)
1053−assert(res[1] == 30 and res[2] == 20 and res[3] == 10 and # res == 3)
1053+assert(res[0x1] == 0x1e and res[0x2] == 0x14 and res[0x3] == 0xa and # res == 0x3)
1054end
1054end
1055print("\u{4f}\u{4b}")
1055print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/pm.lua+86−86
@@ -12,25 +12,25 @@ return string.sub(s,i,e)
12end
12end
13end
13end
14local a,b = string.find("","")
14local a,b = string.find("","")
15−assert(a == 1 and b == 0)
15+assert(a == 0x1 and b == 0x0)
16;
16;
17a,b=string.find("\u{61}\u{6c}\u{6f}","")
17a,b=string.find("\u{61}\u{6c}\u{6f}","")
18−assert(a == 1 and b == 0)
18+assert(a == 0x1 and b == 0x0)
19−a,b=string.find("\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}","\u{61}",1)
19+a,b=string.find("\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}","\u{61}",0x1)
20−assert(a == 1 and b == 1)
20+assert(a == 0x1 and b == 0x1)
21−a,b=string.find("\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}","\u{61}\u{0}\u{6f}",2)
21+a,b=string.find("\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}","\u{61}\u{0}\u{6f}",0x2)
22−assert(a == 5 and b == 7)
22+assert(a == 0x5 and b == 0x7)
23−a,b=string.find("\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}","\u{61}\u{0}\u{6f}",9)
23+a,b=string.find("\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}\u{20}\u{61}\u{0}\u{6f}","\u{61}\u{0}\u{6f}",0x9)
24−assert(a == 9 and b == 11)
24+assert(a == 0x9 and b == 0xb)
25−a,b=string.find("\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{0}\u{61}\u{62}","\u{0}\u{61}\u{62}",2)
25+a,b=string.find("\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{0}\u{61}\u{62}","\u{0}\u{61}\u{62}",0x2)
26;
26;
27−assert(a == 9 and b == 11)
27+assert(a == 0x9 and b == 0xb)
28;
28;
29a,b=string.find("\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{0}\u{61}\u{62}","\u{62}")
29a,b=string.find("\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{0}\u{61}\u{62}","\u{62}")
30−assert(a == 11 and b == 11)
30+assert(a == 0xb and b == 0xb)
31assert(not string.find("\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{0}\u{61}\u{62}","\u{62}\u{0}"))
31assert(not string.find("\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{61}\u{0}\u{0}\u{61}\u{62}","\u{62}\u{0}"))
32assert(not string.find("","\u{0}"))
32assert(not string.find("","\u{0}"))
33−assert(string.find("\u{61}\u{6c}\u{6f}\u{31}\u{32}\u{33}\u{61}\u{6c}\u{6f}","\u{31}\u{32}") == 4)
33+assert(string.find("\u{61}\u{6c}\u{6f}\u{31}\u{32}\u{33}\u{61}\u{6c}\u{6f}","\u{31}\u{32}") == 0x4)
34assert(not string.find("\u{61}\u{6c}\u{6f}\u{31}\u{32}\u{33}\u{61}\u{6c}\u{6f}","\u{5e}\u{31}\u{32}"))
34assert(not string.find("\u{61}\u{6c}\u{6f}\u{31}\u{32}\u{33}\u{61}\u{6c}\u{6f}","\u{5e}\u{31}\u{32}"))
35assert(string.match("\u{61}\u{61}\u{61}\u{62}","\u{2e}\u{2a}\u{62}") == "\u{61}\u{61}\u{61}\u{62}")
35assert(string.match("\u{61}\u{61}\u{61}\u{62}","\u{2e}\u{2a}\u{62}") == "\u{61}\u{61}\u{61}\u{62}")
36assert(string.match("\u{61}\u{61}\u{61}","\u{2e}\u{2a}\u{61}") == "\u{61}\u{61}\u{61}")
36assert(string.match("\u{61}\u{61}\u{61}","\u{2e}\u{2a}\u{61}") == "\u{61}\u{61}\u{61}")
@@ -94,12 +94,12 @@ print("\u{2b}")
94local function f1
94local function f1
95(s,p)
95(s,p)
96p=string.gsub(p,"\u{25}\u{25}\u{28}\u{5b}\u{30}\u{2d}\u{39}\u{5d}\u{29}",function (s)
96p=string.gsub(p,"\u{25}\u{25}\u{28}\u{5b}\u{30}\u{2d}\u{39}\u{5d}\u{29}",function (s)
97−return "\u{25}" .. (tonumber(s) + 1)
97+return "\u{25}" .. (tonumber(s) + 0x1)
98end)
98end)
99−p=string.gsub(p,"\u{5e}\u{28}\u{5e}\u{3f}\u{29}","\u{25}\u{31}\u{28}\u{29}",1)
99+p=string.gsub(p,"\u{5e}\u{28}\u{5e}\u{3f}\u{29}","\u{25}\u{31}\u{28}\u{29}",0x1)
100−p=string.gsub(p,"\u{28}\u{24}\u{3f}\u{29}\u{24}","\u{28}\u{29}\u{25}\u{31}",1)
100+p=string.gsub(p,"\u{28}\u{24}\u{3f}\u{29}\u{24}","\u{28}\u{29}\u{25}\u{31}",0x1)
101local t = {string.match(s,p)}
101local t = {string.match(s,p)}
102−return string.sub(s,t[1],t[# t] - 1)
102+return string.sub(s,t[0x1],t[# t] - 0x1)
103end
103end
104assert(f1("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{78}\u{20}\u{31}\u{32}\u{33}\u{20}\u{62}\u{0}\u{6f}\u{20}\u{62}\u{0}\u{6f}","\u{28}\u{2e}\u{2e}\u{2a}\u{29}\u{20}\u{25}\u{31}") == "\u{62}\u{0}\u{6f}\u{20}\u{62}\u{0}\u{6f}")
104assert(f1("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{78}\u{20}\u{31}\u{32}\u{33}\u{20}\u{62}\u{0}\u{6f}\u{20}\u{62}\u{0}\u{6f}","\u{28}\u{2e}\u{2e}\u{2a}\u{29}\u{20}\u{25}\u{31}") == "\u{62}\u{0}\u{6f}\u{20}\u{62}\u{0}\u{6f}")
105assert(f1("\u{61}\u{78}\u{7a}\u{31}\u{32}\u{33}\u{3d}\u{20}\u{34}\u{3d}\u{20}\u{34}\u{20}\u{33}\u{34}","\u{28}\u{2e}\u{2b}\u{29}\u{3d}\u{28}\u{2e}\u{2a}\u{29}\u{3d}\u{25}\u{32}\u{20}\u{25}\u{31}") == "\u{33}\u{3d}\u{20}\u{34}\u{3d}\u{20}\u{34}\u{20}\u{33}")
105assert(f1("\u{61}\u{78}\u{7a}\u{31}\u{32}\u{33}\u{3d}\u{20}\u{34}\u{3d}\u{20}\u{34}\u{20}\u{33}\u{34}","\u{28}\u{2e}\u{2b}\u{29}\u{3d}\u{28}\u{2e}\u{2a}\u{29}\u{3d}\u{25}\u{32}\u{20}\u{25}\u{31}") == "\u{33}\u{3d}\u{20}\u{34}\u{3d}\u{20}\u{34}\u{20}\u{33}")
@@ -108,12 +108,12 @@ assert(not string.match("\u{3d}\u{3d}\u{3d}\u{3d}\u{3d}\u{3d}\u{3d}\u{3d}\u{3d}\
108local function range
108local function range
109(i,j)
109(i,j)
110if i <= j then
110if i <= j then
111−return i,range(i + 1,j)
111+return i,range(i + 0x1,j)
112end
112end
113end
113end
114−local abc = string.char(range(0,127)) .. string.char(range(128,255))
114+local abc = string.char(range(0x0,0x7f)) .. string.char(range(0x80,0xff))
115;
115;
116−assert(string.len(abc) == 256)
116+assert(string.len(abc) == 0x100)
117local function strset
117local function strset
118(p)
118(p)
119local res = {["\u{73}"] = ""}
119local res = {["\u{73}"] = ""}
@@ -123,7 +123,7 @@ end)
123return res.s
123return res.s
124end
124end
125;
125;
126−assert(string.len(strset("\u{5b}\u{c8}\u{2d}\u{d2}\u{5d}")) == 11)
126+assert(string.len(strset("\u{5b}\u{c8}\u{2d}\u{d2}\u{5d}")) == 0xb)
127assert(strset("\u{5b}\u{61}\u{2d}\u{7a}\u{5d}") == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}\u{6a}\u{6b}\u{6c}\u{6d}\u{6e}\u{6f}\u{70}\u{71}\u{72}\u{73}\u{74}\u{75}\u{76}\u{77}\u{78}\u{79}\u{7a}")
127assert(strset("\u{5b}\u{61}\u{2d}\u{7a}\u{5d}") == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}\u{6a}\u{6b}\u{6c}\u{6d}\u{6e}\u{6f}\u{70}\u{71}\u{72}\u{73}\u{74}\u{75}\u{76}\u{77}\u{78}\u{79}\u{7a}")
128assert(strset("\u{5b}\u{61}\u{2d}\u{7a}\u{25}\u{64}\u{5d}") == strset("\u{5b}\u{25}\u{64}\u{61}\u{2d}\u{75}\u{75}\u{2d}\u{7a}\u{5d}"))
128assert(strset("\u{5b}\u{61}\u{2d}\u{7a}\u{25}\u{64}\u{5d}") == strset("\u{5b}\u{25}\u{64}\u{61}\u{2d}\u{75}\u{75}\u{2d}\u{7a}\u{5d}"))
129assert(strset("\u{5b}\u{61}\u{2d}\u{5d}") == "\u{2d}\u{61}")
129assert(strset("\u{5b}\u{61}\u{2d}\u{5d}") == "\u{2d}\u{61}")
@@ -139,11 +139,11 @@ assert(string.match("\u{61}\u{6c}\u{6f}\u{20}\u{78}\u{79}\u{7a}\u{4b}","\u{28}\u
139assert(string.match("\u{32}\u{35}\u{34}\u{20}\u{4b}","\u{28}\u{25}\u{64}\u{2a}\u{29}\u{4b}") == "")
139assert(string.match("\u{32}\u{35}\u{34}\u{20}\u{4b}","\u{28}\u{25}\u{64}\u{2a}\u{29}\u{4b}") == "")
140assert(string.match("\u{61}\u{6c}\u{6f}\u{20}","\u{28}\u{25}\u{77}\u{2a}\u{29}\u{24}") == "")
140assert(string.match("\u{61}\u{6c}\u{6f}\u{20}","\u{28}\u{25}\u{77}\u{2a}\u{29}\u{24}") == "")
141assert(not string.match("\u{61}\u{6c}\u{6f}\u{20}","\u{28}\u{25}\u{77}\u{2b}\u{29}\u{24}"))
141assert(not string.match("\u{61}\u{6c}\u{6f}\u{20}","\u{28}\u{25}\u{77}\u{2b}\u{29}\u{24}"))
142−assert(string.find("\u{28}\u{c3}\u{a1}\u{6c}\u{6f}\u{29}","\u{25}\u{28}\u{c3}\u{a1}") == 1)
142+assert(string.find("\u{28}\u{c3}\u{a1}\u{6c}\u{6f}\u{29}","\u{25}\u{28}\u{c3}\u{a1}") == 0x1)
143local a,b,c,d,e = string.match("\u{c3}\u{a2}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}",PU("\u{5e}\u{28}\u{28}\u{28}\u{2e}\u{29}\u{2e}\u{29}\u{2e}\u{20}\u{28}\u{25}\u{77}\u{2a}\u{29}\u{29}\u{24}"))
143local a,b,c,d,e = string.match("\u{c3}\u{a2}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}",PU("\u{5e}\u{28}\u{28}\u{28}\u{2e}\u{29}\u{2e}\u{29}\u{2e}\u{20}\u{28}\u{25}\u{77}\u{2a}\u{29}\u{29}\u{24}"))
144assert(a == "\u{c3}\u{a2}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}" and b == "\u{c3}\u{a2}\u{6c}" and c == "\u{c3}\u{a2}" and d == "\u{61}\u{6c}\u{6f}" and e == nil)
144assert(a == "\u{c3}\u{a2}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}" and b == "\u{c3}\u{a2}\u{6c}" and c == "\u{c3}\u{a2}" and d == "\u{61}\u{6c}\u{6f}" and e == nil)
145a,b,c,d=string.match("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{28}\u{2e}\u{2b}\u{28}\u{2e}\u{3f}\u{29}\u{28}\u{29}\u{29}")
145a,b,c,d=string.match("\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{28}\u{2e}\u{2b}\u{28}\u{2e}\u{3f}\u{29}\u{28}\u{29}\u{29}")
146−assert(a == "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}" and b == "" and c == 11 and d == nil)
146+assert(a == "\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}" and b == "" and c == 0xb and d == nil)
147print("\u{2b}")
147print("\u{2b}")
148assert(string.gsub("\u{c3}\u{bc}\u{6c}\u{6f}\u{20}\u{c3}\u{bc}\u{6c}\u{6f}","\u{c3}\u{bc}","\u{78}") == "\u{78}\u{6c}\u{6f}\u{20}\u{78}\u{6c}\u{6f}")
148assert(string.gsub("\u{c3}\u{bc}\u{6c}\u{6f}\u{20}\u{c3}\u{bc}\u{6c}\u{6f}","\u{c3}\u{bc}","\u{78}") == "\u{78}\u{6c}\u{6f}\u{20}\u{78}\u{6c}\u{6f}")
149assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{c3}\u{ba}\u{6c}\u{6f}\u{20}\u{20}","\u{20}\u{2b}\u{24}","") == "\u{61}\u{6c}\u{6f}\u{20}\u{c3}\u{ba}\u{6c}\u{6f}")
149assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{c3}\u{ba}\u{6c}\u{6f}\u{20}\u{20}","\u{20}\u{2b}\u{24}","") == "\u{61}\u{6c}\u{6f}\u{20}\u{c3}\u{ba}\u{6c}\u{6f}")
@@ -151,9 +151,9 @@ assert(string.gsub("\u{20}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}\u{20}
151assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{20}\u{a}\u{20}\u{31}\u{32}\u{33}\u{a}\u{20}","\u{25}\u{73}\u{2b}","\u{20}") == "\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{31}\u{32}\u{33}\u{20}")
151assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{20}\u{a}\u{20}\u{31}\u{32}\u{33}\u{a}\u{20}","\u{25}\u{73}\u{2b}","\u{20}") == "\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{31}\u{32}\u{33}\u{20}")
152local t = "\u{61}\u{62}\u{c3}\u{a7}\u{20}\u{64}"
152local t = "\u{61}\u{62}\u{c3}\u{a7}\u{20}\u{64}"
153a,b=string.gsub(t,PU("\u{28}\u{2e}\u{29}"),"\u{25}\u{31}\u{40}")
153a,b=string.gsub(t,PU("\u{28}\u{2e}\u{29}"),"\u{25}\u{31}\u{40}")
154−assert(a == "\u{61}\u{40}\u{62}\u{40}\u{c3}\u{a7}\u{40}\u{20}\u{40}\u{64}\u{40}" and b == 5)
154+assert(a == "\u{61}\u{40}\u{62}\u{40}\u{c3}\u{a7}\u{40}\u{20}\u{40}\u{64}\u{40}" and b == 0x5)
155−a,b=string.gsub("\u{61}\u{62}\u{c3}\u{a7}\u{64}",PU("\u{28}\u{2e}\u{29}"),"\u{25}\u{30}\u{40}",2)
155+a,b=string.gsub("\u{61}\u{62}\u{c3}\u{a7}\u{64}",PU("\u{28}\u{2e}\u{29}"),"\u{25}\u{30}\u{40}",0x2)
156−assert(a == "\u{61}\u{40}\u{62}\u{40}\u{c3}\u{a7}\u{64}" and b == 2)
156+assert(a == "\u{61}\u{40}\u{62}\u{40}\u{c3}\u{a7}\u{64}" and b == 0x2)
157assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}","\u{28}\u{29}\u{5b}\u{61}\u{6c}\u{5d}","\u{25}\u{31}") == "\u{31}\u{32}\u{6f}\u{20}\u{35}\u{36}\u{6f}")
157assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}","\u{28}\u{29}\u{5b}\u{61}\u{6c}\u{5d}","\u{25}\u{31}") == "\u{31}\u{32}\u{6f}\u{20}\u{35}\u{36}\u{6f}")
158assert(string.gsub("\u{61}\u{62}\u{63}\u{3d}\u{78}\u{79}\u{7a}","\u{28}\u{25}\u{77}\u{2a}\u{29}\u{28}\u{25}\u{70}\u{29}\u{28}\u{25}\u{77}\u{2b}\u{29}","\u{25}\u{33}\u{25}\u{32}\u{25}\u{31}\u{2d}\u{25}\u{30}") == "\u{78}\u{79}\u{7a}\u{3d}\u{61}\u{62}\u{63}\u{2d}\u{61}\u{62}\u{63}\u{3d}\u{78}\u{79}\u{7a}")
158assert(string.gsub("\u{61}\u{62}\u{63}\u{3d}\u{78}\u{79}\u{7a}","\u{28}\u{25}\u{77}\u{2a}\u{29}\u{28}\u{25}\u{70}\u{29}\u{28}\u{25}\u{77}\u{2b}\u{29}","\u{25}\u{33}\u{25}\u{32}\u{25}\u{31}\u{2d}\u{25}\u{30}") == "\u{78}\u{79}\u{7a}\u{3d}\u{61}\u{62}\u{63}\u{2d}\u{61}\u{62}\u{63}\u{3d}\u{78}\u{79}\u{7a}")
159assert(string.gsub("\u{61}\u{62}\u{63}","\u{25}\u{77}","\u{25}\u{31}\u{25}\u{30}") == "\u{61}\u{61}\u{62}\u{62}\u{63}\u{63}")
159assert(string.gsub("\u{61}\u{62}\u{63}","\u{25}\u{77}","\u{25}\u{31}\u{25}\u{30}") == "\u{61}\u{61}\u{62}\u{62}\u{63}\u{63}")
@@ -166,10 +166,10 @@ do
166assert(string.gsub("\u{61}\u{20}\u{62}\u{20}\u{63}\u{64}","\u{20}\u{2a}","\u{2d}") == "\u{2d}\u{61}\u{2d}\u{62}\u{2d}\u{63}\u{2d}\u{64}\u{2d}")
166assert(string.gsub("\u{61}\u{20}\u{62}\u{20}\u{63}\u{64}","\u{20}\u{2a}","\u{2d}") == "\u{2d}\u{61}\u{2d}\u{62}\u{2d}\u{63}\u{2d}\u{64}\u{2d}")
167local res = ""
167local res = ""
168local sub = "\u{61}\u{20}\u{20}\u{a}\u{62}\u{63}\u{9}\u{9}\u{64}"
168local sub = "\u{61}\u{20}\u{20}\u{a}\u{62}\u{63}\u{9}\u{9}\u{64}"
169−local i = 1
169+local i = 0x1
170for p,e in string.gmatch(sub,"\u{28}\u{29}\u{25}\u{73}\u{2a}\u{28}\u{29}")
170for p,e in string.gmatch(sub,"\u{28}\u{29}\u{25}\u{73}\u{2a}\u{28}\u{29}")
171do
171do
172−res=res .. string.sub(sub,i,p - 1) .. "\u{2d}"
172+res=res .. string.sub(sub,i,p - 0x1) .. "\u{2d}"
173i=e
173i=e
174end
174end
175assert(res == "\u{2d}\u{61}\u{2d}\u{62}\u{2d}\u{63}\u{2d}\u{64}\u{2d}")
175assert(res == "\u{2d}\u{61}\u{2d}\u{62}\u{2d}\u{63}\u{2d}\u{64}\u{2d}")
@@ -206,7 +206,7 @@ assert(string.len(w) == b - a)
206t[a]=b - a
206t[a]=b - a
207;
207;
208end)
208end)
209−assert(s == r and t[1] == 1 and t[3] == 3 and t[7] == 4 and t[13] == 4)
209+assert(s == r and t[0x1] == 0x1 and t[0x3] == 0x3 and t[0x7] == 0x4 and t[0xd] == 0x4)
210local function isbalanced
210local function isbalanced
211(s)
211(s)
212return not string.find(string.gsub(s,"\u{25}\u{62}\u{28}\u{29}",""),"\u{5b}\u{28}\u{29}\u{5d}")
212return not string.find(string.gsub(s,"\u{25}\u{62}\u{28}\u{29}",""),"\u{5b}\u{28}\u{29}\u{5d}")
@@ -214,26 +214,26 @@ end
214assert(isbalanced("\u{28}\u{39}\u{20}\u{28}\u{28}\u{38}\u{29}\u{29}\u{28}\u{0}\u{29}\u{20}\u{37}\u{29}\u{20}\u{0}\u{0}\u{20}\u{61}\u{20}\u{62}\u{20}\u{28}\u{29}\u{28}\u{63}\u{29}\u{28}\u{29}\u{20}\u{61}"))
214assert(isbalanced("\u{28}\u{39}\u{20}\u{28}\u{28}\u{38}\u{29}\u{29}\u{28}\u{0}\u{29}\u{20}\u{37}\u{29}\u{20}\u{0}\u{0}\u{20}\u{61}\u{20}\u{62}\u{20}\u{28}\u{29}\u{28}\u{63}\u{29}\u{28}\u{29}\u{20}\u{61}"))
215assert(not isbalanced("\u{28}\u{39}\u{20}\u{28}\u{28}\u{38}\u{29}\u{20}\u{37}\u{29}\u{20}\u{61}\u{20}\u{62}\u{20}\u{28}\u{0}\u{20}\u{63}\u{29}\u{20}\u{61}"))
215assert(not isbalanced("\u{28}\u{39}\u{20}\u{28}\u{28}\u{38}\u{29}\u{20}\u{37}\u{29}\u{20}\u{61}\u{20}\u{62}\u{20}\u{28}\u{0}\u{20}\u{63}\u{29}\u{20}\u{61}"))
216assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{27}\u{6f}\u{69}\u{27}\u{20}\u{61}\u{6c}\u{6f}","\u{25}\u{62}\u{27}\u{27}","\u{22}") == "\u{61}\u{6c}\u{6f}\u{20}\u{22}\u{20}\u{61}\u{6c}\u{6f}")
216assert(string.gsub("\u{61}\u{6c}\u{6f}\u{20}\u{27}\u{6f}\u{69}\u{27}\u{20}\u{61}\u{6c}\u{6f}","\u{25}\u{62}\u{27}\u{27}","\u{22}") == "\u{61}\u{6c}\u{6f}\u{20}\u{22}\u{20}\u{61}\u{6c}\u{6f}")
217−local t = {"\u{61}\u{70}\u{70}\u{6c}\u{65}","\u{6f}\u{72}\u{61}\u{6e}\u{67}\u{65}","\u{6c}\u{69}\u{6d}\u{65}",["\u{6e}"] = 0}
217+local t = {"\u{61}\u{70}\u{70}\u{6c}\u{65}","\u{6f}\u{72}\u{61}\u{6e}\u{67}\u{65}","\u{6c}\u{69}\u{6d}\u{65}",["\u{6e}"] = 0x0}
218assert(string.gsub("\u{78}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{78}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{78}","\u{78}",function ()
218assert(string.gsub("\u{78}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{78}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{78}","\u{78}",function ()
219−t.n=t.n + 1
219+t.n=t.n + 0x1
220;
220;
221return t[t.n]
221return t[t.n]
222end) == "\u{61}\u{70}\u{70}\u{6c}\u{65}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6f}\u{72}\u{61}\u{6e}\u{67}\u{65}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6d}\u{65}")
222end) == "\u{61}\u{70}\u{70}\u{6c}\u{65}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6f}\u{72}\u{61}\u{6e}\u{67}\u{65}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6c}\u{69}\u{6d}\u{65}")
223−t={["\u{6e}"] = 0}
223+t={["\u{6e}"] = 0x0}
224string.gsub("\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}","\u{25}\u{77}\u{25}\u{77}\u{2a}",function (w)
224string.gsub("\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}","\u{25}\u{77}\u{25}\u{77}\u{2a}",function (w)
225−t.n=t.n + 1
225+t.n=t.n + 0x1
226;
226;
227t[t.n]=w
227t[t.n]=w
228end)
228end)
229−assert(t[1] == "\u{66}\u{69}\u{72}\u{73}\u{74}" and t[2] == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}" and t[3] == "\u{77}\u{6f}\u{72}\u{64}" and t.n == 3)
229+assert(t[0x1] == "\u{66}\u{69}\u{72}\u{73}\u{74}" and t[0x2] == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}" and t[0x3] == "\u{77}\u{6f}\u{72}\u{64}" and t.n == 0x3)
230−t={["\u{6e}"] = 0}
230+t={["\u{6e}"] = 0x0}
231assert(string.gsub("\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}","\u{25}\u{77}\u{2b}",function (w)
231assert(string.gsub("\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}","\u{25}\u{77}\u{2b}",function (w)
232−t.n=t.n + 1
232+t.n=t.n + 0x1
233;
233;
234t[t.n]=w
234t[t.n]=w
235−end,2) == "\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}")
235+end,0x2) == "\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}")
236−assert(t[1] == "\u{66}\u{69}\u{72}\u{73}\u{74}" and t[2] == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}" and t[3] == undef)
236+assert(t[0x1] == "\u{66}\u{69}\u{72}\u{73}\u{74}" and t[0x2] == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}" and t[0x3] == undef)
237checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{25}\u{28}\u{61}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{25}\u{29}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{2e}",{["\u{61}"] = {}})
237checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{72}\u{65}\u{70}\u{6c}\u{61}\u{63}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{25}\u{28}\u{61}\u{20}\u{74}\u{61}\u{62}\u{6c}\u{65}\u{25}\u{29}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{2e}",{["\u{61}"] = {}})
238checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{61}\u{70}\u{74}\u{75}\u{72}\u{65}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{25}\u{25}\u{32}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{2e}","\u{25}\u{32}")
238checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{61}\u{70}\u{74}\u{75}\u{72}\u{65}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{25}\u{25}\u{32}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{2e}","\u{25}\u{32}")
239checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{61}\u{70}\u{74}\u{75}\u{72}\u{65}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{25}\u{25}\u{30}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{28}\u{25}\u{30}\u{29}","\u{61}")
239checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{61}\u{70}\u{74}\u{75}\u{72}\u{65}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{25}\u{25}\u{30}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{28}\u{25}\u{30}\u{29}","\u{61}")
@@ -241,11 +241,11 @@ checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{61}\u{70}\u
241checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{75}\u{73}\u{65}\u{20}\u{6f}\u{66}\u{20}\u{27}\u{25}\u{25}\u{27}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{2e}","\u{25}\u{78}")
241checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{75}\u{73}\u{65}\u{20}\u{6f}\u{66}\u{20}\u{27}\u{25}\u{25}\u{27}",string.gsub,"\u{61}\u{6c}\u{6f}","\u{2e}","\u{25}\u{78}")
242if not _soft then
242if not _soft then
243print("\u{62}\u{69}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}")
243print("\u{62}\u{69}\u{67}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}")
244−local a = string.rep("\u{61}",300000)
244+local a = string.rep("\u{61}",0x493e0)
245assert(string.find(a,"\u{5e}\u{61}\u{2a}\u{2e}\u{3f}\u{24}"))
245assert(string.find(a,"\u{5e}\u{61}\u{2a}\u{2e}\u{3f}\u{24}"))
246assert(not string.find(a,"\u{5e}\u{61}\u{2a}\u{2e}\u{3f}\u{62}\u{24}"))
246assert(not string.find(a,"\u{5e}\u{61}\u{2a}\u{2e}\u{3f}\u{62}\u{24}"))
247assert(string.find(a,"\u{5e}\u{61}\u{2d}\u{2e}\u{3f}\u{24}"))
247assert(string.find(a,"\u{5e}\u{61}\u{2d}\u{2e}\u{3f}\u{24}"))
248−a=string.rep("\u{61}",10000) .. string.rep("\u{62}",10000)
248+a=string.rep("\u{61}",0x2710) .. string.rep("\u{62}",0x2710)
249assert(not pcall(string.gsub,a,"\u{62}"))
249assert(not pcall(string.gsub,a,"\u{62}"))
250end
250end
251local function rev
251local function rev
@@ -267,66 +267,66 @@ setmetatable(t,{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,s)
267return string.upper(s)
267return string.upper(s)
268end})
268end})
269assert(string.gsub("\u{61}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{62}\u{20}\u{68}\u{69}","\u{25}\u{77}\u{25}\u{77}\u{2b}",t) == "\u{61}\u{20}\u{41}\u{4c}\u{4f}\u{20}\u{62}\u{20}\u{48}\u{49}")
269assert(string.gsub("\u{61}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{62}\u{20}\u{68}\u{69}","\u{25}\u{77}\u{25}\u{77}\u{2b}",t) == "\u{61}\u{20}\u{41}\u{4c}\u{4f}\u{20}\u{62}\u{20}\u{48}\u{49}")
270−local a = 0
270+local a = 0x0
271for i in string.gmatch("\u{61}\u{62}\u{63}\u{64}\u{65}","\u{28}\u{29}")
271for i in string.gmatch("\u{61}\u{62}\u{63}\u{64}\u{65}","\u{28}\u{29}")
272do
272do
273−assert(i == a + 1)
273+assert(i == a + 0x1)
274;
274;
275a=i
275a=i
276end
276end
277−assert(a == 6)
277+assert(a == 0x6)
278−t={["\u{6e}"] = 0}
278+t={["\u{6e}"] = 0x0}
279for w in string.gmatch("\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}","\u{25}\u{77}\u{2b}")
279for w in string.gmatch("\u{66}\u{69}\u{72}\u{73}\u{74}\u{20}\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}\u{20}\u{77}\u{6f}\u{72}\u{64}","\u{25}\u{77}\u{2b}")
280do
280do
281−t.n=t.n + 1
281+t.n=t.n + 0x1
282;
282;
283t[t.n]=w
283t[t.n]=w
284end
284end
285−assert(t[1] == "\u{66}\u{69}\u{72}\u{73}\u{74}" and t[2] == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}" and t[3] == "\u{77}\u{6f}\u{72}\u{64}")
285+assert(t[0x1] == "\u{66}\u{69}\u{72}\u{73}\u{74}" and t[0x2] == "\u{73}\u{65}\u{63}\u{6f}\u{6e}\u{64}" and t[0x3] == "\u{77}\u{6f}\u{72}\u{64}")
286−t={3,6,9}
286+t={0x3,0x6,0x9}
287for i in string.gmatch("\u{78}\u{75}\u{78}\u{78}\u{20}\u{75}\u{75}\u{20}\u{70}\u{70}\u{61}\u{72}\u{20}\u{72}","\u{28}\u{29}\u{28}\u{2e}\u{29}\u{25}\u{32}")
287for i in string.gmatch("\u{78}\u{75}\u{78}\u{78}\u{20}\u{75}\u{75}\u{20}\u{70}\u{70}\u{61}\u{72}\u{20}\u{72}","\u{28}\u{29}\u{28}\u{2e}\u{29}\u{25}\u{32}")
288do
288do
289−assert(i == table.remove(t,1))
289+assert(i == table.remove(t,0x1))
290end
290end
291−assert(# t == 0)
291+assert(# t == 0x0)
292t={}
292t={}
293for i,j in string.gmatch("\u{31}\u{33}\u{20}\u{31}\u{34}\u{20}\u{31}\u{30}\u{20}\u{3d}\u{20}\u{31}\u{31}\u{2c}\u{20}\u{31}\u{35}\u{3d}\u{20}\u{31}\u{36}\u{2c}\u{20}\u{32}\u{32}\u{3d}\u{32}\u{33}","\u{28}\u{25}\u{64}\u{2b}\u{29}\u{25}\u{73}\u{2a}\u{3d}\u{25}\u{73}\u{2a}\u{28}\u{25}\u{64}\u{2b}\u{29}")
293for i,j in string.gmatch("\u{31}\u{33}\u{20}\u{31}\u{34}\u{20}\u{31}\u{30}\u{20}\u{3d}\u{20}\u{31}\u{31}\u{2c}\u{20}\u{31}\u{35}\u{3d}\u{20}\u{31}\u{36}\u{2c}\u{20}\u{32}\u{32}\u{3d}\u{32}\u{33}","\u{28}\u{25}\u{64}\u{2b}\u{29}\u{25}\u{73}\u{2a}\u{3d}\u{25}\u{73}\u{2a}\u{28}\u{25}\u{64}\u{2b}\u{29}")
294do
294do
295t[tonumber(i)]=tonumber(j)
295t[tonumber(i)]=tonumber(j)
296end
296end
297−a=0
297+a=0x0
298for k,v in pairs(t)
298for k,v in pairs(t)
299do
299do
300−assert(k + 1 == v + 0)
300+assert(k + 0x1 == v + 0x0)
301;
301;
302−a=a + 1
302+a=a + 0x1
303end
303end
304−assert(a == 3)
304+assert(a == 0x3)
305do
305do
306−local s = 0
306+local s = 0x0
307−for k in string.gmatch("\u{31}\u{30}\u{20}\u{32}\u{30}\u{20}\u{33}\u{30}","\u{25}\u{64}\u{2b}",3)
307+for k in string.gmatch("\u{31}\u{30}\u{20}\u{32}\u{30}\u{20}\u{33}\u{30}","\u{25}\u{64}\u{2b}",0x3)
308do
308do
309s=s + tonumber(k)
309s=s + tonumber(k)
310end
310end
311−assert(s == 50)
311+assert(s == 0x32)
312−s=0
312+s=0x0
313−for k in string.gmatch("\u{31}\u{31}\u{20}\u{32}\u{31}\u{20}\u{33}\u{31}","\u{25}\u{64}\u{2b}",- 4)
313+for k in string.gmatch("\u{31}\u{31}\u{20}\u{32}\u{31}\u{20}\u{33}\u{31}","\u{25}\u{64}\u{2b}",- 0x4)
314do
314do
315s=s + tonumber(k)
315s=s + tonumber(k)
316end
316end
317−assert(s == 32)
317+assert(s == 0x20)
318−s=0
318+s=0x0
319−for k in string.gmatch("\u{31}\u{31}\u{20}\u{32}\u{31}\u{20}\u{33}\u{31}","\u{25}\u{77}\u{2a}",9)
319+for k in string.gmatch("\u{31}\u{31}\u{20}\u{32}\u{31}\u{20}\u{33}\u{31}","\u{25}\u{77}\u{2a}",0x9)
320do
320do
321−s=s + 1
321+s=s + 0x1
322end
322end
323−assert(s == 1)
323+assert(s == 0x1)
324−s=0
324+s=0x0
325−for k in string.gmatch("\u{31}\u{31}\u{20}\u{32}\u{31}\u{20}\u{33}\u{31}","\u{25}\u{77}\u{2a}",10)
325+for k in string.gmatch("\u{31}\u{31}\u{20}\u{32}\u{31}\u{20}\u{33}\u{31}","\u{25}\u{77}\u{2a}",0xa)
326do
326do
327−s=s + 1
327+s=s + 0x1
328end
328end
329−assert(s == 0)
329+assert(s == 0x0)
330end
330end
331assert(string.gsub("\u{61}\u{61}\u{61}\u{20}\u{61}\u{61}\u{20}\u{61}\u{20}\u{61}\u{61}\u{61}\u{20}\u{61}","\u{25}\u{66}\u{5b}\u{25}\u{77}\u{5d}\u{61}","\u{78}") == "\u{78}\u{61}\u{61}\u{20}\u{78}\u{61}\u{20}\u{78}\u{20}\u{78}\u{61}\u{61}\u{20}\u{78}")
331assert(string.gsub("\u{61}\u{61}\u{61}\u{20}\u{61}\u{61}\u{20}\u{61}\u{20}\u{61}\u{61}\u{61}\u{20}\u{61}","\u{25}\u{66}\u{5b}\u{25}\u{77}\u{5d}\u{61}","\u{78}") == "\u{78}\u{61}\u{61}\u{20}\u{78}\u{61}\u{20}\u{78}\u{20}\u{78}\u{61}\u{61}\u{20}\u{78}")
332assert(string.gsub("\u{5b}\u{5b}\u{5d}\u{5d}\u{20}\u{5b}\u{5d}\u{5b}\u{5d}\u{20}\u{5b}\u{5b}\u{5b}\u{5b}","\u{25}\u{66}\u{5b}\u{5b}\u{5d}\u{2e}","\u{78}") == "\u{78}\u{5b}\u{5d}\u{5d}\u{20}\u{78}\u{5d}\u{78}\u{5d}\u{20}\u{78}\u{5b}\u{5b}\u{5b}")
332assert(string.gsub("\u{5b}\u{5b}\u{5d}\u{5d}\u{20}\u{5b}\u{5d}\u{5b}\u{5d}\u{20}\u{5b}\u{5b}\u{5b}\u{5b}","\u{25}\u{66}\u{5b}\u{5b}\u{5d}\u{2e}","\u{78}") == "\u{78}\u{5b}\u{5d}\u{5d}\u{20}\u{78}\u{5d}\u{78}\u{5d}\u{20}\u{78}\u{5b}\u{5b}\u{5b}")
@@ -334,23 +334,23 @@ assert(string.gsub("\u{30}\u{31}\u{61}\u{62}\u{63}\u{34}\u{35}\u{64}\u{65}\u{33}
334assert(string.gsub("\u{30}\u{31}\u{61}\u{62}\u{63}\u{34}\u{35}\u{20}\u{64}\u{65}\u{33}\u{78}","\u{25}\u{66}\u{5b}\u{25}\u{44}\u{5d}\u{25}\u{77}","\u{2e}") == "\u{30}\u{31}\u{2e}\u{62}\u{63}\u{34}\u{35}\u{20}\u{64}\u{65}\u{33}\u{2e}")
334assert(string.gsub("\u{30}\u{31}\u{61}\u{62}\u{63}\u{34}\u{35}\u{20}\u{64}\u{65}\u{33}\u{78}","\u{25}\u{66}\u{5b}\u{25}\u{44}\u{5d}\u{25}\u{77}","\u{2e}") == "\u{30}\u{31}\u{2e}\u{62}\u{63}\u{34}\u{35}\u{20}\u{64}\u{65}\u{33}\u{2e}")
335assert(string.gsub("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}","\u{25}\u{66}\u{5b}\u{1}\u{2d}\u{ff}\u{5d}\u{25}\u{77}","\u{2e}") == "\u{2e}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
335assert(string.gsub("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}","\u{25}\u{66}\u{5b}\u{1}\u{2d}\u{ff}\u{5d}\u{25}\u{77}","\u{2e}") == "\u{2e}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}")
336assert(string.gsub("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}","\u{25}\u{66}\u{5b}\u{5e}\u{1}\u{2d}\u{ff}\u{5d}","\u{2e}") == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{2e}")
336assert(string.gsub("\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}","\u{25}\u{66}\u{5b}\u{5e}\u{1}\u{2d}\u{ff}\u{5d}","\u{2e}") == "\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{2e}")
337−assert(string.find("\u{61}","\u{25}\u{66}\u{5b}\u{61}\u{5d}") == 1)
337+assert(string.find("\u{61}","\u{25}\u{66}\u{5b}\u{61}\u{5d}") == 0x1)
338−assert(string.find("\u{61}","\u{25}\u{66}\u{5b}\u{5e}\u{25}\u{7a}\u{5d}") == 1)
338+assert(string.find("\u{61}","\u{25}\u{66}\u{5b}\u{5e}\u{25}\u{7a}\u{5d}") == 0x1)
339−assert(string.find("\u{61}","\u{25}\u{66}\u{5b}\u{5e}\u{25}\u{6c}\u{5d}") == 2)
339+assert(string.find("\u{61}","\u{25}\u{66}\u{5b}\u{5e}\u{25}\u{6c}\u{5d}") == 0x2)
340−assert(string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{61}\u{25}\u{7a}\u{5d}") == 3)
340+assert(string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{61}\u{25}\u{7a}\u{5d}") == 0x3)
341−assert(string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{25}\u{7a}\u{5d}") == 4)
341+assert(string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{25}\u{7a}\u{5d}") == 0x4)
342assert(not string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{25}\u{6c}\u{25}\u{7a}\u{5d}"))
342assert(not string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{25}\u{6c}\u{25}\u{7a}\u{5d}"))
343assert(not string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{5e}\u{25}\u{6c}\u{25}\u{7a}\u{5d}"))
343assert(not string.find("\u{61}\u{62}\u{61}","\u{25}\u{66}\u{5b}\u{5e}\u{25}\u{6c}\u{25}\u{7a}\u{5d}"))
344local i,e = string.find("\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6c}\u{6f}","\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{73}\u{5d}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}")
344local i,e = string.find("\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6c}\u{6f}","\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{73}\u{5d}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}")
345−assert(i == 2 and e == 5)
345+assert(i == 0x2 and e == 0x5)
346local k = string.match("\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6c}\u{6f}","\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}\u{28}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{73}\u{5d}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}\u{29}")
346local k = string.match("\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6c}\u{6f}","\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}\u{28}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{73}\u{5d}\u{2e}\u{2d}\u{25}\u{66}\u{5b}\u{25}\u{53}\u{5d}\u{29}")
347assert(k == "\u{61}\u{6c}\u{6f}\u{20}")
347assert(k == "\u{61}\u{6c}\u{6f}\u{20}")
348−local a = {1,5,9,14,17}
348+local a = {0x1,0x5,0x9,0xe,0x11}
349for k in string.gmatch("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{74}\u{68}\u{30}\u{32}\u{20}\u{69}\u{73}\u{20}\u{31}\u{68}\u{61}\u{74}","\u{28}\u{29}\u{25}\u{66}\u{5b}\u{25}\u{77}\u{25}\u{64}\u{5d}")
349for k in string.gmatch("\u{61}\u{6c}\u{6f}\u{20}\u{61}\u{6c}\u{6f}\u{20}\u{74}\u{68}\u{30}\u{32}\u{20}\u{69}\u{73}\u{20}\u{31}\u{68}\u{61}\u{74}","\u{28}\u{29}\u{25}\u{66}\u{5b}\u{25}\u{77}\u{25}\u{64}\u{5d}")
350do
350do
351−assert(table.remove(a,1) == k)
351+assert(table.remove(a,0x1) == k)
352end
352end
353−assert(# a == 0)
353+assert(# a == 0x0)
354local function malform
354local function malform
355(p,m)
355(p,m)
356m=m or "\u{6d}\u{61}\u{6c}\u{66}\u{6f}\u{72}\u{6d}\u{65}\u{64}"
356m=m or "\u{6d}\u{61}\u{6c}\u{66}\u{6f}\u{72}\u{6d}\u{65}\u{64}"
@@ -370,35 +370,35 @@ malform("\u{25}")
370malform("\u{25}\u{66}","\u{6d}\u{69}\u{73}\u{73}\u{69}\u{6e}\u{67}")
370malform("\u{25}\u{66}","\u{6d}\u{69}\u{73}\u{73}\u{69}\u{6e}\u{67}")
371assert(string.match("\u{61}\u{62}\u{0}\u{1}\u{2}\u{63}","\u{5b}\u{0}\u{2d}\u{2}\u{5d}\u{2b}") == "\u{0}\u{1}\u{2}")
371assert(string.match("\u{61}\u{62}\u{0}\u{1}\u{2}\u{63}","\u{5b}\u{0}\u{2d}\u{2}\u{5d}\u{2b}") == "\u{0}\u{1}\u{2}")
372assert(string.match("\u{61}\u{62}\u{0}\u{1}\u{2}\u{63}","\u{5b}\u{0}\u{2d}\u{0}\u{5d}\u{2b}") == "\u{0}")
372assert(string.match("\u{61}\u{62}\u{0}\u{1}\u{2}\u{63}","\u{5b}\u{0}\u{2d}\u{0}\u{5d}\u{2b}") == "\u{0}")
373−assert(string.find("\u{62}\u{24}\u{61}","\u{24}\u{0}\u{3f}") == 2)
373+assert(string.find("\u{62}\u{24}\u{61}","\u{24}\u{0}\u{3f}") == 0x2)
374−assert(string.find("\u{61}\u{62}\u{63}\u{0}\u{65}\u{66}\u{67}","\u{25}\u{0}") == 4)
374+assert(string.find("\u{61}\u{62}\u{63}\u{0}\u{65}\u{66}\u{67}","\u{25}\u{0}") == 0x4)
375assert(string.match("\u{61}\u{62}\u{63}\u{0}\u{65}\u{66}\u{67}\u{0}\u{1}\u{65}\u{1}\u{67}","\u{25}\u{62}\u{0}\u{1}") == "\u{0}\u{65}\u{66}\u{67}\u{0}\u{1}\u{65}\u{1}")
375assert(string.match("\u{61}\u{62}\u{63}\u{0}\u{65}\u{66}\u{67}\u{0}\u{1}\u{65}\u{1}\u{67}","\u{25}\u{62}\u{0}\u{1}") == "\u{0}\u{65}\u{66}\u{67}\u{0}\u{1}\u{65}\u{1}")
376assert(string.match("\u{61}\u{62}\u{63}\u{0}\u{0}\u{0}","\u{25}\u{0}\u{2b}") == "\u{0}\u{0}\u{0}")
376assert(string.match("\u{61}\u{62}\u{63}\u{0}\u{0}\u{0}","\u{25}\u{0}\u{2b}") == "\u{0}\u{0}\u{0}")
377assert(string.match("\u{61}\u{62}\u{63}\u{0}\u{0}\u{0}","\u{25}\u{0}\u{25}\u{0}\u{3f}") == "\u{0}\u{0}")
377assert(string.match("\u{61}\u{62}\u{63}\u{0}\u{0}\u{0}","\u{25}\u{0}\u{25}\u{0}\u{3f}") == "\u{0}\u{0}")
378−assert(string.find("\u{61}\u{62}\u{63}\u{0}\u{0}","\u{0}\u{2e}") == 4)
378+assert(string.find("\u{61}\u{62}\u{63}\u{0}\u{0}","\u{0}\u{2e}") == 0x4)
379−assert(string.find("\u{61}\u{62}\u{63}\u{78}\u{0}\u{0}\u{61}\u{62}\u{63}\u{0}\u{61}\u{62}\u{63}","\u{78}\u{0}\u{0}\u{61}\u{62}\u{63}\u{0}\u{61}\u{2e}") == 4)
379+assert(string.find("\u{61}\u{62}\u{63}\u{78}\u{0}\u{0}\u{61}\u{62}\u{63}\u{0}\u{61}\u{62}\u{63}","\u{78}\u{0}\u{0}\u{61}\u{62}\u{63}\u{0}\u{61}\u{2e}") == 0x4)
380do
380do
381−local s = string.rep("\u{61}",100)
381+local s = string.rep("\u{61}",0x64)
382local r = string.gsub(s,"\u{62}","\u{63}")
382local r = string.gsub(s,"\u{62}","\u{63}")
383assert(string.format("\u{25}\u{70}",s) == string.format("\u{25}\u{70}",r))
383assert(string.format("\u{25}\u{70}",s) == string.format("\u{25}\u{70}",r))
384r=string.gsub(s,"\u{2e}",{["\u{78}"] = "\u{79}"})
384r=string.gsub(s,"\u{2e}",{["\u{78}"] = "\u{79}"})
385assert(string.format("\u{25}\u{70}",s) == string.format("\u{25}\u{70}",r))
385assert(string.format("\u{25}\u{70}",s) == string.format("\u{25}\u{70}",r))
386−local count = 0
386+local count = 0x0
387r=string.gsub(s,"\u{2e}",function (x)
387r=string.gsub(s,"\u{2e}",function (x)
388assert(x == "\u{61}")
388assert(x == "\u{61}")
389−count=count + 1
389+count=count + 0x1
390return nil
390return nil
391end)
391end)
392r=string.gsub(r,"\u{2e}",{["\u{62}"] = "\u{78}"})
392r=string.gsub(r,"\u{2e}",{["\u{62}"] = "\u{78}"})
393−assert(count == 100)
393+assert(count == 0x64)
394assert(string.format("\u{25}\u{70}",s) == string.format("\u{25}\u{70}",r))
394assert(string.format("\u{25}\u{70}",s) == string.format("\u{25}\u{70}",r))
395−count=0
395+count=0x0
396r=string.gsub(s,"\u{2e}",function (x)
396r=string.gsub(s,"\u{2e}",function (x)
397assert(x == "\u{61}")
397assert(x == "\u{61}")
398−count=count + 1
398+count=count + 0x1
399return x
399return x
400end)
400end)
401−assert(count == 100)
401+assert(count == 0x64)
402assert(r == s and string.format("\u{25}\u{70}",s) ~= string.format("\u{25}\u{70}",r))
402assert(r == s and string.format("\u{25}\u{70}",s) ~= string.format("\u{25}\u{70}",r))
403end
403end
404print("\u{4f}\u{4b}")
404print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/sort.lua+117−117
@@ -8,70 +8,70 @@ local function checkerror
8local s,err = pcall(f,...)
8local s,err = pcall(f,...)
9assert(not s and string.find(err,msg))
9assert(not s and string.find(err,msg))
10end
10end
11−checkerror("\u{77}\u{72}\u{6f}\u{6e}\u{67}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{6f}\u{66}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{73}",table.insert,{},2,3,4)
11+checkerror("\u{77}\u{72}\u{6f}\u{6e}\u{67}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{6f}\u{66}\u{20}\u{61}\u{72}\u{67}\u{75}\u{6d}\u{65}\u{6e}\u{74}\u{73}",table.insert,{},0x2,0x3,0x4)
12local x,y,z,a,n
12local x,y,z,a,n
13a={}
13a={}
14;
14;
15−local lim = _soft and 200 or 2000
15+local lim = _soft and 0xc8 or 0x7d0
16−for i = 1, lim
16+for i = 0x1, lim
17do
17do
18a[i]=i
18a[i]=i
19end
19end
20assert(select(lim,unpack(a)) == lim and select("\u{23}",unpack(a)) == lim)
20assert(select(lim,unpack(a)) == lim and select("\u{23}",unpack(a)) == lim)
21x=unpack(a)
21x=unpack(a)
22−assert(x == 1)
22+assert(x == 0x1)
23x={unpack(a)}
23x={unpack(a)}
24−assert(# x == lim and x[1] == 1 and x[lim] == lim)
24+assert(# x == lim and x[0x1] == 0x1 and x[lim] == lim)
25−x={unpack(a,lim - 2)}
25+x={unpack(a,lim - 0x2)}
26−assert(# x == 3 and x[1] == lim - 2 and x[3] == lim)
26+assert(# x == 0x3 and x[0x1] == lim - 0x2 and x[0x3] == lim)
27−x={unpack(a,10,6)}
27+x={unpack(a,0xa,0x6)}
28assert(next(x) == nil)
28assert(next(x) == nil)
29−x={unpack(a,11,10)}
29+x={unpack(a,0xb,0xa)}
30assert(next(x) == nil)
30assert(next(x) == nil)
31−x,y=unpack(a,10,10)
31+x,y=unpack(a,0xa,0xa)
32−assert(x == 10 and y == nil)
32+assert(x == 0xa and y == nil)
33−x,y,z=unpack(a,10,11)
33+x,y,z=unpack(a,0xa,0xb)
34−assert(x == 10 and y == 11 and z == nil)
34+assert(x == 0xa and y == 0xb and z == nil)
35−a,x=unpack({1})
35+a,x=unpack({0x1})
36−assert(a == 1 and x == nil)
36+assert(a == 0x1 and x == nil)
37−a,x=unpack({1,2},1,1)
37+a,x=unpack({0x1,0x2},0x1,0x1)
38−assert(a == 1 and x == nil)
38+assert(a == 0x1 and x == nil)
39do
39do
40−local maxi = (1 << 31) - 1
40+local maxi = (0x1 << 0x1f) - 0x1
41−local mini = - (1 << 31)
41+local mini = - (0x1 << 0x1f)
42−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},0,maxi)
42+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},0x0,maxi)
43−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},1,maxi)
43+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},0x1,maxi)
44−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},0,maxI)
44+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},0x0,maxI)
45−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},1,maxI)
45+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},0x1,maxI)
46checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},mini,maxi)
46checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},mini,maxi)
47checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},- maxi,maxi)
47checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},- maxi,maxi)
48checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},minI,maxI)
48checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}\u{20}\u{72}\u{65}\u{73}\u{75}\u{6c}\u{74}\u{73}",unpack,{},minI,maxI)
49−unpack({},maxi,0)
49+unpack({},maxi,0x0)
50−unpack({},maxi,1)
50+unpack({},maxi,0x1)
51unpack({},maxI,minI)
51unpack({},maxI,minI)
52−pcall(unpack,{},1,maxi + 1)
52+pcall(unpack,{},0x1,maxi + 0x1)
53−local a,b = unpack({[maxi] = 20},maxi,maxi)
53+local a,b = unpack({[maxi] = 0x14},maxi,maxi)
54−assert(a == 20 and b == nil)
54+assert(a == 0x14 and b == nil)
55−a,b=unpack({[maxi] = 20},maxi - 1,maxi)
55+a,b=unpack({[maxi] = 0x14},maxi - 0x1,maxi)
56−assert(a == nil and b == 20)
56+assert(a == nil and b == 0x14)
57−local t = {[maxI - 1] = 12,[maxI] = 23}
57+local t = {[maxI - 0x1] = 0xc,[maxI] = 0x17}
58−a,b=unpack(t,maxI - 1,maxI)
58+a,b=unpack(t,maxI - 0x1,maxI)
59;
59;
60−assert(a == 12 and b == 23)
60+assert(a == 0xc and b == 0x17)
61a,b=unpack(t,maxI,maxI)
61a,b=unpack(t,maxI,maxI)
62;
62;
63−assert(a == 23 and b == nil)
63+assert(a == 0x17 and b == nil)
64−a,b=unpack(t,maxI,maxI - 1)
64+a,b=unpack(t,maxI,maxI - 0x1)
65;
65;
66assert(a == nil and b == nil)
66assert(a == nil and b == nil)
67−t={[minI] = 12.3,[minI + 1] = 23.5}
67+t={[minI] = 12.3,[minI + 0x1] = 23.5}
68−a,b=unpack(t,minI,minI + 1)
68+a,b=unpack(t,minI,minI + 0x1)
69;
69;
70assert(a == 12.3 and b == 23.5)
70assert(a == 12.3 and b == 23.5)
71a,b=unpack(t,minI,minI)
71a,b=unpack(t,minI,minI)
72;
72;
73assert(a == 12.3 and b == nil)
73assert(a == 12.3 and b == nil)
74−a,b=unpack(t,minI + 1,minI)
74+a,b=unpack(t,minI + 0x1,minI)
75;
75;
76assert(a == nil and b == nil)
76assert(a == nil and b == nil)
77end
77end
@@ -80,17 +80,17 @@ local t = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
80return "\u{61}\u{62}\u{63}"
80return "\u{61}\u{62}\u{63}"
81end})
81end})
82assert(# t == "\u{61}\u{62}\u{63}")
82assert(# t == "\u{61}\u{62}\u{63}")
83−checkerror("\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{69}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{6e}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",table.insert,t,1)
83+checkerror("\u{6f}\u{62}\u{6a}\u{65}\u{63}\u{74}\u{20}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{69}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{6e}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",table.insert,t,0x1)
84end
84end
85print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}")
85print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}")
86a=table.pack()
86a=table.pack()
87−assert(a[1] == undef and a.n == 0)
87+assert(a[0x1] == undef and a.n == 0x0)
88a=table.pack(table)
88a=table.pack(table)
89−assert(a[1] == table and a.n == 1)
89+assert(a[0x1] == table and a.n == 0x1)
90a=table.pack(nil,nil,nil,nil)
90a=table.pack(nil,nil,nil,nil)
91−assert(a[1] == nil and a.n == 4)
91+assert(a[0x1] == nil and a.n == 0x4)
92do
92do
93−checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.move,1,2,3,4)
93+checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.move,0x1,0x2,0x3,0x4)
94local function eqT
94local function eqT
95(a,b)
95(a,b)
96for k,v in pairs(a)
96for k,v in pairs(a)
@@ -102,45 +102,45 @@ do
102assert(a[k] == v)
102assert(a[k] == v)
103end
103end
104end
104end
105−local a = table.move({10,20,30},1,3,2)
105+local a = table.move({0xa,0x14,0x1e},0x1,0x3,0x2)
106−eqT(a,{10,10,20,30})
106+eqT(a,{0xa,0xa,0x14,0x1e})
107−a=table.move({10,20,30},1,3,3)
107+a=table.move({0xa,0x14,0x1e},0x1,0x3,0x3)
108−eqT(a,{10,20,10,20,30})
108+eqT(a,{0xa,0x14,0xa,0x14,0x1e})
109−a={10,20,30,40}
109+a={0xa,0x14,0x1e,0x28}
110−table.move(a,1,4,2,a)
110+table.move(a,0x1,0x4,0x2,a)
111−eqT(a,{10,10,20,30,40})
111+eqT(a,{0xa,0xa,0x14,0x1e,0x28})
112−a=table.move({10,20,30},2,3,1)
112+a=table.move({0xa,0x14,0x1e},0x2,0x3,0x1)
113−eqT(a,{20,30,30})
113+eqT(a,{0x14,0x1e,0x1e})
114a={}
114a={}
115−assert(table.move({10,20,30},1,3,1,a) == a)
115+assert(table.move({0xa,0x14,0x1e},0x1,0x3,0x1,a) == a)
116−eqT(a,{10,20,30})
116+eqT(a,{0xa,0x14,0x1e})
117a={}
117a={}
118−assert(table.move({10,20,30},1,0,3,a) == a)
118+assert(table.move({0xa,0x14,0x1e},0x1,0x0,0x3,a) == a)
119eqT(a,{})
119eqT(a,{})
120−a=table.move({10,20,30},1,10,1)
120+a=table.move({0xa,0x14,0x1e},0x1,0xa,0x1)
121−eqT(a,{10,20,30})
121+eqT(a,{0xa,0x14,0x1e})
122−a=table.move({[maxI - 2] = 1,[maxI - 1] = 2,[maxI] = 3},maxI - 2,maxI,- 10,{})
122+a=table.move({[maxI - 0x2] = 0x1,[maxI - 0x1] = 0x2,[maxI] = 0x3},maxI - 0x2,maxI,- 0xa,{})
123−eqT(a,{[- 10] = 1,[- 9] = 2,[- 8] = 3})
123+eqT(a,{[- 0xa] = 0x1,[- 0x9] = 0x2,[- 0x8] = 0x3})
124−a=table.move({[minI] = 1,[minI + 1] = 2,[minI + 2] = 3},minI,minI + 2,- 10,{})
124+a=table.move({[minI] = 0x1,[minI + 0x1] = 0x2,[minI + 0x2] = 0x3},minI,minI + 0x2,- 0xa,{})
125−eqT(a,{[- 10] = 1,[- 9] = 2,[- 8] = 3})
125+eqT(a,{[- 0xa] = 0x1,[- 0x9] = 0x2,[- 0x8] = 0x3})
126−a=table.move({45},1,1,maxI)
126+a=table.move({0x2d},0x1,0x1,maxI)
127−eqT(a,{45,[maxI] = 45})
127+eqT(a,{0x2d,[maxI] = 0x2d})
128−a=table.move({[maxI] = 100},maxI,maxI,minI)
128+a=table.move({[maxI] = 0x64},maxI,maxI,minI)
129−eqT(a,{[minI] = 100,[maxI] = 100})
129+eqT(a,{[minI] = 0x64,[maxI] = 0x64})
130−a=table.move({[minI] = 100},minI,minI,maxI)
130+a=table.move({[minI] = 0x64},minI,minI,maxI)
131−eqT(a,{[minI] = 100,[maxI] = 100})
131+eqT(a,{[minI] = 0x64,[maxI] = 0x64})
132a=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,k)
132a=setmetatable({},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (_,k)
133−return k * 10
133+return k * 0xa
134end,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = error})
134end,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = error})
135−local b = table.move(a,1,10,3,{})
135+local b = table.move(a,0x1,0xa,0x3,{})
136eqT(a,{})
136eqT(a,{})
137−eqT(b,{nil,nil,10,20,30,40,50,60,70,80,90,100})
137+eqT(b,{nil,nil,0xa,0x14,0x1e,0x28,0x32,0x3c,0x46,0x50,0x5a,0x64})
138b=setmetatable({""},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = error,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k,v)
138b=setmetatable({""},{["\u{5f}\u{5f}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = error,["\u{5f}\u{5f}\u{6e}\u{65}\u{77}\u{69}\u{6e}\u{64}\u{65}\u{78}"] = function (t,k,v)
139−t[1]=string.format("\u{25}\u{73}\u{28}\u{25}\u{64}\u{2c}\u{25}\u{64}\u{29}",t[1],k,v)
139+t[0x1]=string.format("\u{25}\u{73}\u{28}\u{25}\u{64}\u{2c}\u{25}\u{64}\u{29}",t[0x1],k,v)
140end})
140end})
141−table.move(a,10,13,3,b)
141+table.move(a,0xa,0xd,0x3,b)
142−assert(b[1] == "\u{28}\u{33}\u{2c}\u{31}\u{30}\u{30}\u{29}\u{28}\u{34}\u{2c}\u{31}\u{31}\u{30}\u{29}\u{28}\u{35}\u{2c}\u{31}\u{32}\u{30}\u{29}\u{28}\u{36}\u{2c}\u{31}\u{33}\u{30}\u{29}")
142+assert(b[0x1] == "\u{28}\u{33}\u{2c}\u{31}\u{30}\u{30}\u{29}\u{28}\u{34}\u{2c}\u{31}\u{31}\u{30}\u{29}\u{28}\u{35}\u{2c}\u{31}\u{32}\u{30}\u{29}\u{28}\u{36}\u{2c}\u{31}\u{33}\u{30}\u{29}")
143−local stat,msg = pcall(table.move,b,10,13,3,b)
143+local stat,msg = pcall(table.move,b,0xa,0xd,0x3,b)
144assert(not stat and msg == b)
144assert(not stat and msg == b)
145end
145end
146do
146do
@@ -157,25 +157,25 @@ end})
157local st,msg = pcall(table.move,a,f,e,t)
157local st,msg = pcall(table.move,a,f,e,t)
158assert(not st and not msg and pos1 == x and pos2 == y)
158assert(not st and not msg and pos1 == x and pos2 == y)
159end
159end
160−checkmove(1,maxI,0,1,0)
160+checkmove(0x1,maxI,0x0,0x1,0x0)
161−checkmove(0,maxI - 1,1,maxI - 1,maxI)
161+checkmove(0x0,maxI - 0x1,0x1,maxI - 0x1,maxI)
162−checkmove(minI,- 2,- 5,- 2,maxI - 6)
162+checkmove(minI,- 0x2,- 0x5,- 0x2,maxI - 0x6)
163−checkmove(minI + 1,- 1,- 2,- 1,maxI - 3)
163+checkmove(minI + 0x1,- 0x1,- 0x2,- 0x1,maxI - 0x3)
164−checkmove(minI,- 2,0,minI,0)
164+checkmove(minI,- 0x2,0x0,minI,0x0)
165−checkmove(minI + 1,- 1,1,minI + 1,1)
165+checkmove(minI + 0x1,- 0x1,0x1,minI + 0x1,0x1)
166end
166end
167−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},0,maxI,1)
167+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},0x0,maxI,0x1)
168−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},- 1,maxI - 1,1)
168+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},- 0x1,maxI - 0x1,0x1)
169−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},minI,- 1,1)
169+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},minI,- 0x1,0x1)
170−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},minI,maxI,1)
170+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6d}\u{61}\u{6e}\u{79}",table.move,{},minI,maxI,0x1)
171−checkerror("\u{77}\u{72}\u{61}\u{70}\u{20}\u{61}\u{72}\u{6f}\u{75}\u{6e}\u{64}",table.move,{},1,maxI,2)
171+checkerror("\u{77}\u{72}\u{61}\u{70}\u{20}\u{61}\u{72}\u{6f}\u{75}\u{6e}\u{64}",table.move,{},0x1,maxI,0x2)
172−checkerror("\u{77}\u{72}\u{61}\u{70}\u{20}\u{61}\u{72}\u{6f}\u{75}\u{6e}\u{64}",table.move,{},1,2,maxI)
172+checkerror("\u{77}\u{72}\u{61}\u{70}\u{20}\u{61}\u{72}\u{6f}\u{75}\u{6e}\u{64}",table.move,{},0x1,0x2,maxI)
173−checkerror("\u{77}\u{72}\u{61}\u{70}\u{20}\u{61}\u{72}\u{6f}\u{75}\u{6e}\u{64}",table.move,{},minI,- 2,2)
173+checkerror("\u{77}\u{72}\u{61}\u{70}\u{20}\u{61}\u{72}\u{6f}\u{75}\u{6e}\u{64}",table.move,{},minI,- 0x2,0x2)
174print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{6f}\u{72}\u{74}")
174print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{6f}\u{72}\u{74}")
175local a = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
175local a = setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
176−return - 1
176+return - 0x1
177end})
177end})
178−assert(# a == - 1)
178+assert(# a == - 0x1)
179table.sort(a,error)
179table.sort(a,error)
180a=setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
180a=setmetatable({},{["\u{5f}\u{5f}\u{6c}\u{65}\u{6e}"] = function ()
181return maxI
181return maxI
@@ -191,17 +191,17 @@ return true
191end
191end
192checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}",table.sort,t,f)
192checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}",table.sort,t,f)
193end
193end
194−check({1,2,3,4})
194+check({0x1,0x2,0x3,0x4})
195−check({1,2,3,4,5})
195+check({0x1,0x2,0x3,0x4,0x5})
196−check({1,2,3,4,5,6})
196+check({0x1,0x2,0x3,0x4,0x5,0x6})
197function check(a,f)
197function check(a,f)
198f=f or function (x,y)
198f=f or function (x,y)
199return x < y
199return x < y
200end
200end
201;
201;
202−for n = # a, 2, - 1
202+for n = # a, 0x2, - 0x1
203do
203do
204−assert(not f(a[n],a[n - 1]))
204+assert(not f(a[n],a[n - 0x1]))
205end
205end
206end
206end
207a={"\u{4a}\u{61}\u{6e}","\u{46}\u{65}\u{62}","\u{4d}\u{61}\u{72}","\u{41}\u{70}\u{72}","\u{4d}\u{61}\u{79}","\u{4a}\u{75}\u{6e}","\u{4a}\u{75}\u{6c}","\u{41}\u{75}\u{67}","\u{53}\u{65}\u{70}","\u{4f}\u{63}\u{74}","\u{4e}\u{6f}\u{76}","\u{44}\u{65}\u{63}"}
207a={"\u{4a}\u{61}\u{6e}","\u{46}\u{65}\u{62}","\u{4d}\u{61}\u{72}","\u{41}\u{70}\u{72}","\u{4d}\u{61}\u{79}","\u{4a}\u{75}\u{6e}","\u{4a}\u{75}\u{6c}","\u{41}\u{75}\u{67}","\u{53}\u{65}\u{70}","\u{4f}\u{63}\u{74}","\u{4e}\u{6f}\u{76}","\u{44}\u{65}\u{63}"}
@@ -210,69 +210,69 @@ check(a)
210local function perm
210local function perm
211(s,n)
211(s,n)
212n=n or # s
212n=n or # s
213−if n == 1 then
213+if n == 0x1 then
214local t = {unpack(s)}
214local t = {unpack(s)}
215table.sort(t)
215table.sort(t)
216check(t)
216check(t)
217else
217else
218−for i = 1, n
218+for i = 0x1, n
219do
219do
220s[i],s[n]=s[n],s[i]
220s[i],s[n]=s[n],s[i]
221−perm(s,n - 1)
221+perm(s,n - 0x1)
222s[i],s[n]=s[n],s[i]
222s[i],s[n]=s[n],s[i]
223end
223end
224end
224end
225end
225end
226perm({})
226perm({})
227−perm({1})
227+perm({0x1})
228−perm({1,2})
228+perm({0x1,0x2})
229−perm({1,2,3})
229+perm({0x1,0x2,0x3})
230−perm({1,2,3,4})
230+perm({0x1,0x2,0x3,0x4})
231−perm({2,2,3,4})
231+perm({0x2,0x2,0x3,0x4})
232−perm({1,2,3,4,5})
232+perm({0x1,0x2,0x3,0x4,0x5})
233−perm({1,2,3,3,5})
233+perm({0x1,0x2,0x3,0x3,0x5})
234−perm({1,2,3,4,5,6})
234+perm({0x1,0x2,0x3,0x4,0x5,0x6})
235−perm({2,2,3,3,5,6})
235+perm({0x2,0x2,0x3,0x3,0x5,0x6})
236local function timesort
236local function timesort
237(a,n,func,msg,pre)
237(a,n,func,msg,pre)
238local x = os.clock()
238local x = os.clock()
239table.sort(a,func)
239table.sort(a,func)
240−x=(os.clock() - x) * 1000
240+x=(os.clock() - x) * 0x3e8
241pre=pre or ""
241pre=pre or ""
242print(string.format("\u{25}\u{73}\u{73}\u{6f}\u{72}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{25}\u{64}\u{20}\u{25}\u{73}\u{20}\u{65}\u{6c}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{2e}\u{32}\u{66}\u{20}\u{6d}\u{73}\u{65}\u{63}\u{2e}",pre,n,msg,x))
242print(string.format("\u{25}\u{73}\u{73}\u{6f}\u{72}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{25}\u{64}\u{20}\u{25}\u{73}\u{20}\u{65}\u{6c}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{2e}\u{32}\u{66}\u{20}\u{6d}\u{73}\u{65}\u{63}\u{2e}",pre,n,msg,x))
243check(a,func)
243check(a,func)
244end
244end
245−local limit = 50000
245+local limit = 0xc350
246if _soft then
246if _soft then
247−limit=5000
247+limit=0x1388
248end
248end
249a={}
249a={}
250−for i = 1, limit
250+for i = 0x1, limit
251do
251do
252a[i]=math.random()
252a[i]=math.random()
253end
253end
254timesort(a,limit,nil,"\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}")
254timesort(a,limit,nil,"\u{72}\u{61}\u{6e}\u{64}\u{6f}\u{6d}")
255timesort(a,limit,nil,"\u{73}\u{6f}\u{72}\u{74}\u{65}\u{64}","\u{72}\u{65}\u{2d}")
255timesort(a,limit,nil,"\u{73}\u{6f}\u{72}\u{74}\u{65}\u{64}","\u{72}\u{65}\u{2d}")
256a={}
256a={}
257−for i = 1, limit
257+for i = 0x1, limit
258do
258do
259a[i]=math.random()
259a[i]=math.random()
260end
260end
261local x = os.clock()
261local x = os.clock()
262;
262;
263−local i = 0
263+local i = 0x0
264table.sort(a,function (x,y)
264table.sort(a,function (x,y)
265−i=i + 1
265+i=i + 0x1
266;
266;
267return y < x
267return y < x
268end)
268end)
269−x=(os.clock() - x) * 1000
269+x=(os.clock() - x) * 0x3e8
270print(string.format("\u{49}\u{6e}\u{76}\u{65}\u{72}\u{74}\u{2d}\u{73}\u{6f}\u{72}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{25}\u{64}\u{20}\u{65}\u{6c}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{2e}\u{32}\u{66}\u{20}\u{6d}\u{73}\u{65}\u{63}\u{2e}\u{2c}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{25}\u{69}\u{20}\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{69}\u{73}\u{6f}\u{6e}\u{73}",limit,x,i))
270print(string.format("\u{49}\u{6e}\u{76}\u{65}\u{72}\u{74}\u{2d}\u{73}\u{6f}\u{72}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6f}\u{74}\u{68}\u{65}\u{72}\u{20}\u{25}\u{64}\u{20}\u{65}\u{6c}\u{65}\u{6d}\u{65}\u{6e}\u{74}\u{73}\u{20}\u{69}\u{6e}\u{20}\u{25}\u{2e}\u{32}\u{66}\u{20}\u{6d}\u{73}\u{65}\u{63}\u{2e}\u{2c}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{25}\u{69}\u{20}\u{63}\u{6f}\u{6d}\u{70}\u{61}\u{72}\u{69}\u{73}\u{6f}\u{6e}\u{73}",limit,x,i))
271check(a,function (x,y)
271check(a,function (x,y)
272return y < x
272return y < x
273end)
273end)
274table.sort({})
274table.sort({})
275−for i = 1, limit
275+for i = 0x1, limit
276do
276do
277a[i]=false
277a[i]=false
278end
278end
@@ -296,9 +296,9 @@ local tt = {["\u{5f}\u{5f}\u{6c}\u{74}"] = function (a,b)
296return a.val < b.val
296return a.val < b.val
297end}
297end}
298a={}
298a={}
299−for i = 1, 10
299+for i = 0x1, 0xa
300do
300do
301−a[i]={["\u{76}\u{61}\u{6c}"] = math.random(100)}
301+a[i]={["\u{76}\u{61}\u{6c}"] = math.random(0x64)}
302;
302;
303setmetatable(a[i],tt)
303setmetatable(a[i],tt)
304;
304;
zod/luau/res/lua/cycled/strings.lua+183−183
@@ -23,116 +23,116 @@ assert(not ("\u{0}\u{0}\u{0}\u{0}" <= "\u{0}\u{0}\u{0}"))
23assert("\u{0}\u{0}\u{0}" <= "\u{0}\u{0}\u{0}")
23assert("\u{0}\u{0}\u{0}" <= "\u{0}\u{0}\u{0}")
24assert("\u{0}\u{0}\u{0}" >= "\u{0}\u{0}\u{0}")
24assert("\u{0}\u{0}\u{0}" >= "\u{0}\u{0}\u{0}")
25assert(not ("\u{0}\u{0}\u{62}" < "\u{0}\u{0}\u{61}\u{0}"))
25assert(not ("\u{0}\u{0}\u{62}" < "\u{0}\u{0}\u{61}\u{0}"))
26−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",2,4) == "\u{32}\u{33}\u{34}")
26+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x2,0x4) == "\u{32}\u{33}\u{34}")
27−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",7) == "\u{37}\u{38}\u{39}")
27+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x7) == "\u{37}\u{38}\u{39}")
28−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",7,6) == "")
28+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x7,0x6) == "")
29−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",7,7) == "\u{37}")
29+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x7,0x7) == "\u{37}")
30−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0,0) == "")
30+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x0,0x0) == "")
31−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 10,10) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}")
31+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 0xa,0xa) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}")
32−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",1,9) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}")
32+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x1,0x9) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}")
33−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 10,- 20) == "")
33+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 0xa,- 0x14) == "")
34−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 1) == "\u{39}")
34+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 0x1) == "\u{39}")
35−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 4) == "\u{36}\u{37}\u{38}\u{39}")
35+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 0x4) == "\u{36}\u{37}\u{38}\u{39}")
36−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 6,- 4) == "\u{34}\u{35}\u{36}")
36+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",- 0x6,- 0x4) == "\u{34}\u{35}\u{36}")
37−assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",mini,- 4) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}")
37+assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",mini,- 0x4) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}")
38assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",mini,maxi) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}")
38assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",mini,maxi) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}")
39assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",mini,mini) == "")
39assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",mini,mini) == "")
40−assert(string.sub("\u{0}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",3,5) == "\u{32}\u{33}\u{34}")
40+assert(string.sub("\u{0}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",0x3,0x5) == "\u{32}\u{33}\u{34}")
41−assert(("\u{0}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"):sub(8) == "\u{37}\u{38}\u{39}")
41+assert(("\u{0}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}"):sub(0x8) == "\u{37}\u{38}\u{39}")
42−assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}") == 3)
42+assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}") == 0x3)
43local a,b = string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}")
43local a,b = string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}")
44assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",a,b) == "\u{33}\u{34}\u{35}")
44assert(string.sub("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}",a,b) == "\u{33}\u{34}\u{35}")
45−assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}",3) == 3)
45+assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}",0x3) == 0x3)
46−assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}",4) == 13)
46+assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{35}",0x4) == 0xd)
47−assert(not string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{36}",4))
47+assert(not string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{33}\u{34}\u{36}",0x4))
48−assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{2e}\u{34}\u{35}",- 9) == 13)
48+assert(string.find("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}","\u{2e}\u{34}\u{35}",- 0x9) == 0xd)
49−assert(not string.find("\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}","\u{0}",5,1))
49+assert(not string.find("\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}","\u{0}",0x5,0x1))
50−assert(string.find("","") == 1)
50+assert(string.find("","") == 0x1)
51−assert(string.find("","",1) == 1)
51+assert(string.find("","",0x1) == 0x1)
52−assert(not string.find("","",2))
52+assert(not string.find("","",0x2))
53−assert(not string.find("","\u{61}\u{61}\u{61}",1))
53+assert(not string.find("","\u{61}\u{61}\u{61}",0x1))
54−assert(("\u{61}\u{6c}\u{6f}\u{28}\u{2e}\u{29}\u{61}\u{6c}\u{6f}"):find("\u{28}\u{2e}\u{29}",1,1) == 4)
54+assert(("\u{61}\u{6c}\u{6f}\u{28}\u{2e}\u{29}\u{61}\u{6c}\u{6f}"):find("\u{28}\u{2e}\u{29}",0x1,0x1) == 0x4)
55−assert(string.len("") == 0)
55+assert(string.len("") == 0x0)
56−assert(string.len("\u{0}\u{0}\u{0}") == 3)
56+assert(string.len("\u{0}\u{0}\u{0}") == 0x3)
57−assert(string.len("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}") == 10)
57+assert(string.len("\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}") == 0xa)
58−assert(# "" == 0)
58+assert(# "" == 0x0)
59−assert(# "\u{0}\u{0}\u{0}" == 3)
59+assert(# "\u{0}\u{0}\u{0}" == 0x3)
60−assert(# "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}" == 10)
60+assert(# "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}" == 0xa)
61−assert(string.byte("\u{61}") == 97)
61+assert(string.byte("\u{61}") == 0x61)
62−assert(string.byte("\u{e4}") > 127)
62+assert(string.byte("\u{e4}") > 0x7f)
63−assert(string.byte(string.char(255)) == 255)
63+assert(string.byte(string.char(0xff)) == 0xff)
64−assert(string.byte(string.char(0)) == 0)
64+assert(string.byte(string.char(0x0)) == 0x0)
65−assert(string.byte("\u{0}") == 0)
65+assert(string.byte("\u{0}") == 0x0)
66−assert(string.byte("\u{0}\u{0}\u{61}\u{6c}\u{6f}\u{0}\u{78}",- 1) == string.byte("\u{78}"))
66+assert(string.byte("\u{0}\u{0}\u{61}\u{6c}\u{6f}\u{0}\u{78}",- 0x1) == string.byte("\u{78}"))
67−assert(string.byte("\u{62}\u{61}",2) == 97)
67+assert(string.byte("\u{62}\u{61}",0x2) == 0x61)
68−assert(string.byte("\u{a}\u{a}",2,- 1) == 10)
68+assert(string.byte("\u{a}\u{a}",0x2,- 0x1) == 0xa)
69−assert(string.byte("\u{a}\u{a}",2,2) == 10)
69+assert(string.byte("\u{a}\u{a}",0x2,0x2) == 0xa)
70assert(string.byte("") == nil)
70assert(string.byte("") == nil)
71−assert(string.byte("\u{68}\u{69}",- 3) == nil)
71+assert(string.byte("\u{68}\u{69}",- 0x3) == nil)
72−assert(string.byte("\u{68}\u{69}",3) == nil)
72+assert(string.byte("\u{68}\u{69}",0x3) == nil)
73−assert(string.byte("\u{68}\u{69}",9,10) == nil)
73+assert(string.byte("\u{68}\u{69}",0x9,0xa) == nil)
74−assert(string.byte("\u{68}\u{69}",2,1) == nil)
74+assert(string.byte("\u{68}\u{69}",0x2,0x1) == nil)
75assert(string.char() == "")
75assert(string.char() == "")
76−assert(string.char(0,255,0) == "\u{0}\u{ff}\u{0}")
76+assert(string.char(0x0,0xff,0x0) == "\u{0}\u{ff}\u{0}")
77−assert(string.char(0,string.byte("\u{e4}"),0) == "\u{0}\u{e4}\u{0}")
77+assert(string.char(0x0,string.byte("\u{e4}"),0x0) == "\u{0}\u{e4}\u{0}")
78−assert(string.char(string.byte("\u{e4}\u{6c}\u{0}\u{f3}\u{75}",1,- 1)) == "\u{e4}\u{6c}\u{0}\u{f3}\u{75}")
78+assert(string.char(string.byte("\u{e4}\u{6c}\u{0}\u{f3}\u{75}",0x1,- 0x1)) == "\u{e4}\u{6c}\u{0}\u{f3}\u{75}")
79−assert(string.char(string.byte("\u{e4}\u{6c}\u{0}\u{f3}\u{75}",1,0)) == "")
79+assert(string.char(string.byte("\u{e4}\u{6c}\u{0}\u{f3}\u{75}",0x1,0x0)) == "")
80−assert(string.char(string.byte("\u{e4}\u{6c}\u{0}\u{f3}\u{75}",- 10,100)) == "\u{e4}\u{6c}\u{0}\u{f3}\u{75}")
80+assert(string.char(string.byte("\u{e4}\u{6c}\u{0}\u{f3}\u{75}",- 0xa,0x64)) == "\u{e4}\u{6c}\u{0}\u{f3}\u{75}")
81−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,256)
81+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,0x100)
82−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,- 1)
82+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,- 0x1)
83checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,math.maxinteger)
83checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,math.maxinteger)
84checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,math.mininteger)
84checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",string.char,math.mininteger)
85assert(string.upper("\u{61}\u{62}\u{0}\u{63}") == "\u{41}\u{42}\u{0}\u{43}")
85assert(string.upper("\u{61}\u{62}\u{0}\u{63}") == "\u{41}\u{42}\u{0}\u{43}")
86assert(string.lower("\u{0}\u{41}\u{42}\u{43}\u{63}\u{25}\u{24}") == "\u{0}\u{61}\u{62}\u{63}\u{63}\u{25}\u{24}")
86assert(string.lower("\u{0}\u{41}\u{42}\u{43}\u{63}\u{25}\u{24}") == "\u{0}\u{61}\u{62}\u{63}\u{63}\u{25}\u{24}")
87−assert(string.rep("\u{74}\u{65}\u{73}\u{74}\u{65}",0) == "")
87+assert(string.rep("\u{74}\u{65}\u{73}\u{74}\u{65}",0x0) == "")
88−assert(string.rep("\u{74}\u{e9}\u{73}\u{0}\u{74}\u{ea}",2) == "\u{74}\u{e9}\u{73}\u{0}\u{74}\u{ea}\u{74}\u{e9}\u{73}\u{0}\u{74}\u{ea}")
88+assert(string.rep("\u{74}\u{e9}\u{73}\u{0}\u{74}\u{ea}",0x2) == "\u{74}\u{e9}\u{73}\u{0}\u{74}\u{ea}\u{74}\u{e9}\u{73}\u{0}\u{74}\u{ea}")
89−assert(string.rep("",10) == "")
89+assert(string.rep("",0xa) == "")
90−if string.packsize("\u{69}") == 4 then
90+if string.packsize("\u{69}") == 0x4 then
91−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}",string.rep,"\u{61}\u{61}",(1 << 30))
91+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}",string.rep,"\u{61}\u{61}",(0x1 << 0x1e))
92−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}",string.rep,"\u{61}",(1 << 30),"\u{2c}")
92+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}",string.rep,"\u{61}",(0x1 << 0x1e),"\u{2c}")
93−end
93+end
94−assert(string.rep("\u{74}\u{65}\u{73}\u{74}\u{65}",0,"\u{78}\u{75}\u{78}\u{75}") == "")
94+assert(string.rep("\u{74}\u{65}\u{73}\u{74}\u{65}",0x0,"\u{78}\u{75}\u{78}\u{75}") == "")
95−assert(string.rep("\u{74}\u{65}\u{73}\u{74}\u{65}",1,"\u{78}\u{75}\u{78}\u{75}") == "\u{74}\u{65}\u{73}\u{74}\u{65}")
95+assert(string.rep("\u{74}\u{65}\u{73}\u{74}\u{65}",0x1,"\u{78}\u{75}\u{78}\u{75}") == "\u{74}\u{65}\u{73}\u{74}\u{65}")
96−assert(string.rep("\u{1}\u{0}\u{1}",2,"\u{0}\u{0}") == "\u{1}\u{0}\u{1}\u{0}\u{0}\u{1}\u{0}\u{1}")
96+assert(string.rep("\u{1}\u{0}\u{1}",0x2,"\u{0}\u{0}") == "\u{1}\u{0}\u{1}\u{0}\u{0}\u{1}\u{0}\u{1}")
97−assert(string.rep("",10,"\u{2e}") == string.rep("\u{2e}",9))
97+assert(string.rep("",0xa,"\u{2e}") == string.rep("\u{2e}",0x9))
98−assert(not pcall(string.rep,"\u{61}\u{61}",maxi // 2 + 10))
98+assert(not pcall(string.rep,"\u{61}\u{61}",maxi // 0x2 + 0xa))
99−assert(not pcall(string.rep,"",maxi // 2 + 10,"\u{61}\u{61}"))
99+assert(not pcall(string.rep,"",maxi // 0x2 + 0xa,"\u{61}\u{61}"))
100assert(string.reverse("") == "")
100assert(string.reverse("") == "")
101assert(string.reverse("\u{0}\u{1}\u{2}\u{3}") == "\u{3}\u{2}\u{1}\u{0}")
101assert(string.reverse("\u{0}\u{1}\u{2}\u{3}") == "\u{3}\u{2}\u{1}\u{0}")
102assert(string.reverse("\u{0}\u{31}\u{32}\u{33}\u{34}") == "\u{34}\u{33}\u{32}\u{31}\u{0}")
102assert(string.reverse("\u{0}\u{31}\u{32}\u{33}\u{34}") == "\u{34}\u{33}\u{32}\u{31}\u{0}")
103−for i = 0, 30
103+for i = 0x0, 0x1e
104do
104do
105assert(string.len(string.rep("\u{61}",i)) == i)
105assert(string.len(string.rep("\u{61}",i)) == i)
106end
106end
107assert(type(tostring(nil)) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
107assert(type(tostring(nil)) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
108−assert(type(tostring(12)) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
108+assert(type(tostring(0xc)) == "\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}")
109assert(string.find(tostring({}),"\u{74}\u{61}\u{62}\u{6c}\u{65}\u{3a}"))
109assert(string.find(tostring({}),"\u{74}\u{61}\u{62}\u{6c}\u{65}\u{3a}"))
110assert(string.find(tostring(print),"\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{3a}"))
110assert(string.find(tostring(print),"\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{3a}"))
111−assert(# tostring("\u{0}") == 1)
111+assert(# tostring("\u{0}") == 0x1)
112assert(tostring(true) == "\u{74}\u{72}\u{75}\u{65}")
112assert(tostring(true) == "\u{74}\u{72}\u{75}\u{65}")
113assert(tostring(false) == "\u{66}\u{61}\u{6c}\u{73}\u{65}")
113assert(tostring(false) == "\u{66}\u{61}\u{6c}\u{73}\u{65}")
114−assert(tostring(- 1203) == "\u{2d}\u{31}\u{32}\u{30}\u{33}")
114+assert(tostring(- 0x4b3) == "\u{2d}\u{31}\u{32}\u{30}\u{33}")
115assert(tostring(1203.125) == "\u{31}\u{32}\u{30}\u{33}\u{2e}\u{31}\u{32}\u{35}")
115assert(tostring(1203.125) == "\u{31}\u{32}\u{30}\u{33}\u{2e}\u{31}\u{32}\u{35}")
116assert(tostring(- 0.5) == "\u{2d}\u{30}\u{2e}\u{35}")
116assert(tostring(- 0.5) == "\u{2d}\u{30}\u{2e}\u{35}")
117−assert(tostring(- 32767) == "\u{2d}\u{33}\u{32}\u{37}\u{36}\u{37}")
117+assert(tostring(- 0x7fff) == "\u{2d}\u{33}\u{32}\u{37}\u{36}\u{37}")
118−if math.tointeger(2147483647) then
118+if math.tointeger(0x7fffffff) then
119−assert(tostring(- 2147483647) == "\u{2d}\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}")
119+assert(tostring(- 0x7fffffff) == "\u{2d}\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}")
120end
120end
121−if math.tointeger(4611686018427387904) then
121+if math.tointeger(0x4000000000000000) then
122−assert(tostring(4611686018427387904) == "\u{34}\u{36}\u{31}\u{31}\u{36}\u{38}\u{36}\u{30}\u{31}\u{38}\u{34}\u{32}\u{37}\u{33}\u{38}\u{37}\u{39}\u{30}\u{34}")
122+assert(tostring(0x4000000000000000) == "\u{34}\u{36}\u{31}\u{31}\u{36}\u{38}\u{36}\u{30}\u{31}\u{38}\u{34}\u{32}\u{37}\u{33}\u{38}\u{37}\u{39}\u{30}\u{34}")
123−assert(tostring(- 4611686018427387904) == "\u{2d}\u{34}\u{36}\u{31}\u{31}\u{36}\u{38}\u{36}\u{30}\u{31}\u{38}\u{34}\u{32}\u{37}\u{33}\u{38}\u{37}\u{39}\u{30}\u{34}")
123+assert(tostring(- 0x4000000000000000) == "\u{2d}\u{34}\u{36}\u{31}\u{31}\u{36}\u{38}\u{36}\u{30}\u{31}\u{38}\u{34}\u{32}\u{37}\u{33}\u{38}\u{37}\u{39}\u{30}\u{34}")
124end
124end
125if tostring(0.0) == "\u{30}\u{2e}\u{30}" then
125if tostring(0.0) == "\u{30}\u{2e}\u{30}" then
126−assert("" .. 12 == "\u{31}\u{32}" and 12.0 .. "" == "\u{31}\u{32}\u{2e}\u{30}")
126+assert("" .. 0xc == "\u{31}\u{32}" and 12.0 .. "" == "\u{31}\u{32}\u{2e}\u{30}")
127−assert(tostring(- 1203 + 0.0) == "\u{2d}\u{31}\u{32}\u{30}\u{33}\u{2e}\u{30}")
127+assert(tostring(- 0x4b3 + 0.0) == "\u{2d}\u{31}\u{32}\u{30}\u{33}\u{2e}\u{30}")
128else
128else
129assert(tostring(0.0) == "\u{30}")
129assert(tostring(0.0) == "\u{30}")
130−assert("" .. 12 == "\u{31}\u{32}" and 12.0 .. "" == "\u{31}\u{32}")
130+assert("" .. 0xc == "\u{31}\u{32}" and 12.0 .. "" == "\u{31}\u{32}")
131−assert(tostring(- 1203 + 0.0) == "\u{2d}\u{31}\u{32}\u{30}\u{33}")
131+assert(tostring(- 0x4b3 + 0.0) == "\u{2d}\u{31}\u{32}\u{30}\u{33}")
132end
132end
133do
133do
134local null = "\u{28}\u{6e}\u{75}\u{6c}\u{6c}\u{29}"
134local null = "\u{28}\u{6e}\u{75}\u{6c}\u{6c}\u{29}"
135−assert(string.format("\u{25}\u{70}",4) == null)
135+assert(string.format("\u{25}\u{70}",0x4) == null)
136assert(string.format("\u{25}\u{70}",true) == null)
136assert(string.format("\u{25}\u{70}",true) == null)
137assert(string.format("\u{25}\u{70}",nil) == null)
137assert(string.format("\u{25}\u{70}",nil) == null)
138assert(string.format("\u{25}\u{70}",{}) ~= null)
138assert(string.format("\u{25}\u{70}",{}) ~= null)
@@ -142,10 +142,10 @@ assert(string.format("\u{25}\u{70}",io.stdin) ~= null)
142assert(string.format("\u{25}\u{70}",io.stdin) == string.format("\u{25}\u{70}",io.stdin))
142assert(string.format("\u{25}\u{70}",io.stdin) == string.format("\u{25}\u{70}",io.stdin))
143assert(string.format("\u{25}\u{70}",print) == string.format("\u{25}\u{70}",print))
143assert(string.format("\u{25}\u{70}",print) == string.format("\u{25}\u{70}",print))
144assert(string.format("\u{25}\u{70}",print) ~= string.format("\u{25}\u{70}",assert))
144assert(string.format("\u{25}\u{70}",print) ~= string.format("\u{25}\u{70}",assert))
145−assert(# string.format("\u{25}\u{39}\u{30}\u{70}",{}) == 90)
145+assert(# string.format("\u{25}\u{39}\u{30}\u{70}",{}) == 0x5a)
146−assert(# string.format("\u{25}\u{2d}\u{36}\u{30}\u{70}",{}) == 60)
146+assert(# string.format("\u{25}\u{2d}\u{36}\u{30}\u{70}",{}) == 0x3c)
147−assert(string.format("\u{25}\u{31}\u{30}\u{70}",false) == string.rep("\u{20}",10 - # null) .. null)
147+assert(string.format("\u{25}\u{31}\u{30}\u{70}",false) == string.rep("\u{20}",0xa - # null) .. null)
148−assert(string.format("\u{25}\u{2d}\u{31}\u{32}\u{70}",1.5) == null .. string.rep("\u{20}",12 - # null))
148+assert(string.format("\u{25}\u{2d}\u{31}\u{32}\u{70}",1.5) == null .. string.rep("\u{20}",0xc - # null))
149do
149do
150local t1 = {}
150local t1 = {}
151;
151;
@@ -153,14 +153,14 @@ local t2 = {}
153assert(string.format("\u{25}\u{70}",t1) ~= string.format("\u{25}\u{70}",t2))
153assert(string.format("\u{25}\u{70}",t1) ~= string.format("\u{25}\u{70}",t2))
154end
154end
155do
155do
156−local s1 = string.rep("\u{61}",10)
156+local s1 = string.rep("\u{61}",0xa)
157−local s2 = string.rep("\u{61}\u{61}",5)
157+local s2 = string.rep("\u{61}\u{61}",0x5)
158assert(string.format("\u{25}\u{70}",s1) == string.format("\u{25}\u{70}",s2))
158assert(string.format("\u{25}\u{70}",s1) == string.format("\u{25}\u{70}",s2))
159end
159end
160do
160do
161−local s1 = string.rep("\u{61}",300)
161+local s1 = string.rep("\u{61}",0x12c)
162;
162;
163−local s2 = string.rep("\u{61}",300)
163+local s2 = string.rep("\u{61}",0x12c)
164assert(string.format("\u{25}\u{70}",s1) ~= string.format("\u{25}\u{70}",s2))
164assert(string.format("\u{25}\u{70}",s1) ~= string.format("\u{25}\u{70}",s2))
165end
165end
166end
166end
@@ -170,15 +170,15 @@ assert(string.format("\u{25}\u{71}","\u{0}") == "\u{22}\u{5c}\u{30}\u{22}")
170assert(load(string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{71}",x))() == x)
170assert(load(string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{71}",x))() == x)
171x="\u{0}\u{1}\u{2}\u{33}\u{5}\u{0}\u{39}"
171x="\u{0}\u{1}\u{2}\u{33}\u{5}\u{0}\u{39}"
172assert(load(string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{71}",x))() == x)
172assert(load(string.format("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{25}\u{71}",x))() == x)
173−assert(string.format("\u{0}\u{25}\u{63}\u{0}\u{25}\u{63}\u{25}\u{78}\u{0}",string.byte("\u{e4}"),string.byte("\u{62}"),140) == "\u{0}\u{e4}\u{0}\u{62}\u{38}\u{63}\u{0}")
173+assert(string.format("\u{0}\u{25}\u{63}\u{0}\u{25}\u{63}\u{25}\u{78}\u{0}",string.byte("\u{e4}"),string.byte("\u{62}"),0x8c) == "\u{0}\u{e4}\u{0}\u{62}\u{38}\u{63}\u{0}")
174assert(string.format("") == "")
174assert(string.format("") == "")
175−assert(string.format("\u{25}\u{63}",34) .. string.format("\u{25}\u{63}",48) .. string.format("\u{25}\u{63}",90) .. string.format("\u{25}\u{63}",100) == string.format("\u{25}\u{31}\u{63}\u{25}\u{2d}\u{63}\u{25}\u{2d}\u{31}\u{63}\u{25}\u{63}",34,48,90,100))
175+assert(string.format("\u{25}\u{63}",0x22) .. string.format("\u{25}\u{63}",0x30) .. string.format("\u{25}\u{63}",0x5a) .. string.format("\u{25}\u{63}",0x64) == string.format("\u{25}\u{31}\u{63}\u{25}\u{2d}\u{63}\u{25}\u{2d}\u{31}\u{63}\u{25}\u{63}",0x22,0x30,0x5a,0x64))
176assert(string.format("\u{25}\u{73}\u{0}\u{20}\u{69}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{0}\u{25}\u{73}","\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}","\u{62}\u{65}") == "\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{0}\u{20}\u{69}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{0}\u{62}\u{65}")
176assert(string.format("\u{25}\u{73}\u{0}\u{20}\u{69}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{0}\u{25}\u{73}","\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}","\u{62}\u{65}") == "\u{6e}\u{6f}\u{74}\u{20}\u{62}\u{65}\u{0}\u{20}\u{69}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{0}\u{62}\u{65}")
177−assert(string.format("\u{25}\u{25}\u{25}\u{64}\u{20}\u{25}\u{30}\u{31}\u{30}\u{64}",10,23) == "\u{25}\u{31}\u{30}\u{20}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{32}\u{33}")
177+assert(string.format("\u{25}\u{25}\u{25}\u{64}\u{20}\u{25}\u{30}\u{31}\u{30}\u{64}",0xa,0x17) == "\u{25}\u{31}\u{30}\u{20}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{32}\u{33}")
178assert(tonumber(string.format("\u{25}\u{66}",10.3)) == 10.3)
178assert(tonumber(string.format("\u{25}\u{66}",10.3)) == 10.3)
179−assert(string.format("\u{22}\u{25}\u{2d}\u{35}\u{30}\u{73}\u{22}","\u{61}") == "\u{22}\u{61}" .. string.rep("\u{20}",49) .. "\u{22}")
179+assert(string.format("\u{22}\u{25}\u{2d}\u{35}\u{30}\u{73}\u{22}","\u{61}") == "\u{22}\u{61}" .. string.rep("\u{20}",0x31) .. "\u{22}")
180−assert(string.format("\u{2d}\u{25}\u{2e}\u{32}\u{30}\u{73}\u{2e}\u{32}\u{30}\u{73}",string.rep("\u{25}",2000)) == "\u{2d}" .. string.rep("\u{25}",20) .. "\u{2e}\u{32}\u{30}\u{73}")
180+assert(string.format("\u{2d}\u{25}\u{2e}\u{32}\u{30}\u{73}\u{2e}\u{32}\u{30}\u{73}",string.rep("\u{25}",0x7d0)) == "\u{2d}" .. string.rep("\u{25}",0x14) .. "\u{2e}\u{32}\u{30}\u{73}")
181−assert(string.format("\u{22}\u{2d}\u{25}\u{32}\u{30}\u{73}\u{2e}\u{32}\u{30}\u{73}\u{22}",string.rep("\u{25}",2000)) == string.format("\u{25}\u{71}","\u{2d}" .. string.rep("\u{25}",2000) .. "\u{2e}\u{32}\u{30}\u{73}"))
181+assert(string.format("\u{22}\u{2d}\u{25}\u{32}\u{30}\u{73}\u{2e}\u{32}\u{30}\u{73}\u{22}",string.rep("\u{25}",0x7d0)) == string.format("\u{25}\u{71}","\u{2d}" .. string.rep("\u{25}",0x7d0) .. "\u{2e}\u{32}\u{30}\u{73}"))
182do
182do
183local function checkQ
183local function checkQ
184(v)
184(v)
@@ -196,7 +196,7 @@ checkQ(nil)
196checkQ(false)
196checkQ(false)
197checkQ(math.huge)
197checkQ(math.huge)
198checkQ(- math.huge)
198checkQ(- math.huge)
199−assert(string.format("\u{25}\u{71}",0 / 0) == "\u{28}\u{30}\u{2f}\u{30}\u{29}")
199+assert(string.format("\u{25}\u{71}",0x0 / 0x0) == "\u{28}\u{30}\u{2f}\u{30}\u{29}")
200checkerror("\u{6e}\u{6f}\u{20}\u{6c}\u{69}\u{74}\u{65}\u{72}\u{61}\u{6c}",string.format,"\u{25}\u{71}",{})
200checkerror("\u{6e}\u{6f}\u{20}\u{6c}\u{69}\u{74}\u{65}\u{72}\u{61}\u{6c}",string.format,"\u{25}\u{71}",{})
201end
201end
202assert(string.format("\u{0}\u{25}\u{73}\u{0}","\u{0}\u{0}\u{1}") == "\u{0}\u{0}\u{0}\u{1}\u{0}")
202assert(string.format("\u{0}\u{25}\u{73}\u{0}","\u{0}\u{0}\u{1}") == "\u{0}\u{0}\u{0}\u{1}\u{0}")
@@ -216,50 +216,50 @@ end
216checkerror("\u{27}\u{5f}\u{5f}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{20}\u{6d}\u{75}\u{73}\u{74}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",tostring,m)
216checkerror("\u{27}\u{5f}\u{5f}\u{74}\u{6f}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{20}\u{6d}\u{75}\u{73}\u{74}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",tostring,m)
217assert(string.format("\u{25}\u{78}",0.0) == "\u{30}")
217assert(string.format("\u{25}\u{78}",0.0) == "\u{30}")
218assert(string.format("\u{25}\u{30}\u{32}\u{78}",0.0) == "\u{30}\u{30}")
218assert(string.format("\u{25}\u{30}\u{32}\u{78}",0.0) == "\u{30}\u{30}")
219−assert(string.format("\u{25}\u{30}\u{38}\u{58}",4294967295) == "\u{46}\u{46}\u{46}\u{46}\u{46}\u{46}\u{46}\u{46}")
219+assert(string.format("\u{25}\u{30}\u{38}\u{58}",0xffffffff) == "\u{46}\u{46}\u{46}\u{46}\u{46}\u{46}\u{46}\u{46}")
220−assert(string.format("\u{25}\u{2b}\u{30}\u{38}\u{64}",31501) == "\u{2b}\u{30}\u{30}\u{33}\u{31}\u{35}\u{30}\u{31}")
220+assert(string.format("\u{25}\u{2b}\u{30}\u{38}\u{64}",0x7b0d) == "\u{2b}\u{30}\u{30}\u{33}\u{31}\u{35}\u{30}\u{31}")
221−assert(string.format("\u{25}\u{2b}\u{30}\u{38}\u{64}",- 30927) == "\u{2d}\u{30}\u{30}\u{33}\u{30}\u{39}\u{32}\u{37}")
221+assert(string.format("\u{25}\u{2b}\u{30}\u{38}\u{64}",- 0x78cf) == "\u{2d}\u{30}\u{30}\u{33}\u{30}\u{39}\u{32}\u{37}")
222do
222do
223−local i = 1
223+local i = 0x1
224−local j = 10000
224+local j = 0x2710
225−while i + 1 < j do
225+while i + 0x1 < j do
226−local m = (i + j) // 2
226+local m = (i + j) // 0x2
227−if 10 ^ m < math.huge then
227+if 0xa ^ m < math.huge then
228i=m
228i=m
229else
229else
230j=m
230j=m
231end
231end
232end
232end
233−assert(10 ^ i < math.huge and 10 ^ j == math.huge)
233+assert(0xa ^ i < math.huge and 0xa ^ j == math.huge)
234−local s = string.format("\u{25}\u{2e}\u{39}\u{39}\u{66}",- (10 ^ i))
234+local s = string.format("\u{25}\u{2e}\u{39}\u{39}\u{66}",- (0xa ^ i))
235−assert(string.len(s) >= i + 101)
235+assert(string.len(s) >= i + 0x65)
236−assert(tonumber(s) == - (10 ^ i))
236+assert(tonumber(s) == - (0xa ^ i))
237−assert(10 ^ 38 < math.huge)
237+assert(0xa ^ 0x26 < math.huge)
238−local s = string.format("\u{25}\u{2e}\u{39}\u{39}\u{66}",- (10 ^ 38))
238+local s = string.format("\u{25}\u{2e}\u{39}\u{39}\u{66}",- (0xa ^ 0x26))
239−assert(string.len(s) >= 38 + 101)
239+assert(string.len(s) >= 0x26 + 0x65)
240−assert(tonumber(s) == - (10 ^ 38))
240+assert(tonumber(s) == - (0xa ^ 0x26))
241end
241end
242do
242do
243−local max,min = 2147483647,- 2147483648
243+local max,min = 0x7fffffff,- 0x80000000
244−assert(string.sub(string.format("\u{25}\u{38}\u{78}",- 1),- 8) == "\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
244+assert(string.sub(string.format("\u{25}\u{38}\u{78}",- 0x1),- 0x8) == "\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
245assert(string.format("\u{25}\u{78}",max) == "\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
245assert(string.format("\u{25}\u{78}",max) == "\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
246−assert(string.sub(string.format("\u{25}\u{78}",min),- 8) == "\u{38}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}")
246+assert(string.sub(string.format("\u{25}\u{78}",min),- 0x8) == "\u{38}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}")
247assert(string.format("\u{25}\u{64}",max) == "\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}")
247assert(string.format("\u{25}\u{64}",max) == "\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{37}")
248assert(string.format("\u{25}\u{64}",min) == "\u{2d}\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{38}")
248assert(string.format("\u{25}\u{64}",min) == "\u{2d}\u{32}\u{31}\u{34}\u{37}\u{34}\u{38}\u{33}\u{36}\u{34}\u{38}")
249−assert(string.format("\u{25}\u{75}",4294967295) == "\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{35}")
249+assert(string.format("\u{25}\u{75}",0xffffffff) == "\u{34}\u{32}\u{39}\u{34}\u{39}\u{36}\u{37}\u{32}\u{39}\u{35}")
250−assert(string.format("\u{25}\u{6f}",43981) == "\u{31}\u{32}\u{35}\u{37}\u{31}\u{35}")
250+assert(string.format("\u{25}\u{6f}",0xabcd) == "\u{31}\u{32}\u{35}\u{37}\u{31}\u{35}")
251−max,min=9223372036854775807,- 9223372036854775808
251+max,min=0x7fffffffffffffff,- 0x8000000000000000
252−if max > 2.0 ^ 53 then
252+if max > 2.0 ^ 0x35 then
253−assert(string.format("\u{25}\u{78}",(2 ^ 52 | 0) - 1) == "\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
253+assert(string.format("\u{25}\u{78}",(0x2 ^ 0x34 | 0x0) - 0x1) == "\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
254−assert(string.format("\u{30}\u{78}\u{25}\u{38}\u{58}",2399141891) == "\u{30}\u{78}\u{38}\u{46}\u{30}\u{30}\u{30}\u{30}\u{30}\u{33}")
254+assert(string.format("\u{30}\u{78}\u{25}\u{38}\u{58}",0x8f000003) == "\u{30}\u{78}\u{38}\u{46}\u{30}\u{30}\u{30}\u{30}\u{30}\u{33}")
255−assert(string.format("\u{25}\u{64}",2 ^ 53) == "\u{39}\u{30}\u{30}\u{37}\u{31}\u{39}\u{39}\u{32}\u{35}\u{34}\u{37}\u{34}\u{30}\u{39}\u{39}\u{32}")
255+assert(string.format("\u{25}\u{64}",0x2 ^ 0x35) == "\u{39}\u{30}\u{30}\u{37}\u{31}\u{39}\u{39}\u{32}\u{35}\u{34}\u{37}\u{34}\u{30}\u{39}\u{39}\u{32}")
256−assert(string.format("\u{25}\u{69}",- 2 ^ 53) == "\u{2d}\u{39}\u{30}\u{30}\u{37}\u{31}\u{39}\u{39}\u{32}\u{35}\u{34}\u{37}\u{34}\u{30}\u{39}\u{39}\u{32}")
256+assert(string.format("\u{25}\u{69}",- 0x2 ^ 0x35) == "\u{2d}\u{39}\u{30}\u{30}\u{37}\u{31}\u{39}\u{39}\u{32}\u{35}\u{34}\u{37}\u{34}\u{30}\u{39}\u{39}\u{32}")
257assert(string.format("\u{25}\u{78}",max) == "\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
257assert(string.format("\u{25}\u{78}",max) == "\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}")
258assert(string.format("\u{25}\u{78}",min) == "\u{38}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}")
258assert(string.format("\u{25}\u{78}",min) == "\u{38}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}")
259assert(string.format("\u{25}\u{64}",max) == "\u{39}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{37}\u{37}\u{35}\u{38}\u{30}\u{37}")
259assert(string.format("\u{25}\u{64}",max) == "\u{39}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{37}\u{37}\u{35}\u{38}\u{30}\u{37}")
260assert(string.format("\u{25}\u{64}",min) == "\u{2d}\u{39}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{37}\u{37}\u{35}\u{38}\u{30}\u{38}")
260assert(string.format("\u{25}\u{64}",min) == "\u{2d}\u{39}\u{32}\u{32}\u{33}\u{33}\u{37}\u{32}\u{30}\u{33}\u{36}\u{38}\u{35}\u{34}\u{37}\u{37}\u{35}\u{38}\u{30}\u{38}")
261−assert(string.format("\u{25}\u{75}",~ (- 1 << 64)) == "\u{31}\u{38}\u{34}\u{34}\u{36}\u{37}\u{34}\u{34}\u{30}\u{37}\u{33}\u{37}\u{30}\u{39}\u{35}\u{35}\u{31}\u{36}\u{31}\u{35}")
261+assert(string.format("\u{25}\u{75}",~ (- 0x1 << 0x40)) == "\u{31}\u{38}\u{34}\u{34}\u{36}\u{37}\u{34}\u{34}\u{30}\u{37}\u{33}\u{37}\u{30}\u{39}\u{35}\u{35}\u{31}\u{36}\u{31}\u{35}")
262−assert(tostring(1234567890123) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}")
262+assert(tostring(0x11f71fb04cb) == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{38}\u{39}\u{30}\u{31}\u{32}\u{33}")
263end
263end
264end
264end
265do
265do
@@ -273,43 +273,43 @@ s=string.format("\u{25}\u{41}",n)
273assert(string.find(s,"\u{5e}\u{25}\u{2d}\u{3f}\u{30}\u{58}\u{5b}\u{31}\u{2d}\u{39}\u{41}\u{2d}\u{46}\u{5d}\u{25}\u{2e}\u{3f}\u{5b}\u{30}\u{2d}\u{39}\u{41}\u{2d}\u{46}\u{5d}\u{2a}\u{50}\u{5b}\u{2d}\u{2b}\u{5d}\u{3f}\u{25}\u{64}\u{2b}\u{24}"))
273assert(string.find(s,"\u{5e}\u{25}\u{2d}\u{3f}\u{30}\u{58}\u{5b}\u{31}\u{2d}\u{39}\u{41}\u{2d}\u{46}\u{5d}\u{25}\u{2e}\u{3f}\u{5b}\u{30}\u{2d}\u{39}\u{41}\u{2d}\u{46}\u{5d}\u{2a}\u{50}\u{5b}\u{2d}\u{2b}\u{5d}\u{3f}\u{25}\u{64}\u{2b}\u{24}"))
274assert(tonumber(s) == n)
274assert(tonumber(s) == n)
275end
275end
276−for _,n in ipairs({0.1,- 0.1,1 / 3,- 1 / 3,1e30,- 1e30,- 45 / 247,1,- 1,2,- 2,3e-20,- 3e-20})
276+for _,n in ipairs({0.1,- 0.1,0x1 / 0x3,- 0x1 / 0x3,1e30,- 1e30,- 0x2d / 0xf7,0x1,- 0x1,0x2,- 0x2,3e-20,- 3e-20})
277do
277do
278matchhexa(n)
278matchhexa(n)
279end
279end
280assert(string.find(string.format("\u{25}\u{41}",0.0),"\u{5e}\u{30}\u{58}\u{30}\u{25}\u{2e}\u{3f}\u{30}\u{2a}\u{50}\u{25}\u{2b}\u{3f}\u{30}\u{24}"))
280assert(string.find(string.format("\u{25}\u{41}",0.0),"\u{5e}\u{30}\u{58}\u{30}\u{25}\u{2e}\u{3f}\u{30}\u{2a}\u{50}\u{25}\u{2b}\u{3f}\u{30}\u{24}"))
281assert(string.find(string.format("\u{25}\u{61}",- 0.0),"\u{5e}\u{25}\u{2d}\u{30}\u{78}\u{30}\u{25}\u{2e}\u{3f}\u{30}\u{2a}\u{70}\u{25}\u{2b}\u{3f}\u{30}\u{24}"))
281assert(string.find(string.format("\u{25}\u{61}",- 0.0),"\u{5e}\u{25}\u{2d}\u{30}\u{78}\u{30}\u{25}\u{2e}\u{3f}\u{30}\u{2a}\u{70}\u{25}\u{2b}\u{3f}\u{30}\u{24}"))
282if not _port then
282if not _port then
283−assert(string.find(string.format("\u{25}\u{61}",1 / 0),"\u{5e}\u{69}\u{6e}\u{66}"))
283+assert(string.find(string.format("\u{25}\u{61}",0x1 / 0x0),"\u{5e}\u{69}\u{6e}\u{66}"))
284−assert(string.find(string.format("\u{25}\u{41}",- 1 / 0),"\u{5e}\u{25}\u{2d}\u{49}\u{4e}\u{46}"))
284+assert(string.find(string.format("\u{25}\u{41}",- 0x1 / 0x0),"\u{5e}\u{25}\u{2d}\u{49}\u{4e}\u{46}"))
285−assert(string.find(string.format("\u{25}\u{61}",0 / 0),"\u{5e}\u{25}\u{2d}\u{3f}\u{6e}\u{61}\u{6e}"))
285+assert(string.find(string.format("\u{25}\u{61}",0x0 / 0x0),"\u{5e}\u{25}\u{2d}\u{3f}\u{6e}\u{61}\u{6e}"))
286assert(string.find(string.format("\u{25}\u{61}",- 0.0),"\u{5e}\u{25}\u{2d}\u{30}\u{78}\u{30}"))
286assert(string.find(string.format("\u{25}\u{61}",- 0.0),"\u{5e}\u{25}\u{2d}\u{30}\u{78}\u{30}"))
287end
287end
288−if not pcall(string.format,"\u{25}\u{2e}\u{33}\u{61}",0) then
288+if not pcall(string.format,"\u{25}\u{2e}\u{33}\u{61}",0x0) then
289(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{6d}\u{6f}\u{64}\u{69}\u{66}\u{69}\u{65}\u{72}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{20}\u{27}\u{25}\u{61}\u{27}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{76}\u{61}\u{69}\u{6c}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
289(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{6d}\u{6f}\u{64}\u{69}\u{66}\u{69}\u{65}\u{72}\u{73}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{20}\u{27}\u{25}\u{61}\u{27}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{76}\u{61}\u{69}\u{6c}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
290else
290else
291−assert(string.find(string.format("\u{25}\u{2b}\u{2e}\u{32}\u{41}",12),"\u{5e}\u{25}\u{2b}\u{30}\u{58}\u{25}\u{78}\u{25}\u{2e}\u{25}\u{78}\u{30}\u{50}\u{25}\u{2b}\u{3f}\u{25}\u{64}\u{24}"))
291+assert(string.find(string.format("\u{25}\u{2b}\u{2e}\u{32}\u{41}",0xc),"\u{5e}\u{25}\u{2b}\u{30}\u{58}\u{25}\u{78}\u{25}\u{2e}\u{25}\u{78}\u{30}\u{50}\u{25}\u{2b}\u{3f}\u{25}\u{64}\u{24}"))
292−assert(string.find(string.format("\u{25}\u{2e}\u{34}\u{41}",- 12),"\u{5e}\u{25}\u{2d}\u{30}\u{58}\u{25}\u{78}\u{25}\u{2e}\u{25}\u{78}\u{30}\u{30}\u{30}\u{50}\u{25}\u{2b}\u{3f}\u{25}\u{64}\u{24}"))
292+assert(string.find(string.format("\u{25}\u{2e}\u{34}\u{41}",- 0xc),"\u{5e}\u{25}\u{2d}\u{30}\u{58}\u{25}\u{78}\u{25}\u{2e}\u{25}\u{78}\u{30}\u{30}\u{30}\u{50}\u{25}\u{2b}\u{3f}\u{25}\u{64}\u{24}"))
293−end
293+end
294−end
294+end
295−assert(string.format("\u{25}\u{23}\u{31}\u{32}\u{6f}",10) == "\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{30}\u{31}\u{32}")
295+assert(string.format("\u{25}\u{23}\u{31}\u{32}\u{6f}",0xa) == "\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{30}\u{31}\u{32}")
296−assert(string.format("\u{25}\u{23}\u{31}\u{30}\u{78}",100) == "\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{30}\u{78}\u{36}\u{34}")
296+assert(string.format("\u{25}\u{23}\u{31}\u{30}\u{78}",0x64) == "\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{30}\u{78}\u{36}\u{34}")
297−assert(string.format("\u{25}\u{23}\u{2d}\u{31}\u{37}\u{58}",100) == "\u{30}\u{58}\u{36}\u{34}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}")
297+assert(string.format("\u{25}\u{23}\u{2d}\u{31}\u{37}\u{58}",0x64) == "\u{30}\u{58}\u{36}\u{34}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}")
298−assert(string.format("\u{25}\u{30}\u{31}\u{33}\u{69}",- 100) == "\u{2d}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}\u{30}\u{30}")
298+assert(string.format("\u{25}\u{30}\u{31}\u{33}\u{69}",- 0x64) == "\u{2d}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}\u{30}\u{30}")
299−assert(string.format("\u{25}\u{32}\u{2e}\u{35}\u{64}",- 100) == "\u{2d}\u{30}\u{30}\u{31}\u{30}\u{30}")
299+assert(string.format("\u{25}\u{32}\u{2e}\u{35}\u{64}",- 0x64) == "\u{2d}\u{30}\u{30}\u{31}\u{30}\u{30}")
300−assert(string.format("\u{25}\u{2e}\u{75}",0) == "")
300+assert(string.format("\u{25}\u{2e}\u{75}",0x0) == "")
301−assert(string.format("\u{25}\u{2b}\u{23}\u{30}\u{31}\u{34}\u{2e}\u{30}\u{66}",100) == "\u{2b}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}\u{30}\u{30}\u{2e}")
301+assert(string.format("\u{25}\u{2b}\u{23}\u{30}\u{31}\u{34}\u{2e}\u{30}\u{66}",0x64) == "\u{2b}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{31}\u{30}\u{30}\u{2e}")
302−assert(string.format("\u{25}\u{2d}\u{31}\u{36}\u{63}",97) == "\u{61}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}")
302+assert(string.format("\u{25}\u{2d}\u{31}\u{36}\u{63}",0x61) == "\u{61}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}\u{20}")
303assert(string.format("\u{25}\u{2b}\u{2e}\u{33}\u{47}",1.5) == "\u{2b}\u{31}\u{2e}\u{35}")
303assert(string.format("\u{25}\u{2b}\u{2e}\u{33}\u{47}",1.5) == "\u{2b}\u{31}\u{2e}\u{35}")
304assert(string.format("\u{25}\u{2e}\u{30}\u{73}","\u{61}\u{6c}\u{6f}") == "")
304assert(string.format("\u{25}\u{2e}\u{30}\u{73}","\u{61}\u{6c}\u{6f}") == "")
305assert(string.format("\u{25}\u{2e}\u{73}","\u{61}\u{6c}\u{6f}") == "")
305assert(string.format("\u{25}\u{2e}\u{73}","\u{61}\u{6c}\u{6f}") == "")
306−assert(string.match(string.format("\u{25}\u{20}\u{31}\u{2e}\u{30}\u{45}",100),"\u{5e}\u{20}\u{31}\u{45}\u{25}\u{2b}\u{30}\u{2b}\u{32}\u{24}"))
306+assert(string.match(string.format("\u{25}\u{20}\u{31}\u{2e}\u{30}\u{45}",0x64),"\u{5e}\u{20}\u{31}\u{45}\u{25}\u{2b}\u{30}\u{2b}\u{32}\u{24}"))
307−assert(string.match(string.format("\u{25}\u{20}\u{2e}\u{31}\u{67}",2 ^ 10),"\u{5e}\u{20}\u{31}\u{65}\u{25}\u{2b}\u{30}\u{2b}\u{33}\u{24}"))
307+assert(string.match(string.format("\u{25}\u{20}\u{2e}\u{31}\u{67}",0x2 ^ 0xa),"\u{5e}\u{20}\u{31}\u{65}\u{25}\u{2b}\u{30}\u{2b}\u{33}\u{24}"))
308local function check
308local function check
309(fmt,msg)
309(fmt,msg)
310−checkerror(msg,string.format,fmt,10)
310+checkerror(msg,string.format,fmt,0xa)
311end
311end
312−local aux = string.rep("\u{30}",600)
312+local aux = string.rep("\u{30}",0x258)
313check("\u{25}\u{31}\u{30}\u{30}\u{2e}\u{33}\u{64}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
313check("\u{25}\u{31}\u{30}\u{30}\u{2e}\u{33}\u{64}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
314check("\u{25}\u{31}" .. aux .. "\u{2e}\u{33}\u{64}","\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{6f}\u{6e}\u{67}")
314check("\u{25}\u{31}" .. aux .. "\u{2e}\u{33}\u{64}","\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{6f}\u{6e}\u{67}")
315check("\u{25}\u{31}\u{2e}\u{31}\u{30}\u{30}\u{64}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
315check("\u{25}\u{31}\u{2e}\u{31}\u{30}\u{30}\u{64}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
@@ -325,8 +325,8 @@ check("\u{25}\u{33}\u{2e}\u{31}\u{70}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{6
325check("\u{25}\u{30}\u{2e}\u{73}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
325check("\u{25}\u{30}\u{2e}\u{73}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
326check("\u{25}\u{31}\u{30}\u{71}","\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{61}\u{76}\u{65}\u{20}\u{6d}\u{6f}\u{64}\u{69}\u{66}\u{69}\u{65}\u{72}\u{73}")
326check("\u{25}\u{31}\u{30}\u{71}","\u{63}\u{61}\u{6e}\u{6e}\u{6f}\u{74}\u{20}\u{68}\u{61}\u{76}\u{65}\u{20}\u{6d}\u{6f}\u{64}\u{69}\u{66}\u{69}\u{65}\u{72}\u{73}")
327check("\u{25}\u{46}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
327check("\u{25}\u{46}","\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{63}\u{6f}\u{6e}\u{76}\u{65}\u{72}\u{73}\u{69}\u{6f}\u{6e}")
328−assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}\u{2d}\u{2d}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{65}\u{6e}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{45}\u{4f}\u{4c}")() == 1)
328+assert(load("\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{a}\u{2d}\u{2d}\u{63}\u{6f}\u{6d}\u{6d}\u{65}\u{6e}\u{74}\u{20}\u{77}\u{69}\u{74}\u{68}\u{6f}\u{75}\u{74}\u{20}\u{65}\u{6e}\u{64}\u{69}\u{6e}\u{67}\u{20}\u{45}\u{4f}\u{4c}")() == 0x1)
329−checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.concat,3)
329+checkerror("\u{74}\u{61}\u{62}\u{6c}\u{65}\u{20}\u{65}\u{78}\u{70}\u{65}\u{63}\u{74}\u{65}\u{64}",table.concat,0x3)
330checkerror("\u{61}\u{74}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}" .. maxi,table.concat,{},"\u{20}",maxi,maxi)
330checkerror("\u{61}\u{74}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}" .. maxi,table.concat,{},"\u{20}",maxi,maxi)
331checkerror("\u{61}\u{74}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{25}" .. mini,table.concat,{},"\u{20}",mini,mini)
331checkerror("\u{61}\u{74}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{20}\u{25}" .. mini,table.concat,{},"\u{20}",mini,mini)
332assert(table.concat({}) == "")
332assert(table.concat({}) == "")
@@ -334,33 +334,33 @@ assert(table.concat({},"\u{78}") == "")
334assert(table.concat({"\u{0}","\u{0}\u{1}","\u{0}\u{1}\u{2}"},"\u{2e}\u{0}\u{2e}") == "\u{0}\u{2e}\u{0}\u{2e}\u{0}\u{1}\u{2e}\u{0}\u{2e}\u{0}\u{1}\u{2}")
334assert(table.concat({"\u{0}","\u{0}\u{1}","\u{0}\u{1}\u{2}"},"\u{2e}\u{0}\u{2e}") == "\u{0}\u{2e}\u{0}\u{2e}\u{0}\u{1}\u{2e}\u{0}\u{2e}\u{0}\u{1}\u{2}")
335local a = {}
335local a = {}
336;
336;
337−for i = 1, 300
337+for i = 0x1, 0x12c
338do
338do
339a[i]="\u{78}\u{75}\u{78}\u{75}"
339a[i]="\u{78}\u{75}\u{78}\u{75}"
340end
340end
341−assert(table.concat(a,"\u{31}\u{32}\u{33}") .. "\u{31}\u{32}\u{33}" == string.rep("\u{78}\u{75}\u{78}\u{75}\u{31}\u{32}\u{33}",300))
341+assert(table.concat(a,"\u{31}\u{32}\u{33}") .. "\u{31}\u{32}\u{33}" == string.rep("\u{78}\u{75}\u{78}\u{75}\u{31}\u{32}\u{33}",0x12c))
342−assert(table.concat(a,"\u{62}",20,20) == "\u{78}\u{75}\u{78}\u{75}")
342+assert(table.concat(a,"\u{62}",0x14,0x14) == "\u{78}\u{75}\u{78}\u{75}")
343−assert(table.concat(a,"",20,21) == "\u{78}\u{75}\u{78}\u{75}\u{78}\u{75}\u{78}\u{75}")
343+assert(table.concat(a,"",0x14,0x15) == "\u{78}\u{75}\u{78}\u{75}\u{78}\u{75}\u{78}\u{75}")
344−assert(table.concat(a,"\u{78}",22,21) == "")
344+assert(table.concat(a,"\u{78}",0x16,0x15) == "")
345−assert(table.concat(a,"\u{33}",299) == "\u{78}\u{75}\u{78}\u{75}\u{33}\u{78}\u{75}\u{78}\u{75}")
345+assert(table.concat(a,"\u{33}",0x12b) == "\u{78}\u{75}\u{78}\u{75}\u{33}\u{78}\u{75}\u{78}\u{75}")
346−assert(table.concat({},"\u{78}",maxi,maxi - 1) == "")
346+assert(table.concat({},"\u{78}",maxi,maxi - 0x1) == "")
347−assert(table.concat({},"\u{78}",mini + 1,mini) == "")
347+assert(table.concat({},"\u{78}",mini + 0x1,mini) == "")
348assert(table.concat({},"\u{78}",maxi,mini) == "")
348assert(table.concat({},"\u{78}",maxi,mini) == "")
349assert(table.concat({[maxi] = "\u{61}\u{6c}\u{6f}"},"\u{78}",maxi,maxi) == "\u{61}\u{6c}\u{6f}")
349assert(table.concat({[maxi] = "\u{61}\u{6c}\u{6f}"},"\u{78}",maxi,maxi) == "\u{61}\u{6c}\u{6f}")
350−assert(table.concat({[maxi] = "\u{61}\u{6c}\u{6f}",[maxi - 1] = "\u{79}"},"\u{2d}",maxi - 1,maxi) == "\u{79}\u{2d}\u{61}\u{6c}\u{6f}")
350+assert(table.concat({[maxi] = "\u{61}\u{6c}\u{6f}",[maxi - 0x1] = "\u{79}"},"\u{2d}",maxi - 0x1,maxi) == "\u{79}\u{2d}\u{61}\u{6c}\u{6f}")
351assert(not pcall(table.concat,{"\u{61}","\u{62}",{}}))
351assert(not pcall(table.concat,{"\u{61}","\u{62}",{}}))
352a={"\u{61}","\u{62}","\u{63}"}
352a={"\u{61}","\u{62}","\u{63}"}
353−assert(table.concat(a,"\u{2c}",1,0) == "")
353+assert(table.concat(a,"\u{2c}",0x1,0x0) == "")
354−assert(table.concat(a,"\u{2c}",1,1) == "\u{61}")
354+assert(table.concat(a,"\u{2c}",0x1,0x1) == "\u{61}")
355−assert(table.concat(a,"\u{2c}",1,2) == "\u{61}\u{2c}\u{62}")
355+assert(table.concat(a,"\u{2c}",0x1,0x2) == "\u{61}\u{2c}\u{62}")
356−assert(table.concat(a,"\u{2c}",2) == "\u{62}\u{2c}\u{63}")
356+assert(table.concat(a,"\u{2c}",0x2) == "\u{62}\u{2c}\u{63}")
357−assert(table.concat(a,"\u{2c}",3) == "\u{63}")
357+assert(table.concat(a,"\u{2c}",0x3) == "\u{63}")
358−assert(table.concat(a,"\u{2c}",4) == "")
358+assert(table.concat(a,"\u{2c}",0x4) == "")
359if not _port then
359if not _port then
360local locales = {"\u{70}\u{74}\u{62}","\u{70}\u{74}\u{5f}\u{42}\u{52}\u{2e}\u{69}\u{73}\u{6f}\u{38}\u{38}\u{35}\u{39}\u{31}","\u{49}\u{53}\u{4f}\u{2d}\u{38}\u{38}\u{35}\u{39}\u{2d}\u{31}"}
360local locales = {"\u{70}\u{74}\u{62}","\u{70}\u{74}\u{5f}\u{42}\u{52}\u{2e}\u{69}\u{73}\u{6f}\u{38}\u{38}\u{35}\u{39}\u{31}","\u{49}\u{53}\u{4f}\u{2d}\u{38}\u{38}\u{35}\u{39}\u{2d}\u{31}"}
361local function trylocale
361local function trylocale
362(w)
362(w)
363−for i = 1, # locales
363+for i = 0x1, # locales
364do
364do
365if os.setlocale(locales[i],w) then
365if os.setlocale(locales[i],w) then
366print(string.format("\u{27}\u{25}\u{73}\u{27}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{65}\u{20}\u{73}\u{65}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{27}\u{25}\u{73}\u{27}",w,locales[i]))
366print(string.format("\u{27}\u{25}\u{73}\u{27}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{65}\u{20}\u{73}\u{65}\u{74}\u{20}\u{74}\u{6f}\u{20}\u{27}\u{25}\u{73}\u{27}",w,locales[i]))
@@ -393,36 +393,36 @@ if T == nil then
393(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{70}\u{75}\u{73}\u{68}\u{66}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
393(Message or print)("\u{a}\u{20}\u{3e}\u{3e}\u{3e}\u{20}\u{74}\u{65}\u{73}\u{74}\u{43}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{61}\u{63}\u{74}\u{69}\u{76}\u{65}\u{3a}\u{20}\u{73}\u{6b}\u{69}\u{70}\u{70}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{70}\u{75}\u{73}\u{68}\u{66}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}\u{20}\u{74}\u{65}\u{73}\u{74}\u{73}\u{20}\u{3c}\u{3c}\u{3c}\u{a}")
394else
394else
395print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{70}\u{75}\u{73}\u{68}\u{66}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}")
395print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{27}\u{70}\u{75}\u{73}\u{68}\u{66}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{27}")
396−local blen = 200
396+local blen = 0xc8
397local function callpfs
397local function callpfs
398(op,fmt,n)
398(op,fmt,n)
399local x = {T.testC("\u{70}\u{75}\u{73}\u{68}\u{66}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" .. op .. "\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",fmt,n)}
399local x = {T.testC("\u{70}\u{75}\u{73}\u{68}\u{66}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}" .. op .. "\u{3b}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{2a}",fmt,n)}
400−assert(# x == 4)
400+assert(# x == 0x4)
401−return x[4]
401+return x[0x4]
402end
402end
403local function testpfs
403local function testpfs
404(op,fmt,n)
404(op,fmt,n)
405assert(callpfs(op,fmt,n) == string.format(fmt,n))
405assert(callpfs(op,fmt,n) == string.format(fmt,n))
406end
406end
407−testpfs("\u{49}","",0)
407+testpfs("\u{49}","",0x0)
408−testpfs("\u{49}",string.rep("\u{61}",blen - 1),0)
408+testpfs("\u{49}",string.rep("\u{61}",blen - 0x1),0x0)
409−testpfs("\u{49}",string.rep("\u{61}",blen),0)
409+testpfs("\u{49}",string.rep("\u{61}",blen),0x0)
410−testpfs("\u{49}",string.rep("\u{61}",blen + 1),0)
410+testpfs("\u{49}",string.rep("\u{61}",blen + 0x1),0x0)
411−local str = string.rep("\u{61}\u{62}",blen) .. "\u{25}\u{64}" .. string.rep("\u{64}",blen / 2)
411+local str = string.rep("\u{61}\u{62}",blen) .. "\u{25}\u{64}" .. string.rep("\u{64}",blen / 0x2)
412−testpfs("\u{49}",str,2 ^ 14)
412+testpfs("\u{49}",str,0x2 ^ 0xe)
413−testpfs("\u{49}",str,- 2 ^ 15)
413+testpfs("\u{49}",str,- 0x2 ^ 0xf)
414str="\u{25}\u{64}" .. string.rep("\u{63}\u{64}",blen)
414str="\u{25}\u{64}" .. string.rep("\u{63}\u{64}",blen)
415−testpfs("\u{49}",str,2 ^ 14)
415+testpfs("\u{49}",str,0x2 ^ 0xe)
416−testpfs("\u{49}",str,- 2 ^ 15)
416+testpfs("\u{49}",str,- 0x2 ^ 0xf)
417−str=string.rep("\u{63}",blen - 2) .. "\u{25}\u{64}"
417+str=string.rep("\u{63}",blen - 0x2) .. "\u{25}\u{64}"
418−testpfs("\u{49}",str,2 ^ 14)
418+testpfs("\u{49}",str,0x2 ^ 0xe)
419−testpfs("\u{49}",str,- 2 ^ 15)
419+testpfs("\u{49}",str,- 0x2 ^ 0xf)
420−for l = 12, 14
420+for l = 0xc, 0xe
421do
421do
422local str1 = string.rep("\u{61}",l)
422local str1 = string.rep("\u{61}",l)
423−for i = 0, 500, 13
423+for i = 0x0, 0x1f4, 0xd
424do
424do
425−for j = 0, 500, 13
425+for j = 0x0, 0x1f4, 0xd
426do
426do
427str=string.rep("\u{61}",i) .. "\u{25}\u{73}" .. string.rep("\u{64}",j)
427str=string.rep("\u{61}",i) .. "\u{25}\u{73}" .. string.rep("\u{64}",j)
428testpfs("\u{53}",str,str1)
428testpfs("\u{53}",str,str1)
@@ -432,10 +432,10 @@ end
432end
432end
433str="\u{61}\u{62}\u{63}\u{20}\u{25}\u{63}\u{20}\u{64}\u{65}\u{66}"
433str="\u{61}\u{62}\u{63}\u{20}\u{25}\u{63}\u{20}\u{64}\u{65}\u{66}"
434testpfs("\u{49}",str,string.byte("\u{41}"))
434testpfs("\u{49}",str,string.byte("\u{41}"))
435−testpfs("\u{49}",str,255)
435+testpfs("\u{49}",str,0xff)
436−str=string.rep("\u{61}",blen - 1) .. "\u{25}\u{70}" .. string.rep("\u{63}\u{64}",blen)
436+str=string.rep("\u{61}",blen - 0x1) .. "\u{25}\u{70}" .. string.rep("\u{63}\u{64}",blen)
437testpfs("\u{50}",str,{})
437testpfs("\u{50}",str,{})
438−str=string.rep("\u{25}\u{25}",3 * blen) .. "\u{25}\u{70}" .. string.rep("\u{25}\u{25}",2 * blen)
438+str=string.rep("\u{25}\u{25}",0x3 * blen) .. "\u{25}\u{70}" .. string.rep("\u{25}\u{25}",0x2 * blen)
439testpfs("\u{50}",str,{})
439testpfs("\u{50}",str,{})
440end
440end
441print("\u{4f}\u{4b}")
441print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/tpack.lua+105−105
@@ -2,7 +2,7 @@ local pack = string.pack
2local packsize = string.packsize
2local packsize = string.packsize
3local unpack = string.unpack
3local unpack = string.unpack
4print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}\u{2f}\u{75}\u{6e}\u{70}\u{61}\u{63}\u{6b}")
4print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}\u{2f}\u{75}\u{6e}\u{70}\u{61}\u{63}\u{6b}")
5−local NB = 16
5+local NB = 0x10
6local sizeshort = packsize("\u{68}")
6local sizeshort = packsize("\u{68}")
7local sizeint = packsize("\u{69}")
7local sizeint = packsize("\u{69}")
8local sizelong = packsize("\u{6c}")
8local sizelong = packsize("\u{6c}")
@@ -11,9 +11,9 @@ local sizeLI = packsize("\u{6a}")
11local sizefloat = packsize("\u{66}")
11local sizefloat = packsize("\u{66}")
12local sizedouble = packsize("\u{64}")
12local sizedouble = packsize("\u{64}")
13local sizenumber = packsize("\u{6e}")
13local sizenumber = packsize("\u{6e}")
14−local little = (pack("\u{69}\u{32}",1) == "\u{1}\u{0}")
14+local little = (pack("\u{69}\u{32}",0x1) == "\u{1}\u{0}")
15local align = packsize("\u{21}\u{78}\u{58}\u{69}\u{31}\u{36}")
15local align = packsize("\u{21}\u{78}\u{58}\u{69}\u{31}\u{36}")
16−assert(1 <= sizeshort and sizeshort <= sizeint and sizeint <= sizelong and sizefloat <= sizedouble)
16+assert(0x1 <= sizeshort and sizeshort <= sizeint and sizeint <= sizelong and sizefloat <= sizedouble)
17print("\u{70}\u{6c}\u{61}\u{74}\u{66}\u{6f}\u{72}\u{6d}\u{3a}")
17print("\u{70}\u{6c}\u{61}\u{74}\u{66}\u{6f}\u{72}\u{6d}\u{3a}")
18print(string.format("\u{9}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{69}\u{6e}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{5f}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{64}\u{6f}\u{75}\u{62}\u{6c}\u{65}\u{20}\u{25}\u{64}\u{2c}\u{a}\u{9}\u{6c}\u{75}\u{61}\u{20}\u{49}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{6c}\u{75}\u{61}\u{20}\u{4e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{25}\u{64}",sizeshort,sizeint,sizelong,sizesize_t,sizefloat,sizedouble,sizeLI,sizenumber))
18print(string.format("\u{9}\u{73}\u{68}\u{6f}\u{72}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{69}\u{6e}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{6c}\u{6f}\u{6e}\u{67}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{73}\u{69}\u{7a}\u{65}\u{5f}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{64}\u{6f}\u{75}\u{62}\u{6c}\u{65}\u{20}\u{25}\u{64}\u{2c}\u{a}\u{9}\u{6c}\u{75}\u{61}\u{20}\u{49}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}\u{20}\u{25}\u{64}\u{2c}\u{20}\u{6c}\u{75}\u{61}\u{20}\u{4e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{20}\u{25}\u{64}",sizeshort,sizeint,sizelong,sizesize_t,sizefloat,sizedouble,sizeLI,sizenumber))
19print("\u{9}" .. (little and "\u{6c}\u{69}\u{74}\u{74}\u{6c}\u{65}" or "\u{62}\u{69}\u{67}") .. "\u{20}\u{65}\u{6e}\u{64}\u{69}\u{61}\u{6e}")
19print("\u{9}" .. (little and "\u{6c}\u{69}\u{74}\u{74}\u{6c}\u{65}" or "\u{62}\u{69}\u{67}") .. "\u{20}\u{65}\u{6e}\u{64}\u{69}\u{61}\u{6e}")
@@ -23,113 +23,113 @@ local function checkerror
23local status,err = pcall(f,...)
23local status,err = pcall(f,...)
24assert(not status and string.find(err,msg))
24assert(not status and string.find(err,msg))
25end
25end
26−assert(unpack("\u{42}",pack("\u{42}",255)) == 255)
26+assert(unpack("\u{42}",pack("\u{42}",0xff)) == 0xff)
27−assert(unpack("\u{62}",pack("\u{62}",127)) == 127)
27+assert(unpack("\u{62}",pack("\u{62}",0x7f)) == 0x7f)
28−assert(unpack("\u{62}",pack("\u{62}",- 128)) == - 128)
28+assert(unpack("\u{62}",pack("\u{62}",- 0x80)) == - 0x80)
29−assert(unpack("\u{48}",pack("\u{48}",65535)) == 65535)
29+assert(unpack("\u{48}",pack("\u{48}",0xffff)) == 0xffff)
30−assert(unpack("\u{68}",pack("\u{68}",32767)) == 32767)
30+assert(unpack("\u{68}",pack("\u{68}",0x7fff)) == 0x7fff)
31−assert(unpack("\u{68}",pack("\u{68}",- 32768)) == - 32768)
31+assert(unpack("\u{68}",pack("\u{68}",- 0x8000)) == - 0x8000)
32−assert(unpack("\u{4c}",pack("\u{4c}",4294967295)) == 4294967295)
32+assert(unpack("\u{4c}",pack("\u{4c}",0xffffffff)) == 0xffffffff)
33−assert(unpack("\u{6c}",pack("\u{6c}",2147483647)) == 2147483647)
33+assert(unpack("\u{6c}",pack("\u{6c}",0x7fffffff)) == 0x7fffffff)
34−assert(unpack("\u{6c}",pack("\u{6c}",- 2147483648)) == - 2147483648)
34+assert(unpack("\u{6c}",pack("\u{6c}",- 0x80000000)) == - 0x80000000)
35−for i = 1, NB
35+for i = 0x1, NB
36do
36do
37local s = string.rep("\u{ff}",i)
37local s = string.rep("\u{ff}",i)
38−assert(pack("\u{69}" .. i,- 1) == s)
38+assert(pack("\u{69}" .. i,- 0x1) == s)
39assert(packsize("\u{69}" .. i) == # s)
39assert(packsize("\u{69}" .. i) == # s)
40−assert(unpack("\u{69}" .. i,s) == - 1)
40+assert(unpack("\u{69}" .. i,s) == - 0x1)
41−s="\u{aa}" .. string.rep("\u{0}",i - 1)
41+s="\u{aa}" .. string.rep("\u{0}",i - 0x1)
42−assert(pack("\u{3c}\u{49}" .. i,170) == s)
42+assert(pack("\u{3c}\u{49}" .. i,0xaa) == s)
43−assert(unpack("\u{3c}\u{49}" .. i,s) == 170)
43+assert(unpack("\u{3c}\u{49}" .. i,s) == 0xaa)
44−assert(pack("\u{3e}\u{49}" .. i,170) == s:reverse())
44+assert(pack("\u{3e}\u{49}" .. i,0xaa) == s:reverse())
45−assert(unpack("\u{3e}\u{49}" .. i,s:reverse()) == 170)
45+assert(unpack("\u{3e}\u{49}" .. i,s:reverse()) == 0xaa)
46end
46end
47do
47do
48−local lnum = 1510926445411202934483812811265
48+local lnum = 0x807060504030201
49local s = pack("\u{3c}\u{6a}",lnum)
49local s = pack("\u{3c}\u{6a}",lnum)
50assert(unpack("\u{3c}\u{6a}",s) == lnum)
50assert(unpack("\u{3c}\u{6a}",s) == lnum)
51−assert(unpack("\u{3c}\u{69}" .. sizeLI + 1,s .. "\u{0}") == lnum)
51+assert(unpack("\u{3c}\u{69}" .. sizeLI + 0x1,s .. "\u{0}") == lnum)
52−assert(unpack("\u{3c}\u{69}" .. sizeLI + 1,s .. "\u{0}") == lnum)
52+assert(unpack("\u{3c}\u{69}" .. sizeLI + 0x1,s .. "\u{0}") == lnum)
53−for i = sizeLI + 1, NB
53+for i = sizeLI + 0x1, NB
54do
54do
55local s = pack("\u{3c}\u{6a}",- lnum)
55local s = pack("\u{3c}\u{6a}",- lnum)
56assert(unpack("\u{3c}\u{6a}",s) == - lnum)
56assert(unpack("\u{3c}\u{6a}",s) == - lnum)
57assert(unpack("\u{3c}\u{69}" .. i,s .. ("\u{ff}"):rep(i - sizeLI)) == - lnum)
57assert(unpack("\u{3c}\u{69}" .. i,s .. ("\u{ff}"):rep(i - sizeLI)) == - lnum)
58assert(unpack("\u{3e}\u{69}" .. i,("\u{ff}"):rep(i - sizeLI) .. s:reverse()) == - lnum)
58assert(unpack("\u{3e}\u{69}" .. i,("\u{ff}"):rep(i - sizeLI) .. s:reverse()) == - lnum)
59assert(unpack("\u{3c}\u{49}" .. i,s .. ("\u{0}"):rep(i - sizeLI)) == - lnum)
59assert(unpack("\u{3c}\u{49}" .. i,s .. ("\u{0}"):rep(i - sizeLI)) == - lnum)
60−checkerror("\u{64}\u{6f}\u{65}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{69}\u{74}",unpack,"\u{3c}\u{49}" .. i,("\u{0}"):rep(i - 1) .. "\u{1}")
60+checkerror("\u{64}\u{6f}\u{65}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{69}\u{74}",unpack,"\u{3c}\u{49}" .. i,("\u{0}"):rep(i - 0x1) .. "\u{1}")
61−checkerror("\u{64}\u{6f}\u{65}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{69}\u{74}",unpack,"\u{3e}\u{69}" .. i,"\u{1}" .. ("\u{0}"):rep(i - 1))
61+checkerror("\u{64}\u{6f}\u{65}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{69}\u{74}",unpack,"\u{3e}\u{69}" .. i,"\u{1}" .. ("\u{0}"):rep(i - 0x1))
62end
62end
63end
63end
64−for i = 1, sizeLI
64+for i = 0x1, sizeLI
65do
65do
66local lstr = "\u{1}\u{2}\u{3}\u{4}\u{5}\u{6}\u{7}\u{8}\u{9}\u{a}\u{b}\u{c}\u{d}"
66local lstr = "\u{1}\u{2}\u{3}\u{4}\u{5}\u{6}\u{7}\u{8}\u{9}\u{a}\u{b}\u{c}\u{d}"
67−local lnum = 1510926445411202934483812811265
67+local lnum = 0x807060504030201
68−local n = lnum & (~ (- 1 << (i * 8)))
68+local n = lnum & (~ (- 0x1 << (i * 0x8)))
69−local s = string.sub(lstr,1,i)
69+local s = string.sub(lstr,0x1,i)
70assert(pack("\u{3c}\u{69}" .. i,n) == s)
70assert(pack("\u{3c}\u{69}" .. i,n) == s)
71assert(pack("\u{3e}\u{69}" .. i,n) == s:reverse())
71assert(pack("\u{3e}\u{69}" .. i,n) == s:reverse())
72assert(unpack("\u{3e}\u{69}" .. i,s:reverse()) == n)
72assert(unpack("\u{3e}\u{69}" .. i,s:reverse()) == n)
73end
73end
74do
74do
75−local u = 240
75+local u = 0xf0
76−for i = 1, sizeLI - 1
76+for i = 0x1, sizeLI - 0x1
77do
77do
78−assert(unpack("\u{3c}\u{69}" .. i,"\u{f0}" .. ("\u{ff}"):rep(i - 1)) == - 16)
78+assert(unpack("\u{3c}\u{69}" .. i,"\u{f0}" .. ("\u{ff}"):rep(i - 0x1)) == - 0x10)
79−assert(unpack("\u{3e}\u{49}" .. i,"\u{f0}" .. ("\u{ff}"):rep(i - 1)) == u)
79+assert(unpack("\u{3e}\u{49}" .. i,"\u{f0}" .. ("\u{ff}"):rep(i - 0x1)) == u)
80−u=u * 256 + 255
80+u=u * 0x100 + 0xff
81end
81end
82end
82end
83do
83do
84−assert(pack("\u{3e}\u{69}\u{32}\u{20}\u{3c}\u{69}\u{32}",10,20) == "\u{0}\u{a}\u{14}\u{0}")
84+assert(pack("\u{3e}\u{69}\u{32}\u{20}\u{3c}\u{69}\u{32}",0xa,0x14) == "\u{0}\u{a}\u{14}\u{0}")
85local a,b = unpack("\u{3c}\u{69}\u{32}\u{20}\u{3e}\u{69}\u{32}","\u{a}\u{0}\u{0}\u{14}")
85local a,b = unpack("\u{3c}\u{69}\u{32}\u{20}\u{3e}\u{69}\u{32}","\u{a}\u{0}\u{0}\u{14}")
86−assert(a == 10 and b == 20)
86+assert(a == 0xa and b == 0x14)
87−assert(pack("\u{3d}\u{69}\u{34}",2001) == pack("\u{69}\u{34}",2001))
87+assert(pack("\u{3d}\u{69}\u{34}",0x7d1) == pack("\u{69}\u{34}",0x7d1))
88end
88end
89print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{73}")
89print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{73}")
90−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{69}\u{30}",0)
90+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{69}\u{30}",0x0)
91−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{69}" .. NB + 1,0)
91+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{69}" .. NB + 0x1,0x0)
92−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{21}" .. NB + 1,0)
92+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{21}" .. NB + 0x1,0x0)
93−checkerror("\u{25}\u{28}\u{31}\u{37}\u{25}\u{29}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}\u{20}\u{25}\u{5b}\u{31}\u{2c}\u{31}\u{36}\u{25}\u{5d}",pack,"\u{58}\u{69}" .. NB + 1)
93+checkerror("\u{25}\u{28}\u{31}\u{37}\u{25}\u{29}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}\u{20}\u{25}\u{5b}\u{31}\u{2c}\u{31}\u{36}\u{25}\u{5d}",pack,"\u{58}\u{69}" .. NB + 0x1)
94−checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{27}\u{72}\u{27}",pack,"\u{69}\u{33}\u{72}",0)
94+checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{27}\u{72}\u{27}",pack,"\u{69}\u{33}\u{72}",0x0)
95−checkerror("\u{31}\u{36}\u{25}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",unpack,"\u{69}\u{31}\u{36}",string.rep("\u{3}",16))
95+checkerror("\u{31}\u{36}\u{25}\u{2d}\u{62}\u{79}\u{74}\u{65}\u{20}\u{69}\u{6e}\u{74}\u{65}\u{67}\u{65}\u{72}",unpack,"\u{69}\u{31}\u{36}",string.rep("\u{3}",0x10))
96−checkerror("\u{6e}\u{6f}\u{74}\u{20}\u{70}\u{6f}\u{77}\u{65}\u{72}\u{20}\u{6f}\u{66}\u{20}\u{32}",pack,"\u{21}\u{34}\u{69}\u{33}",0)
96+checkerror("\u{6e}\u{6f}\u{74}\u{20}\u{70}\u{6f}\u{77}\u{65}\u{72}\u{20}\u{6f}\u{66}\u{20}\u{32}",pack,"\u{21}\u{34}\u{69}\u{33}",0x0)
97;
97;
98checkerror("\u{6d}\u{69}\u{73}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{69}\u{7a}\u{65}",pack,"\u{63}","")
98checkerror("\u{6d}\u{69}\u{73}\u{73}\u{69}\u{6e}\u{67}\u{20}\u{73}\u{69}\u{7a}\u{65}",pack,"\u{63}","")
99checkerror("\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{25}\u{2d}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",packsize,"\u{73}")
99checkerror("\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{25}\u{2d}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",packsize,"\u{73}")
100checkerror("\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{25}\u{2d}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",packsize,"\u{7a}")
100checkerror("\u{76}\u{61}\u{72}\u{69}\u{61}\u{62}\u{6c}\u{65}\u{25}\u{2d}\u{6c}\u{65}\u{6e}\u{67}\u{74}\u{68}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",packsize,"\u{7a}")
101−checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",packsize,"\u{63}\u{31}" .. string.rep("\u{30}",40))
101+checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{66}\u{6f}\u{72}\u{6d}\u{61}\u{74}",packsize,"\u{63}\u{31}" .. string.rep("\u{30}",0x28))
102−if packsize("\u{69}") == 4 then
102+if packsize("\u{69}") == 0x4 then
103−local s = string.rep("\u{63}\u{32}\u{36}\u{38}\u{34}\u{33}\u{35}\u{34}\u{35}\u{36}",2 ^ 3)
103+local s = string.rep("\u{63}\u{32}\u{36}\u{38}\u{34}\u{33}\u{35}\u{34}\u{35}\u{36}",0x2 ^ 0x3)
104checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}",packsize,s)
104checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}",packsize,s)
105−s=string.rep("\u{63}\u{32}\u{36}\u{38}\u{34}\u{33}\u{35}\u{34}\u{35}\u{36}",2 ^ 3 - 1) .. "\u{63}\u{32}\u{36}\u{38}\u{34}\u{33}\u{35}\u{34}\u{35}\u{35}"
105+s=string.rep("\u{63}\u{32}\u{36}\u{38}\u{34}\u{33}\u{35}\u{34}\u{35}\u{36}",0x2 ^ 0x3 - 0x1) .. "\u{63}\u{32}\u{36}\u{38}\u{34}\u{33}\u{35}\u{34}\u{35}\u{35}"
106−assert(packsize(s) == 2147483647)
106+assert(packsize(s) == 0x7fffffff)
107end
107end
108−for i = 1, sizeLI - 1
108+for i = 0x1, sizeLI - 0x1
109do
109do
110−local umax = (1 << (i * 8)) - 1
110+local umax = (0x1 << (i * 0x8)) - 0x1
111−local max = umax >> 1
111+local max = umax >> 0x1
112local min = ~ max
112local min = ~ max
113−checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3c}\u{49}" .. i,- 1)
113+checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3c}\u{49}" .. i,- 0x1)
114checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3c}\u{49}" .. i,min)
114checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3c}\u{49}" .. i,min)
115−checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3e}\u{49}" .. i,umax + 1)
115+checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3e}\u{49}" .. i,umax + 0x1)
116checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3e}\u{69}" .. i,umax)
116checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3e}\u{69}" .. i,umax)
117−checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3e}\u{69}" .. i,max + 1)
117+checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3e}\u{69}" .. i,max + 0x1)
118−checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3c}\u{69}" .. i,min - 1)
118+checkerror("\u{6f}\u{76}\u{65}\u{72}\u{66}\u{6c}\u{6f}\u{77}",pack,"\u{3c}\u{69}" .. i,min - 0x1)
119assert(unpack("\u{3e}\u{69}" .. i,pack("\u{3e}\u{69}" .. i,max)) == max)
119assert(unpack("\u{3e}\u{69}" .. i,pack("\u{3e}\u{69}" .. i,max)) == max)
120assert(unpack("\u{3c}\u{69}" .. i,pack("\u{3c}\u{69}" .. i,min)) == min)
120assert(unpack("\u{3c}\u{69}" .. i,pack("\u{3c}\u{69}" .. i,min)) == min)
121assert(unpack("\u{3e}\u{49}" .. i,pack("\u{3e}\u{49}" .. i,umax)) == umax)
121assert(unpack("\u{3e}\u{49}" .. i,pack("\u{3e}\u{49}" .. i,umax)) == umax)
122end
122end
123assert(unpack("\u{3e}\u{6a}",pack("\u{3e}\u{6a}",math.maxinteger)) == math.maxinteger)
123assert(unpack("\u{3e}\u{6a}",pack("\u{3e}\u{6a}",math.maxinteger)) == math.maxinteger)
124assert(unpack("\u{3c}\u{6a}",pack("\u{3c}\u{6a}",math.mininteger)) == math.mininteger)
124assert(unpack("\u{3c}\u{6a}",pack("\u{3c}\u{6a}",math.mininteger)) == math.mininteger)
125−assert(unpack("\u{3c}\u{4a}",pack("\u{3c}\u{6a}",- 1)) == - 1)
125+assert(unpack("\u{3c}\u{4a}",pack("\u{3c}\u{6a}",- 0x1)) == - 0x1)
126if little then
126if little then
127−assert(pack("\u{66}",24) == pack("\u{3c}\u{66}",24))
127+assert(pack("\u{66}",0x18) == pack("\u{3c}\u{66}",0x18))
128else
128else
129−assert(pack("\u{66}",24) == pack("\u{3e}\u{66}",24))
129+assert(pack("\u{66}",0x18) == pack("\u{3e}\u{66}",0x18))
130end
130end
131print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}\u{2f}\u{75}\u{6e}\u{70}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{66}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{2d}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{73}")
131print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}\u{2f}\u{75}\u{6e}\u{70}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{66}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{69}\u{6e}\u{67}\u{2d}\u{70}\u{6f}\u{69}\u{6e}\u{74}\u{20}\u{6e}\u{75}\u{6d}\u{62}\u{65}\u{72}\u{73}")
132−for _,n in ipairs({0,- 1.1,1.9,1 / 0,- 1 / 0,1e20,- 1e20,0.1,2000.7})
132+for _,n in ipairs({0x0,- 1.1,1.9,0x1 / 0x0,- 0x1 / 0x0,1e20,- 1e20,0.1,2000.7})
133do
133do
134assert(unpack("\u{6e}",pack("\u{6e}",n)) == n)
134assert(unpack("\u{6e}",pack("\u{6e}",n)) == n)
135assert(unpack("\u{3c}\u{6e}",pack("\u{3c}\u{6e}",n)) == n)
135assert(unpack("\u{3c}\u{6e}",pack("\u{3c}\u{6e}",n)) == n)
@@ -137,7 +137,7 @@ assert(unpack("\u{3e}\u{6e}",pack("\u{3e}\u{6e}",n)) == n)
137assert(pack("\u{3c}\u{66}",n) == pack("\u{3e}\u{66}",n):reverse())
137assert(pack("\u{3c}\u{66}",n) == pack("\u{3e}\u{66}",n):reverse())
138assert(pack("\u{3e}\u{64}",n) == pack("\u{3c}\u{64}",n):reverse())
138assert(pack("\u{3e}\u{64}",n) == pack("\u{3c}\u{64}",n):reverse())
139end
139end
140−for _,n in ipairs({0,- 1.5,1 / 0,- 1 / 0,1e10,- 1e9,0.5,2000.25})
140+for _,n in ipairs({0x0,- 1.5,0x1 / 0x0,- 0x1 / 0x0,1e10,- 1e9,0.5,2000.25})
141do
141do
142assert(unpack("\u{3c}\u{66}",pack("\u{3c}\u{66}",n)) == n)
142assert(unpack("\u{3c}\u{66}",pack("\u{3c}\u{66}",n)) == n)
143assert(unpack("\u{3e}\u{66}",pack("\u{3e}\u{66}",n)) == n)
143assert(unpack("\u{3e}\u{66}",pack("\u{3e}\u{66}",n)) == n)
@@ -146,17 +146,17 @@ assert(unpack("\u{3e}\u{64}",pack("\u{3e}\u{64}",n)) == n)
146end
146end
147print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}\u{2f}\u{75}\u{6e}\u{70}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{66}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}")
147print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{70}\u{61}\u{63}\u{6b}\u{2f}\u{75}\u{6e}\u{70}\u{61}\u{63}\u{6b}\u{20}\u{6f}\u{66}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}\u{73}")
148do
148do
149−local s = string.rep("\u{61}\u{62}\u{63}",1000)
149+local s = string.rep("\u{61}\u{62}\u{63}",0x3e8)
150−assert(pack("\u{7a}\u{42}",s,247) == s .. "\u{0}\u{f7}")
150+assert(pack("\u{7a}\u{42}",s,0xf7) == s .. "\u{0}\u{f7}")
151local s1,b = unpack("\u{7a}\u{42}",s .. "\u{0}\u{f9}")
151local s1,b = unpack("\u{7a}\u{42}",s .. "\u{0}\u{f9}")
152−assert(b == 249 and s1 == s)
152+assert(b == 0xf9 and s1 == s)
153s1=pack("\u{73}",s)
153s1=pack("\u{73}",s)
154assert(unpack("\u{73}",s1) == s)
154assert(unpack("\u{73}",s1) == s)
155checkerror("\u{64}\u{6f}\u{65}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{69}\u{74}",pack,"\u{73}\u{31}",s)
155checkerror("\u{64}\u{6f}\u{65}\u{73}\u{20}\u{6e}\u{6f}\u{74}\u{20}\u{66}\u{69}\u{74}",pack,"\u{73}\u{31}",s)
156checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{61}\u{69}\u{6e}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}\u{73}",pack,"\u{7a}","\u{61}\u{6c}\u{6f}\u{0}")
156checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{61}\u{69}\u{6e}\u{73}\u{20}\u{7a}\u{65}\u{72}\u{6f}\u{73}",pack,"\u{7a}","\u{61}\u{6c}\u{6f}\u{0}")
157;
157;
158checkerror("\u{75}\u{6e}\u{66}\u{69}\u{6e}\u{69}\u{73}\u{68}\u{65}\u{64}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",unpack,"\u{7a}\u{63}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}","\u{61}\u{6c}\u{6f}")
158checkerror("\u{75}\u{6e}\u{66}\u{69}\u{6e}\u{69}\u{73}\u{68}\u{65}\u{64}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",unpack,"\u{7a}\u{63}\u{31}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}\u{30}","\u{61}\u{6c}\u{6f}")
159−for i = 2, NB
159+for i = 0x2, NB
160do
160do
161local s1 = pack("\u{73}" .. i,s)
161local s1 = pack("\u{73}" .. i,s)
162assert(unpack("\u{73}" .. i,s1) == s and # s1 == # s + i)
162assert(unpack("\u{73}" .. i,s1) == s and # s1 == # s + i)
@@ -164,96 +164,96 @@ end
164end
164end
165do
165do
166local x = pack("\u{73}","\u{61}\u{6c}\u{6f}")
166local x = pack("\u{73}","\u{61}\u{6c}\u{6f}")
167−checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{73}\u{68}\u{6f}\u{72}\u{74}",unpack,"\u{73}",x:sub(1,- 2))
167+checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{73}\u{68}\u{6f}\u{72}\u{74}",unpack,"\u{73}",x:sub(0x1,- 0x2))
168checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{73}\u{68}\u{6f}\u{72}\u{74}",unpack,"\u{63}\u{35}","\u{61}\u{62}\u{63}\u{64}")
168checkerror("\u{74}\u{6f}\u{6f}\u{20}\u{73}\u{68}\u{6f}\u{72}\u{74}",unpack,"\u{63}\u{35}","\u{61}\u{62}\u{63}\u{64}")
169checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{73}\u{31}\u{30}\u{30}","\u{61}\u{6c}\u{6f}")
169checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{6c}\u{69}\u{6d}\u{69}\u{74}\u{73}",pack,"\u{73}\u{31}\u{30}\u{30}","\u{61}\u{6c}\u{6f}")
170end
170end
171do
171do
172assert(pack("\u{63}\u{30}","") == "")
172assert(pack("\u{63}\u{30}","") == "")
173−assert(packsize("\u{63}\u{30}") == 0)
173+assert(packsize("\u{63}\u{30}") == 0x0)
174assert(unpack("\u{63}\u{30}","") == "")
174assert(unpack("\u{63}\u{30}","") == "")
175assert(pack("\u{3c}\u{21}\u{20}\u{63}\u{33}","\u{61}\u{62}\u{63}") == "\u{61}\u{62}\u{63}")
175assert(pack("\u{3c}\u{21}\u{20}\u{63}\u{33}","\u{61}\u{62}\u{63}") == "\u{61}\u{62}\u{63}")
176−assert(packsize("\u{3c}\u{21}\u{20}\u{63}\u{33}") == 3)
176+assert(packsize("\u{3c}\u{21}\u{20}\u{63}\u{33}") == 0x3)
177assert(pack("\u{3e}\u{21}\u{34}\u{20}\u{63}\u{36}","\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}") == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}")
177assert(pack("\u{3e}\u{21}\u{34}\u{20}\u{63}\u{36}","\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}") == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}")
178assert(pack("\u{63}\u{33}","\u{31}\u{32}\u{33}") == "\u{31}\u{32}\u{33}")
178assert(pack("\u{63}\u{33}","\u{31}\u{32}\u{33}") == "\u{31}\u{32}\u{33}")
179assert(pack("\u{63}\u{30}","") == "")
179assert(pack("\u{63}\u{30}","") == "")
180assert(pack("\u{63}\u{38}","\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}") == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{0}\u{0}")
180assert(pack("\u{63}\u{38}","\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}") == "\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{0}\u{0}")
181−assert(pack("\u{63}\u{38}\u{38}","") == string.rep("\u{0}",88))
181+assert(pack("\u{63}\u{38}\u{38}","") == string.rep("\u{0}",0x58))
182−assert(pack("\u{63}\u{31}\u{38}\u{38}","\u{61}\u{62}") == "\u{61}\u{62}" .. string.rep("\u{0}",188 - 2))
182+assert(pack("\u{63}\u{31}\u{38}\u{38}","\u{61}\u{62}") == "\u{61}\u{62}" .. string.rep("\u{0}",0xbc - 0x2))
183local a,b,c = unpack("\u{21}\u{34}\u{20}\u{7a}\u{20}\u{63}\u{33}","\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}\u{0}\u{78}\u{79}\u{7a}")
183local a,b,c = unpack("\u{21}\u{34}\u{20}\u{7a}\u{20}\u{63}\u{33}","\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}\u{0}\u{78}\u{79}\u{7a}")
184−assert(a == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}" and b == "\u{78}\u{79}\u{7a}" and c == 14)
184+assert(a == "\u{61}\u{62}\u{63}\u{64}\u{65}\u{66}\u{67}\u{68}\u{69}" and b == "\u{78}\u{79}\u{7a}" and c == 0xe)
185checkerror("\u{6c}\u{6f}\u{6e}\u{67}\u{65}\u{72}\u{20}\u{74}\u{68}\u{61}\u{6e}",pack,"\u{63}\u{33}","\u{31}\u{32}\u{33}\u{34}")
185checkerror("\u{6c}\u{6f}\u{6e}\u{67}\u{65}\u{72}\u{20}\u{74}\u{68}\u{61}\u{6e}",pack,"\u{63}\u{33}","\u{31}\u{32}\u{33}\u{34}")
186end
186end
187do
187do
188−local x = pack("\u{3c}\u{62}\u{20}\u{68}\u{20}\u{62}\u{20}\u{66}\u{20}\u{64}\u{20}\u{66}\u{20}\u{6e}\u{20}\u{69}",1,2,3,4,5,6,7,8)
188+local x = pack("\u{3c}\u{62}\u{20}\u{68}\u{20}\u{62}\u{20}\u{66}\u{20}\u{64}\u{20}\u{66}\u{20}\u{6e}\u{20}\u{69}",0x1,0x2,0x3,0x4,0x5,0x6,0x7,0x8)
189assert(# x == packsize("\u{3c}\u{62}\u{20}\u{68}\u{20}\u{62}\u{20}\u{66}\u{20}\u{64}\u{20}\u{66}\u{20}\u{6e}\u{20}\u{69}"))
189assert(# x == packsize("\u{3c}\u{62}\u{20}\u{68}\u{20}\u{62}\u{20}\u{66}\u{20}\u{64}\u{20}\u{66}\u{20}\u{6e}\u{20}\u{69}"))
190local a,b,c,d,e,f,g,h = unpack("\u{3c}\u{62}\u{20}\u{68}\u{20}\u{62}\u{20}\u{66}\u{20}\u{64}\u{20}\u{66}\u{20}\u{6e}\u{20}\u{69}",x)
190local a,b,c,d,e,f,g,h = unpack("\u{3c}\u{62}\u{20}\u{68}\u{20}\u{62}\u{20}\u{66}\u{20}\u{64}\u{20}\u{66}\u{20}\u{6e}\u{20}\u{69}",x)
191−assert(a == 1 and b == 2 and c == 3 and d == 4 and e == 5 and f == 6 and g == 7 and h == 8)
191+assert(a == 0x1 and b == 0x2 and c == 0x3 and d == 0x4 and e == 0x5 and f == 0x6 and g == 0x7 and h == 0x8)
192end
192end
193print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{6c}\u{69}\u{67}\u{6e}\u{6d}\u{65}\u{6e}\u{74}")
193print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{61}\u{6c}\u{69}\u{67}\u{6e}\u{6d}\u{65}\u{6e}\u{74}")
194do
194do
195−assert(pack("\u{20}\u{3c}\u{20}\u{69}\u{31}\u{20}\u{69}\u{32}\u{20}",2,3) == "\u{2}\u{3}\u{0}")
195+assert(pack("\u{20}\u{3c}\u{20}\u{69}\u{31}\u{20}\u{69}\u{32}\u{20}",0x2,0x3) == "\u{2}\u{3}\u{0}")
196−local x = pack("\u{3e}\u{21}\u{38}\u{20}\u{62}\u{20}\u{58}\u{68}\u{20}\u{69}\u{34}\u{20}\u{69}\u{38}\u{20}\u{63}\u{31}\u{20}\u{58}\u{69}\u{38}",- 12,100,200,"\u{ec}")
196+local x = pack("\u{3e}\u{21}\u{38}\u{20}\u{62}\u{20}\u{58}\u{68}\u{20}\u{69}\u{34}\u{20}\u{69}\u{38}\u{20}\u{63}\u{31}\u{20}\u{58}\u{69}\u{38}",- 0xc,0x64,0xc8,"\u{ec}")
197assert(# x == packsize("\u{3e}\u{21}\u{38}\u{20}\u{62}\u{20}\u{58}\u{68}\u{20}\u{69}\u{34}\u{20}\u{69}\u{38}\u{20}\u{63}\u{31}\u{20}\u{58}\u{69}\u{38}"))
197assert(# x == packsize("\u{3e}\u{21}\u{38}\u{20}\u{62}\u{20}\u{58}\u{68}\u{20}\u{69}\u{34}\u{20}\u{69}\u{38}\u{20}\u{63}\u{31}\u{20}\u{58}\u{69}\u{38}"))
198assert(x == "\u{f4}" .. "\u{0}\u{0}\u{0}" .. "\u{0}\u{0}\u{0}\u{64}" .. "\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{c8}" .. "\u{ec}" .. "\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}")
198assert(x == "\u{f4}" .. "\u{0}\u{0}\u{0}" .. "\u{0}\u{0}\u{0}\u{64}" .. "\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{c8}" .. "\u{ec}" .. "\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}\u{0}")
199local a,b,c,d,pos = unpack("\u{3e}\u{21}\u{38}\u{20}\u{63}\u{31}\u{20}\u{58}\u{68}\u{20}\u{69}\u{34}\u{20}\u{69}\u{38}\u{20}\u{62}\u{20}\u{58}\u{69}\u{38}\u{20}\u{58}\u{49}\u{20}\u{58}\u{48}",x)
199local a,b,c,d,pos = unpack("\u{3e}\u{21}\u{38}\u{20}\u{63}\u{31}\u{20}\u{58}\u{68}\u{20}\u{69}\u{34}\u{20}\u{69}\u{38}\u{20}\u{62}\u{20}\u{58}\u{69}\u{38}\u{20}\u{58}\u{49}\u{20}\u{58}\u{48}",x)
200−assert(a == "\u{f4}" and b == 100 and c == 200 and d == - 20 and (pos - 1) == # x)
200+assert(a == "\u{f4}" and b == 0x64 and c == 0xc8 and d == - 0x14 and (pos - 0x1) == # x)
201−x=pack("\u{3e}\u{21}\u{34}\u{20}\u{63}\u{33}\u{20}\u{63}\u{34}\u{20}\u{63}\u{32}\u{20}\u{7a}\u{20}\u{69}\u{34}\u{20}\u{63}\u{35}\u{20}\u{63}\u{32}\u{20}\u{58}\u{69}\u{34}","\u{61}\u{62}\u{63}","\u{61}\u{62}\u{63}\u{64}","\u{78}\u{7a}","\u{68}\u{65}\u{6c}\u{6c}\u{6f}",5,"\u{77}\u{6f}\u{72}\u{6c}\u{64}","\u{78}\u{79}")
201+x=pack("\u{3e}\u{21}\u{34}\u{20}\u{63}\u{33}\u{20}\u{63}\u{34}\u{20}\u{63}\u{32}\u{20}\u{7a}\u{20}\u{69}\u{34}\u{20}\u{63}\u{35}\u{20}\u{63}\u{32}\u{20}\u{58}\u{69}\u{34}","\u{61}\u{62}\u{63}","\u{61}\u{62}\u{63}\u{64}","\u{78}\u{7a}","\u{68}\u{65}\u{6c}\u{6c}\u{6f}",0x5,"\u{77}\u{6f}\u{72}\u{6c}\u{64}","\u{78}\u{79}")
202assert(x == "\u{61}\u{62}\u{63}\u{61}\u{62}\u{63}\u{64}\u{78}\u{7a}\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{0}\u{0}\u{0}\u{0}\u{0}\u{5}\u{77}\u{6f}\u{72}\u{6c}\u{64}\u{78}\u{79}\u{0}")
202assert(x == "\u{61}\u{62}\u{63}\u{61}\u{62}\u{63}\u{64}\u{78}\u{7a}\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{0}\u{0}\u{0}\u{0}\u{0}\u{5}\u{77}\u{6f}\u{72}\u{6c}\u{64}\u{78}\u{79}\u{0}")
203local a,b,c,d,e,f,g,pos = unpack("\u{3e}\u{21}\u{34}\u{20}\u{63}\u{33}\u{20}\u{63}\u{34}\u{20}\u{63}\u{32}\u{20}\u{7a}\u{20}\u{69}\u{34}\u{20}\u{63}\u{35}\u{20}\u{63}\u{32}\u{20}\u{58}\u{68}\u{20}\u{58}\u{69}\u{34}",x)
203local a,b,c,d,e,f,g,pos = unpack("\u{3e}\u{21}\u{34}\u{20}\u{63}\u{33}\u{20}\u{63}\u{34}\u{20}\u{63}\u{32}\u{20}\u{7a}\u{20}\u{69}\u{34}\u{20}\u{63}\u{35}\u{20}\u{63}\u{32}\u{20}\u{58}\u{68}\u{20}\u{58}\u{69}\u{34}",x)
204−assert(a == "\u{61}\u{62}\u{63}" and b == "\u{61}\u{62}\u{63}\u{64}" and c == "\u{78}\u{7a}" and d == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}" and e == 5 and f == "\u{77}\u{6f}\u{72}\u{6c}\u{64}" and g == "\u{78}\u{79}" and (pos - 1) % 4 == 0)
204+assert(a == "\u{61}\u{62}\u{63}" and b == "\u{61}\u{62}\u{63}\u{64}" and c == "\u{78}\u{7a}" and d == "\u{68}\u{65}\u{6c}\u{6c}\u{6f}" and e == 0x5 and f == "\u{77}\u{6f}\u{72}\u{6c}\u{64}" and g == "\u{78}\u{79}" and (pos - 0x1) % 0x4 == 0x0)
205−x=pack("\u{20}\u{62}\u{20}\u{62}\u{20}\u{58}\u{64}\u{20}\u{62}\u{20}\u{58}\u{62}\u{20}\u{78}",1,2,3)
205+x=pack("\u{20}\u{62}\u{20}\u{62}\u{20}\u{58}\u{64}\u{20}\u{62}\u{20}\u{58}\u{62}\u{20}\u{78}",0x1,0x2,0x3)
206−assert(packsize("\u{20}\u{62}\u{20}\u{62}\u{20}\u{58}\u{64}\u{20}\u{62}\u{20}\u{58}\u{62}\u{20}\u{78}") == 4)
206+assert(packsize("\u{20}\u{62}\u{20}\u{62}\u{20}\u{58}\u{64}\u{20}\u{62}\u{20}\u{58}\u{62}\u{20}\u{78}") == 0x4)
207assert(x == "\u{1}\u{2}\u{3}\u{0}")
207assert(x == "\u{1}\u{2}\u{3}\u{0}")
208a,b,c,pos=unpack("\u{62}\u{62}\u{58}\u{64}\u{62}",x)
208a,b,c,pos=unpack("\u{62}\u{62}\u{58}\u{64}\u{62}",x)
209−assert(a == 1 and b == 2 and c == 3 and pos == # x)
209+assert(a == 0x1 and b == 0x2 and c == 0x3 and pos == # x)
210−assert(packsize("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{38}") == 8)
210+assert(packsize("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{38}") == 0x8)
211local pos = unpack("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{38}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
211local pos = unpack("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{38}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
212;
212;
213−assert(pos == 9)
213+assert(pos == 0x9)
214−assert(packsize("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{32}") == 2)
214+assert(packsize("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{32}") == 0x2)
215local pos = unpack("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{32}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
215local pos = unpack("\u{21}\u{38}\u{20}\u{78}\u{58}\u{69}\u{32}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
216;
216;
217−assert(pos == 3)
217+assert(pos == 0x3)
218−assert(packsize("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{32}") == 2)
218+assert(packsize("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{32}") == 0x2)
219local pos = unpack("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{32}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
219local pos = unpack("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{32}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
220;
220;
221−assert(pos == 3)
221+assert(pos == 0x3)
222−assert(packsize("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{38}") == 2)
222+assert(packsize("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{38}") == 0x2)
223local pos = unpack("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{38}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
223local pos = unpack("\u{21}\u{32}\u{20}\u{78}\u{58}\u{69}\u{38}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
224;
224;
225−assert(pos == 3)
225+assert(pos == 0x3)
226−assert(packsize("\u{21}\u{31}\u{36}\u{20}\u{78}\u{58}\u{69}\u{31}\u{36}") == 16)
226+assert(packsize("\u{21}\u{31}\u{36}\u{20}\u{78}\u{58}\u{69}\u{31}\u{36}") == 0x10)
227local pos = unpack("\u{21}\u{31}\u{36}\u{20}\u{78}\u{58}\u{69}\u{31}\u{36}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
227local pos = unpack("\u{21}\u{31}\u{36}\u{20}\u{78}\u{58}\u{69}\u{31}\u{36}","\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}\u{30}\u{31}\u{32}\u{33}\u{34}\u{35}\u{36}\u{37}")
228;
228;
229−assert(pos == 17)
229+assert(pos == 0x11)
230checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",pack,"\u{58}")
230checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",pack,"\u{58}")
231checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",unpack,"\u{58}\u{58}\u{69}","")
231checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",unpack,"\u{58}\u{58}\u{69}","")
232checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",unpack,"\u{58}\u{20}\u{69}","")
232checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",unpack,"\u{58}\u{20}\u{69}","")
233checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",pack,"\u{58}\u{63}\u{31}")
233checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{6e}\u{65}\u{78}\u{74}\u{20}\u{6f}\u{70}\u{74}\u{69}\u{6f}\u{6e}",pack,"\u{58}\u{63}\u{31}")
234end
234end
235do
235do
236−local x = pack("\u{69}\u{34}\u{69}\u{34}\u{69}\u{34}\u{69}\u{34}",1,2,3,4)
236+local x = pack("\u{69}\u{34}\u{69}\u{34}\u{69}\u{34}\u{69}\u{34}",0x1,0x2,0x3,0x4)
237−for pos = 1, 16, 4
237+for pos = 0x1, 0x10, 0x4
238do
238do
239local i,p = unpack("\u{69}\u{34}",x,pos)
239local i,p = unpack("\u{69}\u{34}",x,pos)
240−assert(i == pos // 4 + 1 and p == pos + 4)
240+assert(i == pos // 0x4 + 0x1 and p == pos + 0x4)
241end
241end
242−for pos = 0, 12
242+for pos = 0x0, 0xc
243do
243do
244−local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,pos + 1)
244+local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,pos + 0x1)
245−assert(i == (pos + 3) // 4 + 1 and p == i * 4 + 1)
245+assert(i == (pos + 0x3) // 0x4 + 0x1 and p == i * 0x4 + 0x1)
246end
246end
247−local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,- 4)
247+local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,- 0x4)
248−assert(i == 4 and p == 17)
248+assert(i == 0x4 and p == 0x11)
249−local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,- 7)
249+local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,- 0x7)
250−assert(i == 4 and p == 17)
250+assert(i == 0x4 and p == 0x11)
251local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,- # x)
251local i,p = unpack("\u{21}\u{34}\u{20}\u{69}\u{34}",x,- # x)
252−assert(i == 1 and p == 5)
252+assert(i == 0x1 and p == 0x5)
253−for i = 1, # x + 1
253+for i = 0x1, # x + 0x1
254do
254do
255assert(unpack("\u{63}\u{30}",x,i) == "")
255assert(unpack("\u{63}\u{30}",x,i) == "")
256end
256end
257−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",unpack,"\u{63}\u{30}",x,# x + 2)
257+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{73}\u{74}\u{72}\u{69}\u{6e}\u{67}",unpack,"\u{63}\u{30}",x,# x + 0x2)
258end
258end
259print("\u{4f}\u{4b}")
259print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/utf8.lua+85−85
@@ -13,69 +13,69 @@ local justone = "\u{5e}" .. utf8.charpattern .. "\u{24}"
13local function checksyntax
13local function checksyntax
14(s,t)
14(s,t)
15local ts = {"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}"}
15local ts = {"\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{27}"}
16−for i = 1, # t
16+for i = 0x1, # t
17do
17do
18−ts[i + 1]=string.format("\u{5c}\u{75}\u{7b}\u{25}\u{78}\u{7d}",t[i])
18+ts[i + 0x1]=string.format("\u{5c}\u{75}\u{7b}\u{25}\u{78}\u{7d}",t[i])
19end
19end
20−ts[# t + 2]="\u{27}"
20+ts[# t + 0x2]="\u{27}"
21ts=table.concat(ts)
21ts=table.concat(ts)
22assert(assert(load(ts))() == s)
22assert(assert(load(ts))() == s)
23end
23end
24−assert(not utf8.offset("\u{61}\u{6c}\u{6f}",5))
24+assert(not utf8.offset("\u{61}\u{6c}\u{6f}",0x5))
25−assert(not utf8.offset("\u{61}\u{6c}\u{6f}",- 4))
25+assert(not utf8.offset("\u{61}\u{6c}\u{6f}",- 0x4))
26local function check
26local function check
27(s,t,nonstrict)
27(s,t,nonstrict)
28−local l = utf8.len(s,1,- 1,nonstrict)
28+local l = utf8.len(s,0x1,- 0x1,nonstrict)
29assert(# t == l and len(s) == l)
29assert(# t == l and len(s) == l)
30assert(utf8.char(table.unpack(t)) == s)
30assert(utf8.char(table.unpack(t)) == s)
31−assert(utf8.offset(s,0) == 1)
31+assert(utf8.offset(s,0x0) == 0x1)
32checksyntax(s,t)
32checksyntax(s,t)
33−local t1 = {utf8.codepoint(s,1,- 1,nonstrict)}
33+local t1 = {utf8.codepoint(s,0x1,- 0x1,nonstrict)}
34assert(# t == # t1)
34assert(# t == # t1)
35−for i = 1, # t
35+for i = 0x1, # t
36do
36do
37assert(t[i] == t1[i])
37assert(t[i] == t1[i])
38end
38end
39−for i = 1, l
39+for i = 0x1, l
40do
40do
41local pi = utf8.offset(s,i)
41local pi = utf8.offset(s,i)
42−local pi1 = utf8.offset(s,2,pi)
42+local pi1 = utf8.offset(s,0x2,pi)
43−assert(string.find(string.sub(s,pi,pi1 - 1),justone))
43+assert(string.find(string.sub(s,pi,pi1 - 0x1),justone))
44−assert(utf8.offset(s,- 1,pi1) == pi)
44+assert(utf8.offset(s,- 0x1,pi1) == pi)
45−assert(utf8.offset(s,i - l - 1) == pi)
45+assert(utf8.offset(s,i - l - 0x1) == pi)
46assert(pi1 - pi == # utf8.char(utf8.codepoint(s,pi,pi,nonstrict)))
46assert(pi1 - pi == # utf8.char(utf8.codepoint(s,pi,pi,nonstrict)))
47−for j = pi, pi1 - 1
47+for j = pi, pi1 - 0x1
48do
48do
49−assert(utf8.offset(s,0,j) == pi)
49+assert(utf8.offset(s,0x0,j) == pi)
50end
50end
51−for j = pi + 1, pi1 - 1
51+for j = pi + 0x1, pi1 - 0x1
52do
52do
53assert(not utf8.len(s,j))
53assert(not utf8.len(s,j))
54end
54end
55−assert(utf8.len(s,pi,pi,nonstrict) == 1)
55+assert(utf8.len(s,pi,pi,nonstrict) == 0x1)
56−assert(utf8.len(s,pi,pi1 - 1,nonstrict) == 1)
56+assert(utf8.len(s,pi,pi1 - 0x1,nonstrict) == 0x1)
57−assert(utf8.len(s,pi,- 1,nonstrict) == l - i + 1)
57+assert(utf8.len(s,pi,- 0x1,nonstrict) == l - i + 0x1)
58−assert(utf8.len(s,pi1,- 1,nonstrict) == l - i)
58+assert(utf8.len(s,pi1,- 0x1,nonstrict) == l - i)
59−assert(utf8.len(s,1,pi,nonstrict) == i)
59+assert(utf8.len(s,0x1,pi,nonstrict) == i)
60end
60end
61−local i = 0
61+local i = 0x0
62for p,c in utf8.codes(s,nonstrict)
62for p,c in utf8.codes(s,nonstrict)
63do
63do
64−i=i + 1
64+i=i + 0x1
65assert(c == t[i] and p == utf8.offset(s,i))
65assert(c == t[i] and p == utf8.offset(s,i))
66assert(utf8.codepoint(s,p,p,nonstrict) == c)
66assert(utf8.codepoint(s,p,p,nonstrict) == c)
67end
67end
68assert(i == # t)
68assert(i == # t)
69−i=0
69+i=0x0
70for c in string.gmatch(s,utf8.charpattern)
70for c in string.gmatch(s,utf8.charpattern)
71do
71do
72−i=i + 1
72+i=i + 0x1
73assert(c == utf8.char(t[i]))
73assert(c == utf8.char(t[i]))
74end
74end
75assert(i == # t)
75assert(i == # t)
76−for i = 1, l
76+for i = 0x1, l
77do
77do
78−assert(utf8.offset(s,i) == utf8.offset(s,i - l - 1,# s + 1))
78+assert(utf8.offset(s,i) == utf8.offset(s,i - l - 0x1,# s + 0x1))
79end
79end
80end
80end
81do
81do
@@ -84,15 +84,15 @@ local function check
84local a,b = utf8.len(s)
84local a,b = utf8.len(s)
85assert(not a and b == p)
85assert(not a and b == p)
86end
86end
87−check("\u{61}\u{62}\u{63}\u{e3}\u{64}\u{65}\u{66}",4)
87+check("\u{61}\u{62}\u{63}\u{e3}\u{64}\u{65}\u{66}",0x4)
88−check("\u{f4}\u{9f}\u{bf}",1)
88+check("\u{f4}\u{9f}\u{bf}",0x1)
89−check("\u{f4}\u{9f}\u{bf}\u{bf}",1)
89+check("\u{f4}\u{9f}\u{bf}\u{bf}",0x1)
90−check("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}\u{80}",# ("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}") + 1)
90+check("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}\u{80}",# ("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}") + 0x1)
91−check("\u{80}\u{68}\u{65}\u{6c}\u{6c}\u{6f}",1)
91+check("\u{80}\u{68}\u{65}\u{6c}\u{6c}\u{6f}",0x1)
92−check("\u{68}\u{65}\u{6c}\u{80}\u{6c}\u{6f}",4)
92+check("\u{68}\u{65}\u{6c}\u{80}\u{6c}\u{6f}",0x4)
93−check("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}\u{bf}",# ("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}") + 1)
93+check("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}\u{bf}",# ("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}") + 0x1)
94−check("\u{bf}\u{68}\u{65}\u{6c}\u{6c}\u{6f}",1)
94+check("\u{bf}\u{68}\u{65}\u{6c}\u{6c}\u{6f}",0x1)
95−check("\u{68}\u{65}\u{6c}\u{bf}\u{6c}\u{6f}",4)
95+check("\u{68}\u{65}\u{6c}\u{bf}\u{6c}\u{6f}",0x4)
96end
96end
97do
97do
98local function errorcodes
98local function errorcodes
@@ -110,49 +110,49 @@ errorcodes("\u{69}\u{6e}\u{80}\u{76}\u{61}\u{6c}\u{69}\u{64}")
110errorcodes("\u{bf}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}")
110errorcodes("\u{bf}\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}")
111errorcodes("\u{ce}\u{b1}\u{ce}\u{bb}\u{cf}\u{86}\u{bf}\u{ce}\u{b1}")
111errorcodes("\u{ce}\u{b1}\u{ce}\u{bb}\u{cf}\u{86}\u{bf}\u{ce}\u{b1}")
112local f = utf8.codes("")
112local f = utf8.codes("")
113−assert(f("",2) == nil)
113+assert(f("",0x2) == nil)
114−assert(f("",- 1) == nil)
114+assert(f("",- 0x1) == nil)
115assert(f("",math.mininteger) == nil)
115assert(f("",math.mininteger) == nil)
116end
116end
117−checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"\u{61}\u{62}\u{63}",1,5)
117+checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"\u{61}\u{62}\u{63}",0x1,0x5)
118−checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"\u{61}\u{62}\u{63}",1,- 4)
118+checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"\u{61}\u{62}\u{63}",0x1,- 0x4)
119−checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"",1,2)
119+checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"",0x1,0x2)
120−checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"",1,- 1)
120+checkerror("\u{70}\u{6f}\u{73}\u{69}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.offset,"",0x1,- 0x1)
121−checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{79}\u{74}\u{65}",utf8.offset,"\u{f0}\u{a6}\u{a7}\u{ba}",1,2)
121+checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{79}\u{74}\u{65}",utf8.offset,"\u{f0}\u{a6}\u{a7}\u{ba}",0x1,0x2)
122−checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{79}\u{74}\u{65}",utf8.offset,"\u{f0}\u{a6}\u{a7}\u{ba}",1,2)
122+checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{79}\u{74}\u{65}",utf8.offset,"\u{f0}\u{a6}\u{a7}\u{ba}",0x1,0x2)
123−checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{79}\u{74}\u{65}",utf8.offset,"\u{80}",1)
123+checkerror("\u{63}\u{6f}\u{6e}\u{74}\u{69}\u{6e}\u{75}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{79}\u{74}\u{65}",utf8.offset,"\u{80}",0x1)
124−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.len,"\u{61}\u{62}\u{63}",0,2)
124+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.len,"\u{61}\u{62}\u{63}",0x0,0x2)
125−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.len,"\u{61}\u{62}\u{63}",1,4)
125+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.len,"\u{61}\u{62}\u{63}",0x1,0x4)
126local s = "\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{20}\u{57}\u{6f}\u{72}\u{6c}\u{64}"
126local s = "\u{68}\u{65}\u{6c}\u{6c}\u{6f}\u{20}\u{57}\u{6f}\u{72}\u{6c}\u{64}"
127−local t = {string.byte(s,1,- 1)}
127+local t = {string.byte(s,0x1,- 0x1)}
128−for i = 1, utf8.len(s)
128+for i = 0x1, utf8.len(s)
129do
129do
130assert(t[i] == string.byte(s,i))
130assert(t[i] == string.byte(s,i))
131end
131end
132check(s,t)
132check(s,t)
133−check("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}\u{2f}\u{e6}\u{bc}\u{a2}\u{e5}\u{ad}\u{97}",{27721,23383,47,28450,23383})
133+check("\u{e6}\u{b1}\u{89}\u{e5}\u{ad}\u{97}\u{2f}\u{e6}\u{bc}\u{a2}\u{e5}\u{ad}\u{97}",{0x6c49,0x5b57,0x2f,0x6f22,0x5b57})
134do
134do
135local s = "\u{c3}\u{a1}\u{c3}\u{a9}\u{c3}\u{ad}\u{80}"
135local s = "\u{c3}\u{a1}\u{c3}\u{a9}\u{c3}\u{ad}\u{80}"
136−local t = {utf8.codepoint(s,1,# s - 1)}
136+local t = {utf8.codepoint(s,0x1,# s - 0x1)}
137−assert(# t == 3 and t[1] == 225 and t[2] == 233 and t[3] == 237)
137+assert(# t == 0x3 and t[0x1] == 0xe1 and t[0x2] == 0xe9 and t[0x3] == 0xed)
138−checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{55}\u{54}\u{46}\u{25}\u{2d}\u{38}\u{20}\u{63}\u{6f}\u{64}\u{65}",utf8.codepoint,s,1,# s)
138+checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{55}\u{54}\u{46}\u{25}\u{2d}\u{38}\u{20}\u{63}\u{6f}\u{64}\u{65}",utf8.codepoint,s,0x1,# s)
139−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.codepoint,s,# s + 1)
139+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.codepoint,s,# s + 0x1)
140−t={utf8.codepoint(s,4,3)}
140+t={utf8.codepoint(s,0x4,0x3)}
141−assert(# t == 0)
141+assert(# t == 0x0)
142−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.codepoint,s,- (# s + 1),1)
142+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.codepoint,s,- (# s + 0x1),0x1)
143−checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.codepoint,s,1,# s + 1)
143+checkerror("\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{62}\u{6f}\u{75}\u{6e}\u{64}\u{73}",utf8.codepoint,s,0x1,# s + 0x1)
144−assert(utf8.codepoint("\u{d7ff}") == 55296 - 1)
144+assert(utf8.codepoint("\u{d7ff}") == 0xd800 - 0x1)
145−assert(utf8.codepoint("\u{e000}") == 57343 + 1)
145+assert(utf8.codepoint("\u{e000}") == 0xdfff + 0x1)
146−assert(utf8.codepoint("\u{d800}",1,1,true) == 55296)
146+assert(utf8.codepoint("\u{d800}",0x1,0x1,true) == 0xd800)
147−assert(utf8.codepoint("\u{dfff}",1,1,true) == 57343)
147+assert(utf8.codepoint("\u{dfff}",0x1,0x1,true) == 0xdfff)
148−assert(utf8.codepoint("\u{7fffffff}",1,1,true) == 2147483647)
148+assert(utf8.codepoint("\u{7fffffff}",0x1,0x1,true) == 0x7fffffff)
149end
149end
150assert(utf8.char() == "")
150assert(utf8.char() == "")
151−assert(utf8.char(0,97,98,99,1) == "\u{0}\u{61}\u{62}\u{63}\u{1}")
151+assert(utf8.char(0x0,0x61,0x62,0x63,0x1) == "\u{0}\u{61}\u{62}\u{63}\u{1}")
152−assert(utf8.codepoint(utf8.char(1114111)) == 1114111)
152+assert(utf8.codepoint(utf8.char(0x10ffff)) == 0x10ffff)
153−assert(utf8.codepoint(utf8.char(2147483647),1,1,true) == (1 << 31) - 1)
153+assert(utf8.codepoint(utf8.char(0x7fffffff),0x1,0x1,true) == (0x1 << 0x1f) - 0x1)
154−checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",utf8.char,2147483647 + 1)
154+checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",utf8.char,0x7fffffff + 0x1)
155−checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",utf8.char,- 1)
155+checkerror("\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{6f}\u{75}\u{74}\u{20}\u{6f}\u{66}\u{20}\u{72}\u{61}\u{6e}\u{67}\u{65}",utf8.char,- 0x1)
156local function invalid
156local function invalid
157(s)
157(s)
158checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{55}\u{54}\u{46}\u{25}\u{2d}\u{38}\u{20}\u{63}\u{6f}\u{64}\u{65}",utf8.codepoint,s)
158checkerror("\u{69}\u{6e}\u{76}\u{61}\u{6c}\u{69}\u{64}\u{20}\u{55}\u{54}\u{46}\u{25}\u{2d}\u{38}\u{20}\u{63}\u{6f}\u{64}\u{65}",utf8.codepoint,s)
@@ -172,32 +172,32 @@ invalid("\u{ff}")
172check("",{})
172check("",{})
173s="\u{0}\u{20}\u{7f}\u{c2}\u{80}\u{20}\u{df}\u{bf}\u{e0}\u{a0}\u{80}\u{20}\u{ef}\u{bf}\u{bf}\u{f0}\u{90}\u{80}\u{80}\u{20}\u{20}\u{f4}\u{8f}\u{bf}\u{bf}"
173s="\u{0}\u{20}\u{7f}\u{c2}\u{80}\u{20}\u{df}\u{bf}\u{e0}\u{a0}\u{80}\u{20}\u{ef}\u{bf}\u{bf}\u{f0}\u{90}\u{80}\u{80}\u{20}\u{20}\u{f4}\u{8f}\u{bf}\u{bf}"
174s=string.gsub(s,"\u{20}","")
174s=string.gsub(s,"\u{20}","")
175−check(s,{0,127,128,2047,2048,65535,65536,1114111})
175+check(s,{0x0,0x7f,0x80,0x7ff,0x800,0xffff,0x10000,0x10ffff})
176do
176do
177local s = "\u{4000000}\u{7fffffff}"
177local s = "\u{4000000}\u{7fffffff}"
178−assert(# s == 12)
178+assert(# s == 0xc)
179−check(s,{67108864,2147483647},true)
179+check(s,{0x4000000,0x7fffffff},true)
180s="\u{200000}\u{3ffffff}"
180s="\u{200000}\u{3ffffff}"
181−assert(# s == 10)
181+assert(# s == 0xa)
182−check(s,{2097152,67108863},true)
182+check(s,{0x200000,0x3ffffff},true)
183s="\u{10000}\u{1fffff}"
183s="\u{10000}\u{1fffff}"
184−assert(# s == 8)
184+assert(# s == 0x8)
185−check(s,{65536,2097151},true)
185+check(s,{0x10000,0x1fffff},true)
186end
186end
187local x = "\u{e6}\u{97}\u{a5}\u{e6}\u{9c}\u{ac}\u{e8}\u{aa}\u{9e}\u{61}\u{2d}\u{34}\u{0}\u{c3}\u{a9}\u{c3}\u{b3}"
187local x = "\u{e6}\u{97}\u{a5}\u{e6}\u{9c}\u{ac}\u{e8}\u{aa}\u{9e}\u{61}\u{2d}\u{34}\u{0}\u{c3}\u{a9}\u{c3}\u{b3}"
188−check(x,{26085,26412,35486,97,45,52,0,233,243})
188+check(x,{0x65e5,0x672c,0x8a9e,0x61,0x2d,0x34,0x0,0xe9,0xf3})
189−check("\u{f0}\u{a3}\u{b2}\u{b7}\u{f0}\u{a0}\u{9c}\u{8e}\u{f0}\u{a0}\u{b1}\u{93}\u{f0}\u{a1}\u{81}\u{bb}\u{f0}\u{a0}\u{b5}\u{bc}\u{61}\u{62}\u{f0}\u{a0}\u{ba}\u{a2}",{146615,132878,134227,135291,134524,97,98,134818})
189+check("\u{f0}\u{a3}\u{b2}\u{b7}\u{f0}\u{a0}\u{9c}\u{8e}\u{f0}\u{a0}\u{b1}\u{93}\u{f0}\u{a1}\u{81}\u{bb}\u{f0}\u{a0}\u{b5}\u{bc}\u{61}\u{62}\u{f0}\u{a0}\u{ba}\u{a2}",{0x23cb7,0x2070e,0x20c53,0x2107b,0x20d7c,0x61,0x62,0x20ea2})
190−check("\u{f0}\u{a8}\u{b3}\u{8a}\u{f0}\u{a9}\u{b6}\u{98}\u{f0}\u{a6}\u{a7}\u{ba}\u{f0}\u{a8}\u{b3}\u{92}\u{f0}\u{a5}\u{84}\u{ab}\u{f0}\u{a4}\u{93}\u{93}\u{f4}\u{8f}\u{bf}\u{bf}",{167114,171416,158202,167122,151851,148691,1114111})
190+check("\u{f0}\u{a8}\u{b3}\u{8a}\u{f0}\u{a9}\u{b6}\u{98}\u{f0}\u{a6}\u{a7}\u{ba}\u{f0}\u{a8}\u{b3}\u{92}\u{f0}\u{a5}\u{84}\u{ab}\u{f0}\u{a4}\u{93}\u{93}\u{f4}\u{8f}\u{bf}\u{bf}",{0x28cca,0x29d98,0x269fa,0x28cd2,0x2512b,0x244d3,0x10ffff})
191−local i = 0
191+local i = 0x0
192for p,c in string.gmatch(x,"\u{28}\u{29}\u{28}" .. utf8.charpattern .. "\u{29}")
192for p,c in string.gmatch(x,"\u{28}\u{29}\u{28}" .. utf8.charpattern .. "\u{29}")
193do
193do
194−i=i + 1
194+i=i + 0x1
195assert(utf8.offset(x,i) == p)
195assert(utf8.offset(x,i) == p)
196−assert(utf8.len(x,p) == utf8.len(x) - i + 1)
196+assert(utf8.len(x,p) == utf8.len(x) - i + 0x1)
197−assert(utf8.len(c) == 1)
197+assert(utf8.len(c) == 0x1)
198−for j = 1, # c - 1
198+for j = 0x1, # c - 0x1
199do
199do
200−assert(utf8.offset(x,0,p + j - 1) == p)
200+assert(utf8.offset(x,0x0,p + j - 0x1) == p)
201end
201end
202end
202end
203print("\u{6f}\u{6b}")
203print("\u{6f}\u{6b}")
zod/luau/res/lua/cycled/vararg.lua+48−48
@@ -2,7 +2,7 @@ print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{76}\u{61}\u{72}\u{61}\
2local function f
2local function f
3(a, ...)
3(a, ...)
4local x = {["\u{6e}"] = select("\u{23}",...),...}
4local x = {["\u{6e}"] = select("\u{23}",...),...}
5−for i = 1, x.n
5+for i = 0x1, x.n
6do
6do
7assert(a[i] == x[i])
7assert(a[i] == x[i])
8end
8end
@@ -14,57 +14,57 @@ assert(arg == _G.arg)
14local x = {...}
14local x = {...}
15;
15;
16x.n=# x
16x.n=# x
17−local res = (x.n == 2 and x[1] == 1 and x[2] == 2)
17+local res = (x.n == 0x2 and x[0x1] == 0x1 and x[0x2] == 0x2)
18if res then
18if res then
19−res=55
19+res=0x37
20end
20end
21−return res,2
21+return res,0x2
22end
22end
23local function vararg
23local function vararg
24(...)
24(...)
25return {["\u{6e}"] = select("\u{23}",...),...}
25return {["\u{6e}"] = select("\u{23}",...),...}
26end
26end
27local call = function (f,args)
27local call = function (f,args)
28−return f(table.unpack(args,1,args.n))
28+return f(table.unpack(args,0x1,args.n))
29−end
29+end
30−assert(f() == 0)
30+assert(f() == 0x0)
31−assert(f({1,2,3},1,2,3) == 3)
31+assert(f({0x1,0x2,0x3},0x1,0x2,0x3) == 0x3)
32−assert(f({"\u{61}\u{6c}\u{6f}",nil,45,f,nil},"\u{61}\u{6c}\u{6f}",nil,45,f,nil) == 5)
32+assert(f({"\u{61}\u{6c}\u{6f}",nil,0x2d,f,nil},"\u{61}\u{6c}\u{6f}",nil,0x2d,f,nil) == 0x5)
33−assert(vararg().n == 0)
33+assert(vararg().n == 0x0)
34−assert(vararg(nil,nil).n == 2)
34+assert(vararg(nil,nil).n == 0x2)
35−assert(c12(1,2) == 55)
35+assert(c12(0x1,0x2) == 0x37)
36−local a,b = assert(call(c12,{1,2}))
36+local a,b = assert(call(c12,{0x1,0x2}))
37−assert(a == 55 and b == 2)
37+assert(a == 0x37 and b == 0x2)
38−a=call(c12,{1,2,["\u{6e}"] = 2})
38+a=call(c12,{0x1,0x2,["\u{6e}"] = 0x2})
39−assert(a == 55 and b == 2)
39+assert(a == 0x37 and b == 0x2)
40−a=call(c12,{1,2,["\u{6e}"] = 1})
40+a=call(c12,{0x1,0x2,["\u{6e}"] = 0x1})
41assert(not a)
41assert(not a)
42−assert(c12(1,2,3) == false)
42+assert(c12(0x1,0x2,0x3) == false)
43−local a = vararg(call(next,{_G,nil,["\u{6e}"] = 2}))
43+local a = vararg(call(next,{_G,nil,["\u{6e}"] = 0x2}))
44local b,c = next(_G)
44local b,c = next(_G)
45−assert(a[1] == b and a[2] == c and a.n == 2)
45+assert(a[0x1] == b and a[0x2] == c and a.n == 0x2)
46−a=vararg(call(call,{c12,{1,2}}))
46+a=vararg(call(call,{c12,{0x1,0x2}}))
47−assert(a.n == 2 and a[1] == 55 and a[2] == 2)
47+assert(a.n == 0x2 and a[0x1] == 0x37 and a[0x2] == 0x2)
48a=call(print,{"\u{2b}"})
48a=call(print,{"\u{2b}"})
49assert(a == nil)
49assert(a == nil)
50−local t = {1,10}
50+local t = {0x1,0xa}
51function t:f(...)
51function t:f(...)
52local arg = {...}
52local arg = {...}
53;
53;
54return self[...] + # arg
54return self[...] + # arg
55end
55end
56−assert(t:f(1,4) == 3 and t:f(2) == 11)
56+assert(t:f(0x1,0x4) == 0x3 and t:f(0x2) == 0xb)
57print("\u{2b}")
57print("\u{2b}")
58−local lim = 20
58+local lim = 0x14
59−local i,a = 1,{}
59+local i,a = 0x1,{}
60while i <= lim do
60while i <= lim do
61a[i]=i + 0.3
61a[i]=i + 0.3
62;
62;
63−i=i + 1
63+i=i + 0x1
64end
64end
65function f(a,b,c,d, ...)
65function f(a,b,c,d, ...)
66local more = {...}
66local more = {...}
67−assert(a == 1.3 and more[1] == 5.3 and more[lim - 4] == lim + 0.3 and not more[lim - 3])
67+assert(a == 1.3 and more[0x1] == 5.3 and more[lim - 0x4] == lim + 0.3 and not more[lim - 0x3])
68end
68end
69local function g
69local function g
70(a,b,c)
70(a,b,c)
@@ -73,11 +73,11 @@ end
73call(f,a)
73call(f,a)
74call(g,a)
74call(g,a)
75a={}
75a={}
76−i=1
76+i=0x1
77while i <= lim do
77while i <= lim do
78a[i]=i
78a[i]=i
79;
79;
80−i=i + 1
80+i=i + 0x1
81end
81end
82assert(call(math.max,a) == lim)
82assert(call(math.max,a) == lim)
83print("\u{2b}")
83print("\u{2b}")
@@ -88,35 +88,35 @@ end
88function f(n,a, ...)
88function f(n,a, ...)
89local b
89local b
90assert(arg == _G.arg)
90assert(arg == _G.arg)
91−if n == 0 then
91+if n == 0x0 then
92local b,c,d = ...
92local b,c,d = ...
93return a,b,c,d,oneless(oneless(oneless(...)))
93return a,b,c,d,oneless(oneless(oneless(...)))
94else
94else
95−n,b,a=n - 1,...,a
95+n,b,a=n - 0x1,...,a
96assert(b == ...)
96assert(b == ...)
97return f(n,a,...)
97return f(n,a,...)
98end
98end
99end
99end
100−a,b,c,d,e=assert(f(10,5,4,3,2,1))
100+a,b,c,d,e=assert(f(0xa,0x5,0x4,0x3,0x2,0x1))
101−assert(a == 5 and b == 4 and c == 3 and d == 2 and e == 1)
101+assert(a == 0x5 and b == 0x4 and c == 0x3 and d == 0x2 and e == 0x1)
102−a,b,c,d,e=f(4)
102+a,b,c,d,e=f(0x4)
103assert(a == nil and b == nil and c == nil and d == nil and e == nil)
103assert(a == nil and b == nil and c == nil and d == nil and e == nil)
104local f = load("\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{7b}\u{2e}\u{2e}\u{2e}\u{7d}\u{20}")
104local f = load("\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{7b}\u{2e}\u{2e}\u{2e}\u{7d}\u{20}")
105−local x = f(2,3)
105+local x = f(0x2,0x3)
106−assert(x[1] == 2 and x[2] == 3 and x[3] == undef)
106+assert(x[0x1] == 0x2 and x[0x2] == 0x3 and x[0x3] == undef)
107f=load("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{7b}\u{2e}\u{2e}\u{2e}\u{7d}\u{a}\u{20}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{28}\u{27}\u{23}\u{27}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{64}\u{6f}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{78}\u{5b}\u{69}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{28}\u{69}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{78}\u{5b}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{28}\u{27}\u{23}\u{27}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{2b}\u{31}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{75}\u{6e}\u{64}\u{65}\u{66}\u{29}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{72}\u{75}\u{65}\u{a}")
107f=load("\u{20}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{78}\u{20}\u{3d}\u{20}\u{7b}\u{2e}\u{2e}\u{2e}\u{7d}\u{a}\u{20}\u{20}\u{66}\u{6f}\u{72}\u{20}\u{69}\u{3d}\u{31}\u{2c}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{28}\u{27}\u{23}\u{27}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{20}\u{64}\u{6f}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{78}\u{5b}\u{69}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{28}\u{69}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{29}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{20}\u{20}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{78}\u{5b}\u{73}\u{65}\u{6c}\u{65}\u{63}\u{74}\u{28}\u{27}\u{23}\u{27}\u{2c}\u{20}\u{2e}\u{2e}\u{2e}\u{29}\u{2b}\u{31}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{75}\u{6e}\u{64}\u{65}\u{66}\u{29}\u{a}\u{20}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{74}\u{72}\u{75}\u{65}\u{a}")
108assert(f("\u{61}","\u{62}",nil,{},assert))
108assert(f("\u{61}","\u{62}",nil,{},assert))
109assert(f())
109assert(f())
110−a={select(3,table.unpack({10,20,30,40}))}
110+a={select(0x3,table.unpack({0xa,0x14,0x1e,0x28}))}
111−assert(# a == 2 and a[1] == 30 and a[2] == 40)
111+assert(# a == 0x2 and a[0x1] == 0x1e and a[0x2] == 0x28)
112−a={select(1)}
112+a={select(0x1)}
113assert(next(a) == nil)
113assert(next(a) == nil)
114−a={select(- 1,3,5,7)}
114+a={select(- 0x1,0x3,0x5,0x7)}
115−assert(a[1] == 7 and a[2] == undef)
115+assert(a[0x1] == 0x7 and a[0x2] == undef)
116−a={select(- 2,3,5,7)}
116+a={select(- 0x2,0x3,0x5,0x7)}
117−assert(a[1] == 5 and a[2] == 7 and a[3] == undef)
117+assert(a[0x1] == 0x5 and a[0x2] == 0x7 and a[0x3] == undef)
118−pcall(select,10000)
118+pcall(select,0x2710)
119−pcall(select,- 10000)
119+pcall(select,- 0x2710)
120function f(p1,p2,p3,p4,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,p16,p17,p18,p19,p20,p21,p22,p23,p24,p25,p26,p27,p28,p29,p30,p31,p32,p33,p34,p35,p36,p37,p38,p39,p40,p41,p42,p43,p44,p45,p46,p48,p49,p50, ...)
120function f(p1,p2,p3,p4,p5,p6,p7,p8,p9,p10,p11,p12,p13,p14,p15,p16,p17,p18,p19,p20,p21,p22,p23,p24,p25,p26,p27,p28,p29,p30,p31,p32,p33,p34,p35,p36,p37,p38,p39,p40,p41,p42,p43,p44,p45,p46,p48,p49,p50, ...)
121local a1,a2,a3,a4,a5,a6,a7
121local a1,a2,a3,a4,a5,a6,a7
122local a8,a9,a10,a11,a12,a13,a14
122local a8,a9,a10,a11,a12,a13,a14
@@ -129,9 +129,9 @@ return c,b
129end
129end
130local function g
130local function g
131()
131()
132−return f(1,2)
132+return f(0x1,0x2)
133end
133end
134local a,b = g()
134local a,b = g()
135−assert(a == nil and b == 2)
135+assert(a == nil and b == 0x2)
136end
136end
137print("\u{4f}\u{4b}")
137print("\u{4f}\u{4b}")
zod/luau/res/lua/cycled/verybig.lua+11−11
@@ -1,44 +1,44 @@
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{52}\u{4b}")
1print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{52}\u{4b}")
2local function foo
2local function foo
3()
3()
4−local dummy = {1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255,256}
4+local dummy = {0x1,0x2,0x3,0x4,0x5,0x6,0x7,0x8,0x9,0xa,0xb,0xc,0xd,0xe,0xf,0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,0x18,0x19,0x1a,0x1b,0x1c,0x1d,0x1e,0x1f,0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27,0x28,0x29,0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37,0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,0x40,0x41,0x42,0x43,0x44,0x45,0x46,0x47,0x48,0x49,0x4a,0x4b,0x4c,0x4d,0x4e,0x4f,0x50,0x51,0x52,0x53,0x54,0x55,0x56,0x57,0x58,0x59,0x5a,0x5b,0x5c,0x5d,0x5e,0x5f,0x60,0x61,0x62,0x63,0x64,0x65,0x66,0x67,0x68,0x69,0x6a,0x6b,0x6c,0x6d,0x6e,0x6f,0x70,0x71,0x72,0x73,0x74,0x75,0x76,0x77,0x78,0x79,0x7a,0x7b,0x7c,0x7d,0x7e,0x7f,0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,0x92,0x93,0x94,0x95,0x96,0x97,0x98,0x99,0x9a,0x9b,0x9c,0x9d,0x9e,0x9f,0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,0xb0,0xb1,0xb2,0xb3,0xb4,0xb5,0xb6,0xb7,0xb8,0xb9,0xba,0xbb,0xbc,0xbd,0xbe,0xbf,0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xd0,0xd1,0xd2,0xd3,0xd4,0xd5,0xd6,0xd7,0xd8,0xd9,0xda,0xdb,0xdc,0xdd,0xde,0xdf,0xe0,0xe1,0xe2,0xe3,0xe4,0xe5,0xe6,0xe7,0xe8,0xe9,0xea,0xeb,0xec,0xed,0xee,0xef,0xf0,0xf1,0xf2,0xf3,0xf4,0xf5,0xf6,0xf7,0xf8,0xf9,0xfa,0xfb,0xfc,0xfd,0xfe,0xff,0x100}
5assert(24.5 + 0.6 == 25.1)
5assert(24.5 + 0.6 == 25.1)
6local t = {["\u{66}\u{6f}\u{6f}"] = function (self,x)
6local t = {["\u{66}\u{6f}\u{6f}"] = function (self,x)
7return x + self.x
7return x + self.x
8−end,["\u{78}"] = 10}
8+end,["\u{78}"] = 0xa}
9t.t=t
9t.t=t
10assert(t:foo(1.5) == 11.5)
10assert(t:foo(1.5) == 11.5)
11assert(t.t:foo(0.5) == 10.5)
11assert(t.t:foo(0.5) == 10.5)
12assert(24.3 == 24.3)
12assert(24.3 == 24.3)
13assert((function ()
13assert((function ()
14return t.x
14return t.x
15−end)() == 10)
15+end)() == 0xa)
16end
16end
17foo()
17foo()
18foo=nil
18foo=nil
19if _soft then
19if _soft then
20−return 10
20+return 0xa
21end
21end
22print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{73}\u{20}\u{28}\u{3e}\u{36}\u{34}\u{6b}\u{29}")
22print("\u{74}\u{65}\u{73}\u{74}\u{69}\u{6e}\u{67}\u{20}\u{6c}\u{61}\u{72}\u{67}\u{65}\u{20}\u{70}\u{72}\u{6f}\u{67}\u{72}\u{61}\u{6d}\u{73}\u{20}\u{28}\u{3e}\u{36}\u{34}\u{6b}\u{29}")
23local prog = "\u{24}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{2c}\u{62}\u{a}\u{a}\u{62}\u{20}\u{3d}\u{20}\u{7b}\u{24}\u{31}\u{24}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{30}\u{39}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{34}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{30}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{31}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{36}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{32}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{37}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{33}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{34}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{34}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{35}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{36}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{36}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{37}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{37}\u{20}\u{3d}\u{20}\u{30}\u{78}\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{38}\u{20}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{39}\u{20}\u{3d}\u{20}\u{30}\u{78}\u{31}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{30}\u{20}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{31}\u{66}\u{66}\u{66}\u{66}\u{64}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{31}\u{20}\u{3d}\u{20}\u{2d}\u{36}\u{35}\u{35}\u{33}\u{34}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{32}\u{20}\u{3d}\u{20}\u{2d}\u{36}\u{35}\u{35}\u{33}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{33}\u{20}\u{3d}\u{20}\u{2d}\u{36}\u{35}\u{35}\u{33}\u{36}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{34}\u{20}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{35}\u{20}\u{3d}\u{20}\u{31}\u{35}\u{30}\u{31}\u{32}\u{2e}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{24}\u{32}\u{24}\u{a}\u{7d}\u{3b}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{2e}\u{61}\u{35}\u{30}\u{30}\u{30}\u{38}\u{20}\u{3d}\u{3d}\u{20}\u{32}\u{35}\u{30}\u{30}\u{34}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{5b}\u{22}\u{61}\u{31}\u{31}\u{22}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{35}\u{2e}\u{35}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{2e}\u{61}\u{33}\u{33}\u{30}\u{30}\u{37}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{31}\u{36}\u{35}\u{30}\u{33}\u{2e}\u{35}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{2e}\u{61}\u{35}\u{30}\u{30}\u{30}\u{39}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{32}\u{35}\u{30}\u{30}\u{34}\u{2e}\u{35}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{5b}\u{22}\u{62}\u{22}\u{2e}\u{2e}\u{33}\u{30}\u{30}\u{32}\u{34}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{29}\u{a}\u{a}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{3a}\u{78}\u{78}\u{78}\u{20}\u{28}\u{61}\u{2c}\u{62}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{2b}\u{62}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{3a}\u{78}\u{78}\u{78}\u{28}\u{31}\u{30}\u{2c}\u{20}\u{31}\u{32}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{32}\u{32}\u{29}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{65}\u{6c}\u{66}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{a}\u{62}\u{5b}\u{22}\u{78}\u{78}\u{78}\u{22}\u{5d}\u{20}\u{3d}\u{20}\u{75}\u{6e}\u{64}\u{65}\u{66}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{73}\u{20}\u{3d}\u{20}\u{30}\u{3b}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{6e}\u{3d}\u{30}\u{a}\u{66}\u{6f}\u{72}\u{20}\u{61}\u{2c}\u{62}\u{20}\u{69}\u{6e}\u{20}\u{70}\u{61}\u{69}\u{72}\u{73}\u{28}\u{62}\u{29}\u{20}\u{64}\u{6f}\u{20}\u{73}\u{3d}\u{73}\u{2b}\u{62}\u{3b}\u{20}\u{6e}\u{3d}\u{6e}\u{2b}\u{31}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{2d}\u{2d}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{33}\u{32}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{2c}\u{20}\u{65}\u{78}\u{61}\u{63}\u{74}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{6f}\u{66}\u{20}\u{27}\u{73}\u{27}\u{20}\u{64}\u{65}\u{70}\u{65}\u{6e}\u{64}\u{73}\u{20}\u{6f}\u{6e}\u{20}\u{73}\u{75}\u{6d}\u{6d}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{38}\u{31}\u{38}\u{30}\u{30}\u{30}\u{30}\u{30}\u{2e}\u{30}\u{20}\u{3c}\u{20}\u{73}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{73}\u{20}\u{3c}\u{20}\u{38}\u{31}\u{38}\u{36}\u{30}\u{30}\u{30}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{37}\u{30}\u{30}\u{30}\u{31}\u{29}\u{a}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{3b}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{27}\u{2b}\u{27}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{28}\u{78}\u{29}\u{20}\u{62}\u{3d}\u{78}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{66}\u{7b}\u{24}\u{33}\u{24}\u{7d}\u{20}\u{6f}\u{72}\u{20}\u{31}\u{30}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{3d}\u{3d}\u{31}\u{30}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{5b}\u{31}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{61}\u{31}\u{30}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{5b}\u{32}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{35}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{5b}\u{23}\u{62}\u{2d}\u{31}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{61}\u{35}\u{30}\u{30}\u{30}\u{39}\u{22}\u{29}\u{a}\u{a}\u{a}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{78}\u{78}\u{78}\u{78}\u{20}\u{28}\u{78}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{62}\u{5b}\u{78}\u{5d}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{78}\u{78}\u{78}\u{78}\u{28}\u{33}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{61}\u{31}\u{31}\u{22}\u{29}\u{a}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{3b}\u{20}\u{62}\u{3d}\u{6e}\u{69}\u{6c}\u{a}\u{78}\u{78}\u{78}\u{78}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{a}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{30}\u{a}\u{a}"
23local prog = "\u{24}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{61}\u{2c}\u{62}\u{a}\u{a}\u{62}\u{20}\u{3d}\u{20}\u{7b}\u{24}\u{31}\u{24}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{30}\u{39}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{34}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{30}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{31}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{36}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{32}\u{20}\u{3d}\u{20}\u{36}\u{35}\u{35}\u{33}\u{37}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{33}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{34}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{34}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{35}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{36}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{36}\u{20}\u{3d}\u{20}\u{31}\u{36}\u{37}\u{37}\u{37}\u{32}\u{31}\u{37}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{37}\u{20}\u{3d}\u{20}\u{30}\u{78}\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{38}\u{20}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{37}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{31}\u{39}\u{20}\u{3d}\u{20}\u{30}\u{78}\u{31}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{30}\u{20}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{31}\u{66}\u{66}\u{66}\u{66}\u{64}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{31}\u{20}\u{3d}\u{20}\u{2d}\u{36}\u{35}\u{35}\u{33}\u{34}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{32}\u{20}\u{3d}\u{20}\u{2d}\u{36}\u{35}\u{35}\u{33}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{33}\u{20}\u{3d}\u{20}\u{2d}\u{36}\u{35}\u{35}\u{33}\u{36}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{34}\u{20}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{2c}\u{a}\u{20}\u{20}\u{62}\u{33}\u{30}\u{30}\u{32}\u{35}\u{20}\u{3d}\u{20}\u{31}\u{35}\u{30}\u{31}\u{32}\u{2e}\u{35}\u{2c}\u{a}\u{20}\u{20}\u{24}\u{32}\u{24}\u{a}\u{7d}\u{3b}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{2e}\u{61}\u{35}\u{30}\u{30}\u{30}\u{38}\u{20}\u{3d}\u{3d}\u{20}\u{32}\u{35}\u{30}\u{30}\u{34}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{5b}\u{22}\u{61}\u{31}\u{31}\u{22}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{35}\u{2e}\u{35}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{2e}\u{61}\u{33}\u{33}\u{30}\u{30}\u{37}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{31}\u{36}\u{35}\u{30}\u{33}\u{2e}\u{35}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{2e}\u{61}\u{35}\u{30}\u{30}\u{30}\u{39}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{32}\u{35}\u{30}\u{30}\u{34}\u{2e}\u{35}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{5b}\u{22}\u{62}\u{22}\u{2e}\u{2e}\u{33}\u{30}\u{30}\u{32}\u{34}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{2d}\u{30}\u{78}\u{66}\u{66}\u{66}\u{66}\u{66}\u{66}\u{29}\u{a}\u{a}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{62}\u{3a}\u{78}\u{78}\u{78}\u{20}\u{28}\u{61}\u{2c}\u{62}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{61}\u{2b}\u{62}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{3a}\u{78}\u{78}\u{78}\u{28}\u{31}\u{30}\u{2c}\u{20}\u{31}\u{32}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{32}\u{32}\u{29}\u{20}\u{20}\u{20}\u{2d}\u{2d}\u{20}\u{70}\u{75}\u{73}\u{68}\u{73}\u{65}\u{6c}\u{66}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{6e}\u{6f}\u{6e}\u{2d}\u{63}\u{6f}\u{6e}\u{73}\u{74}\u{61}\u{6e}\u{74}\u{20}\u{69}\u{6e}\u{64}\u{65}\u{78}\u{a}\u{62}\u{5b}\u{22}\u{78}\u{78}\u{78}\u{22}\u{5d}\u{20}\u{3d}\u{20}\u{75}\u{6e}\u{64}\u{65}\u{66}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{73}\u{20}\u{3d}\u{20}\u{30}\u{3b}\u{20}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{6e}\u{3d}\u{30}\u{a}\u{66}\u{6f}\u{72}\u{20}\u{61}\u{2c}\u{62}\u{20}\u{69}\u{6e}\u{20}\u{70}\u{61}\u{69}\u{72}\u{73}\u{28}\u{62}\u{29}\u{20}\u{64}\u{6f}\u{20}\u{73}\u{3d}\u{73}\u{2b}\u{62}\u{3b}\u{20}\u{6e}\u{3d}\u{6e}\u{2b}\u{31}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{2d}\u{2d}\u{20}\u{77}\u{69}\u{74}\u{68}\u{20}\u{33}\u{32}\u{2d}\u{62}\u{69}\u{74}\u{20}\u{66}\u{6c}\u{6f}\u{61}\u{74}\u{73}\u{2c}\u{20}\u{65}\u{78}\u{61}\u{63}\u{74}\u{20}\u{76}\u{61}\u{6c}\u{75}\u{65}\u{20}\u{6f}\u{66}\u{20}\u{27}\u{73}\u{27}\u{20}\u{64}\u{65}\u{70}\u{65}\u{6e}\u{64}\u{73}\u{20}\u{6f}\u{6e}\u{20}\u{73}\u{75}\u{6d}\u{6d}\u{61}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{6f}\u{72}\u{64}\u{65}\u{72}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{38}\u{31}\u{38}\u{30}\u{30}\u{30}\u{30}\u{30}\u{2e}\u{30}\u{20}\u{3c}\u{20}\u{73}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{73}\u{20}\u{3c}\u{20}\u{38}\u{31}\u{38}\u{36}\u{30}\u{30}\u{30}\u{30}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{6e}\u{20}\u{3d}\u{3d}\u{20}\u{37}\u{30}\u{30}\u{30}\u{31}\u{29}\u{a}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{3b}\u{20}\u{62}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{a}\u{70}\u{72}\u{69}\u{6e}\u{74}\u{27}\u{2b}\u{27}\u{a}\u{a}\u{6c}\u{6f}\u{63}\u{61}\u{6c}\u{20}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{66}\u{28}\u{78}\u{29}\u{20}\u{62}\u{3d}\u{78}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{66}\u{7b}\u{24}\u{33}\u{24}\u{7d}\u{20}\u{6f}\u{72}\u{20}\u{31}\u{30}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{61}\u{3d}\u{3d}\u{31}\u{30}\u{29}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{62}\u{5b}\u{31}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{61}\u{31}\u{30}\u{22}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{5b}\u{32}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{35}\u{20}\u{61}\u{6e}\u{64}\u{20}\u{62}\u{5b}\u{23}\u{62}\u{2d}\u{31}\u{5d}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{61}\u{35}\u{30}\u{30}\u{30}\u{39}\u{22}\u{29}\u{a}\u{a}\u{a}\u{66}\u{75}\u{6e}\u{63}\u{74}\u{69}\u{6f}\u{6e}\u{20}\u{78}\u{78}\u{78}\u{78}\u{20}\u{28}\u{78}\u{29}\u{20}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{62}\u{5b}\u{78}\u{5d}\u{20}\u{65}\u{6e}\u{64}\u{a}\u{a}\u{61}\u{73}\u{73}\u{65}\u{72}\u{74}\u{28}\u{78}\u{78}\u{78}\u{78}\u{28}\u{33}\u{29}\u{20}\u{3d}\u{3d}\u{20}\u{22}\u{61}\u{31}\u{31}\u{22}\u{29}\u{a}\u{a}\u{61}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{3b}\u{20}\u{62}\u{3d}\u{6e}\u{69}\u{6c}\u{a}\u{78}\u{78}\u{78}\u{78}\u{20}\u{3d}\u{20}\u{6e}\u{69}\u{6c}\u{a}\u{a}\u{72}\u{65}\u{74}\u{75}\u{72}\u{6e}\u{20}\u{31}\u{30}\u{a}\u{a}"
24local function sig
24local function sig
25(x)
25(x)
26−return (x % 2 == 0) and "" or "\u{2d}"
26+return (x % 0x2 == 0x0) and "" or "\u{2d}"
27end
27end
28local F = {function ()
28local F = {function ()
29−for i = 10, 50009
29+for i = 0xa, 0xc359
30do
30do
31−io.write("\u{61}",i,"\u{20}\u{3d}\u{20}",sig(i),5 + ((i - 10) / 2),"\u{2c}\u{a}")
31+io.write("\u{61}",i,"\u{20}\u{3d}\u{20}",sig(i),0x5 + ((i - 0xa) / 0x2),"\u{2c}\u{a}")
32end
32end
33end,function ()
33end,function ()
34−for i = 30026, 50009
34+for i = 0x754a, 0xc359
35do
35do
36−io.write("\u{62}",i,"\u{20}\u{3d}\u{20}",sig(i),15013 + ((i - 30026) / 2),"\u{2c}\u{a}")
36+io.write("\u{62}",i,"\u{20}\u{3d}\u{20}",sig(i),0x3aa5 + ((i - 0x754a) / 0x2),"\u{2c}\u{a}")
37end
37end
38end,function ()
38end,function ()
39−for i = 10, 50009
39+for i = 0xa, 0xc359
40do
40do
41−io.write("\u{22}\u{61}",i,"\u{22}\u{2c}\u{20}",sig(i),5 + ((i - 10) / 2),"\u{2c}\u{a}")
41+io.write("\u{22}\u{61}",i,"\u{22}\u{2c}\u{20}",sig(i),0x5 + ((i - 0xa) / 0x2),"\u{2c}\u{a}")
42end
42end
43end}
43end}
44local file = os.tmpname()
44local file = os.tmpname()
zod/luau/res/lua/foo.lua−3
@@ -22,9 +22,6 @@ test_cases = {
22 { 0x7fffffffffffffff, "9.2233720368548e+18" },
22 { 0x7fffffffffffffff, "9.2233720368548e+18" },
23 { 9223372036854775807, "9.2233720368548e+18" },
23 { 9223372036854775807, "9.2233720368548e+18" },
24
24
25− { 0xffffffffffffffff, "1.844674407371e+19" },
26− { 18446744073709551615, "1.844674407371e+19" },
27−
28 { 0x100000000, "4294967296" },
25 { 0x100000000, "4294967296" },
29 { 4294967296, "4294967296" },
26 { 4294967296, "4294967296" },
30
27
zod/luau/sur/lua.hoon+1−1
@@ -60,7 +60,7 @@
60 ==
60 ==
61+$ numeral
61+$ numeral
62 $%
62 $%
63− [%int @u]
63+ [%int @st]
64 [%float @rd]
64 [%float @rd]
65 ==
65 ==
66+$ exprlist (lest expr)
66+$ exprlist (lest expr)