diff options
author | Luite Stegeman <stegeman@gmail.com> | 2023-01-31 16:58:28 +0900 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2023-02-07 19:29:54 -0500 |
commit | 2ec1c359d90f20472e5800b5d1d8441dd22c1c73 (patch) | |
tree | b23d341371a9377e2dbfc7e0a1f5de56ca1807e4 | |
parent | 18d1c5f92b20edd2b42ae11bc5482dcea6a5758b (diff) | |
download | haskell-2ec1c359d90f20472e5800b5d1d8441dd22c1c73.tar.gz |
Fix marking async exceptions in the JS backend
Async exceptions are posted as a pair of the exception and
the thread object. This fixes the marking pass to correctly
follow the two elements of the pair.
Potentially fixes #22836
(cherry picked from commit 77a8234c5d284846e18c0a44ba5ee196059aaea6)
-rw-r--r-- | rts/js/gc.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/rts/js/gc.js b/rts/js/gc.js index 6c9934ed33..00def79daa 100644 --- a/rts/js/gc.js +++ b/rts/js/gc.js @@ -493,7 +493,8 @@ function h$follow(obj, sp) { } } for(i=0;i<c.excep.length;i++) { - ADDW(c.excep[i]); + ADDW(c.excep[i][0]); // the posting thread + ADDW(c.excep[i][1]); // the exception } } else if(c instanceof h$Transaction) { // - the accessed TVar values don't need to be marked |