# RequiredTypeArguments does not imply ExplicitForAll

**URL:** <https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313>\
**Category:** Learn\
**Created:** [November 24, 2025, 1:48am UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313 "2025-11-24T01:48:20Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![ashokkimmel](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/ashokkimmel/32/5111_2.png) [@ashokkimmel](https://discourse.haskell.org/u/ashokkimmel)\
**Post date:** [November 24, 2025, 1:48am UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/1 "2025-11-24T01:48:20Z")

</div>

I just don’t get it, is it a bug? The latter is necessitated by the former.

---

<div class="post-metadata">

**Author:** ![eldritch-cookie](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/eldritch-cookie/32/4130_2.png) [@eldritch-cookie](https://discourse.haskell.org/u/eldritch-cookie)\
**Post date:** [November 24, 2025, 1:22pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/2 "2025-11-24T13:22:11Z")

</div>

`forall var.` is invisible quantification, and `forall var ->` is visible quantification they are different things the fact they both use forall is immaterial the is no difference from the hypothetical case where ìnvisible quantification uses `forallI var.` and visible quantification uses `forallV var.` it is only a bug if you can’t write something like

```haskell
{-# LANGUAGE RequiredTypeArguments #-}
import Foreign

mySizeOf :: forall s -> Storable s => Int
mySizeOf myType = sizeOf (undefined :: myType)

main :: IO ()
main = print $ mySizeOf Int

```

EDIT: nevermind if i use NoExplicitForAll it doesn’t compile which is a bug.

---

<div class="post-metadata">

**Author:** ![ashokkimmel](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/ashokkimmel/32/5111_2.png) [@ashokkimmel](https://discourse.haskell.org/u/ashokkimmel)\
**Post date:** [November 24, 2025, 2:08pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/3 "2025-11-24T14:08:43Z")

</div>

How can I get it fixed? Is there already a ticket?

---

<div class="post-metadata">

**Author:** ![eldritch-cookie](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/eldritch-cookie/32/4130_2.png) [@eldritch-cookie](https://discourse.haskell.org/u/eldritch-cookie)\
**Post date:** [November 24, 2025, 2:29pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/4 "2025-11-24T14:29:22Z")

</div>

ghc issues should be reported on the ghc gitlab [Issues · Glasgow Haskell Compiler / GHC · GitLab](https://gitlab.haskell.org/ghc/ghc/-/issues)

---

<div class="post-metadata">

**Author:** ![int-index](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/int-index/32/4156_2.png) [@int-index](https://discourse.haskell.org/u/int-index)\
**Post date:** [November 24, 2025, 10:57pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/5 "2025-11-24T22:57:24Z")

</div>

I think it’s fair to call this a bug.

It wasn’t caught during development because `ExplicitForAll` is included in `GHC2021`, which is the default nowadays, and you need to explicitly specify `Haskell98` or `Haskell2010` to observe the issue.

The patch to fix this should be trivial, would you like to submit one?

---

<div class="post-metadata">

**Author:** ![ashokkimmel](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/ashokkimmel/32/5111_2.png) [@ashokkimmel](https://discourse.haskell.org/u/ashokkimmel)\
**Post date:** [November 25, 2025, 2:21pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/6 "2025-11-25T14:21:30Z")

</div>

Not really, I’m kind of scared of all things to you related after I tried to investigate how to make a plugin, I just wanted to bring it to someone’s attention.

---

<div class="post-metadata">

**Author:** ![ashokkimmel](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/ashokkimmel/32/5111_2.png) [@ashokkimmel](https://discourse.haskell.org/u/ashokkimmel)\
**Post date:** [December 15, 2025, 2:44pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/7 "2025-12-15T14:44:00Z")

</div>

Should I submit a patch? Or has it already been dealt with?

---

<div class="post-metadata">

**Author:** ![int-index](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.haskell.org/int-index/32/4156_2.png) [@int-index](https://discourse.haskell.org/u/int-index)\
**Post date:** [December 15, 2025, 3:23pm UTC](https://discourse.haskell.org/t/requiredtypearguments-does-not-imply-explicitforall/13313/8 "2025-12-15T15:23:24Z")

</div>

I’ve just checked and it hasn’t been dealt with. The steps to deal with this are:

1. Create a ticket on GHC’s issue tracker
2. Submit a patch to fix it:
  - modify `impliedXFlags` in `compiler/GHC/Driver/Flags.hs`
  - add a test case to `testsuite/tests/vdq-rta/`

The page [contributing · Wiki · Glasgow Haskell Compiler / GHC · GitLab](https://gitlab.haskell.org/ghc/ghc/-/wikis/contributing) explains how to build GHC, test it, etc.
