File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -203,7 +203,7 @@ function save_addr(name, addr)
203
203
end
204
204
205
205
local extended = false
206
- local start = data .intptr_t :find_one (search )
206
+ local start , start_addr = data .intptr_t :find_one (search )
207
207
if start then
208
208
extended = true
209
209
else
@@ -215,6 +215,11 @@ if not start then
215
215
qerror (' Could not find global table header' )
216
216
end
217
217
218
+ if extended then
219
+ -- structures only has types for an extended global table
220
+ save_addr (' global_table' , start_addr + (# search * data .intptr_t .esize ))
221
+ end
222
+
218
223
local index = 1
219
224
local entry_size = (extended and 3 or 2 )
220
225
while true do
@@ -236,3 +241,5 @@ while true do
236
241
end
237
242
index = index + 1
238
243
end
244
+
245
+ print (' global table length:' , index )
You can’t perform that action at this time.
0 commit comments