Skip to content

Backport: Fix for #18955 to GHC 8.10

Roland Senn requested to merge RolandSenn/ghc:T18955_4 into ghc-8.10

Since MR !554 (merged) (#15454 (closed)) GHCi automatically enabled the flag -fobject-code on any module using the UnboxedTuples or UnboxedSum extensions.

MR !1553 (closed) (#16876 (closed)) allowed to inhibit the automatic compiling to object-code of these modules by setting the fbyte-code flag. However, it assigned 2 different semantics to this flag and introduced the regression described in issue #18955 (closed).

This MR fixes this regression by unsetting the internal flag Opt_ByteCodeIfUnboxed before it's copied to DynFlags local to the module. In GHC 9.0.1 the issue is solved by introducing a new flag -f(no-)object-code-if-unboxed.

Edited by Roland Senn

Merge request reports