Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC Commits: 9c304ec0 by Sean D. Gillespie at 2025-09-29T19:57:07-04:00 Fix SIZED_BIN_OP_TY_INT casts in RTS interpreter Correct `SIZED_BIN_OP_TY_INT` cast to integer. Previously, it cast its second operand as its parameter `ty`. This does not currently cause any issues, since we are only using it for bit shifts. Fixes #26287 - - - - - 1 changed file: - rts/Interpreter.c Changes: ===================================== rts/Interpreter.c ===================================== @@ -2599,11 +2599,11 @@ run_BCO: #define SIZED_BIN_OP_TY_INT(op,ty) \ { \ if(sizeof(ty) > sizeof(StgWord)) { \ - ty r = ((ty) ReadSpW64(0)) op ((ty) ReadSpW(2)); \ + ty r = ((ty) ReadSpW64(0)) op ((StgInt) ReadSpW(2)); \ Sp_addW(1); \ SpW64(0) = (StgWord64) r; \ } else { \ - ty r = ((ty) ReadSpW(0)) op ((ty) ReadSpW(1)); \ + ty r = ((ty) ReadSpW(0)) op ((StgInt) ReadSpW(1)); \ Sp_addW(1); \ SpW(0) = (StgWord) r; \ }; \ View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/9c304ec00750b69acb854cd47e50bda0... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/9c304ec00750b69acb854cd47e50bda0... You're receiving this email because of your account on gitlab.haskell.org.