Any in foreign import prim should be lifted
This code fails Lint, or causes a panic without Lint:
{-# LANGUAGE GHCForeignImportPrim, MagicHash, UnliftedFFITypes #-}
module T where
import GHC.Exts
foreign import prim "test" test :: Any @(TYPE r) -> Int#
I think that Any
in foreign import prim was meant to be lifted-only. It was introduced in e29001c9 and #10460 (closed). Shouldn't be hard to fix.