3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2026-07-29 10:13:48 +00:00

fix: Use globalThis instead of global (#10249)

There are no `global`s in browser context. `globalThis` applied to both
browser and node.

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
yhx-12243 2026-07-27 23:23:40 +08:00 committed by GitHub
parent c1fa2dbfd6
commit 40d370b55b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2796,7 +2796,7 @@ export function createApi(Z3: Z3Core, em?: any): Z3HighLevel {
for (let i = 0; i < a.numEntries(); i++) {
const e = a.entry(i);
const n = e.numArgs();
const args = global.Array(n).map((_, i) => e.argValue(i));
const args = globalThis.Array.from({ length: n }, (_, i) => e.argValue(i));
funcInterp.addEntry(args, e.value());
}
return;