[Git][ghc/ghc][master] JS: check that tuple constructors are linked (#23709)
Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC Commits: cd7f7420 by Sylvain Henry at 2026-03-11T15:07:58-04:00 JS: check that tuple constructors are linked (#23709) Test js-mk_tup was failing before because tuple constructors weren't linked in. It's no longer an issue after the linker fixes. - - - - - 2 changed files: - testsuite/tests/javascript/js-mk_tup.hs - testsuite/tests/javascript/js-mk_tup.stdout Changes: ===================================== testsuite/tests/javascript/js-mk_tup.hs ===================================== @@ -40,44 +40,32 @@ mkTup9 = unsafeCoerce js_mk_tup9 mkTup10 :: (Int, Int, Int, Int, Int, Int, Int, Int, Int, Int) mkTup10 = unsafeCoerce js_mk_tup10 --- We have to use the Haskell tuple constructors here to make sure --- that the linker includes them in the final output for us to use --- in our JS code. main :: IO () main = do putStr "mkTup2: " - print $ mkTup2 == (101, 102) print mkTup2 putStr "mkTup3: " - print $ mkTup3 == (101, 102, 103) print mkTup3 putStr "mkTup4: " - print $ mkTup4 == (101, 102, 103, 104) print mkTup4 putStr "mkTup5: " - print $ mkTup5 == (101, 102, 103, 104, 105) print mkTup5 putStr "mkTup6: " - print $ mkTup6 == (101, 102, 103, 104, 105, 106) print mkTup6 putStr "mkTup7: " - print $ mkTup7 == (101, 102, 103, 104, 105, 106, 107) print mkTup7 putStr "mkTup8: " - print $ mkTup8 == (101, 102, 103, 104, 105, 106, 107, 108) print mkTup8 putStr "mkTup9: " - print $ mkTup9 == (101, 102, 103, 104, 105, 106, 107, 108, 109) print mkTup9 putStr "mkTup10: " - print $ mkTup10 == (101, 102, 103, 104, 105, 106, 107, 108, 109, 110) print mkTup10 ===================================== testsuite/tests/javascript/js-mk_tup.stdout ===================================== @@ -1,18 +1,9 @@ -mkTup2: True -(101,102) -mkTup3: True -(101,102,103) -mkTup4: True -(101,102,103,104) -mkTup5: True -(101,102,103,104,105) -mkTup6: True -(101,102,103,104,105,106) -mkTup7: True -(101,102,103,104,105,106,107) -mkTup8: True -(101,102,103,104,105,106,107,108) -mkTup9: True -(101,102,103,104,105,106,107,108,109) -mkTup10: True -(101,102,103,104,105,106,107,108,109,110) +mkTup2: (101,102) +mkTup3: (101,102,103) +mkTup4: (101,102,103,104) +mkTup5: (101,102,103,104,105) +mkTup6: (101,102,103,104,105,106) +mkTup7: (101,102,103,104,105,106,107) +mkTup8: (101,102,103,104,105,106,107,108) +mkTup9: (101,102,103,104,105,106,107,108,109) +mkTup10: (101,102,103,104,105,106,107,108,109,110) View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/cd7f742008454f4e5b9499631d3a64e7... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/cd7f742008454f4e5b9499631d3a64e7... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Marge Bot (@marge-bot)