Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Alex D
GHC
Commits
218dead0
Commit
218dead0
authored
Feb 07, 2014
by
eir@cis.upenn.edu
Browse files
Fix #8706, documenting that type operators are not promoted.
parent
312686c1
Changes
1
Hide whitespace changes
Inline
Side-by-side
docs/users_guide/glasgow_exts.xml
View file @
218dead0
...
...
@@ -6652,6 +6652,18 @@ See also <ulink url="http://ghc.haskell.org/trac/ghc/ticket/7347">Trac #7347</ul
</para>
</sect2>
<sect2>
<title>
Promoting type operators
</title>
<para>
Type operators are
<emphasis>
not
</emphasis>
promoted to the kind level. Why not? Because
<literal>
*
</literal>
is a kind, parsed the way identifiers are. Thus, if a programmer
tried to write
<literal>
Either * Bool
</literal>
, would it be
<literal>
Either
</literal>
applied to
<literal>
*
</literal>
and
<literal>
Bool
</literal>
? Or would it be
<literal>
*
</literal>
applied to
<literal>
Either
</literal>
and
<literal>
Bool
</literal>
.
To avoid this quagmire, we simply forbid promoting type operators to the kind level.
</para>
</sect2>
</sect1>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment