From 5ef693cb89bc222e3796ab540fa1ea9585951623 Mon Sep 17 00:00:00 2001 From: Chris Tate Date: Wed, 28 Oct 2026 00:34:57 -0500 Subject: [PATCH] Keep the promise identity keys in the Node island build of the async unit --- packages/runtime/src/scr_async.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/runtime/src/scr_async.c b/packages/runtime/src/scr_async.c index e3a654779..0225269f4 100644 --- a/packages/runtime/src/scr_async.c +++ b/packages/runtime/src/scr_async.c @@ -391,6 +391,9 @@ void scr_promise_share_identity(ScrPromise *dst, ScrPromise *src) { dst->identity->rc++; } +#ifdef SCR_NODE_ISLANDS +/* Node islands (NI-5) key their export table by a promise's identity + * (scr_node_island_export.c); other programs link none of this. */ const void *scr_promise_identity_key(ScrPromise *p) { if (!p->identity) { p->identity = malloc(sizeof *p->identity); @@ -406,6 +409,7 @@ void scr_promise_identity_drop(const void *key) { ScrPromiseIdentity *identity = (ScrPromiseIdentity *)key; if (--identity->rc == 0) free(identity); } +#endif bool scr_promise_identity_equal(ScrPromise *a, ScrPromise *b) { return a == b || (a->identity != NULL && a->identity == b->identity);