<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>



<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">

<h3>
 Marge Bot pushed to branch master
at <a href="https://gitlab.haskell.org/ghc/ghc">Glasgow Haskell Compiler / GHC</a>
</h3>
<h4>
Commits:
</h4>
<ul>
<li>
<strong><a href="https://gitlab.haskell.org/ghc/ghc/-/commit/4f461e1a31263f052effd03738b11ea123512cb0">4f461e1a</a></strong>
<div>
<span>by Vladislav Zavialov</span>
<i>at 2020-09-17T08:52:19-04:00</i>
</div>
<pre class="commit-message" style="white-space: pre-wrap; margin: 0;">Parser.y: clarify treatment of @{-# UNPACK #-}

Before this patch, we had this parser production:

        ftype : ...
              | ftype PREFIX_AT tyarg  { ... }

And 'tyarg' is defined as follows:

        tyarg : atype              { ... }
              | unpackedness atype { ... }

So one might get the (false) impression that that parser production is
intended to parse things like:

        F @{-# UNPACK #-} X

However, the lexer wouldn't produce PREFIX_AT followed by 'unpackedness',
as the '@' operator followed by '{-' is not considered prefix.

Thus there's no point using 'tyarg' after PREFIX_AT,
and a simple 'atype' will suffice:

        ftype : ...
              | ftype PREFIX_AT atype  { ... }

This change has no user-facing consequences. It just makes the grammar a
bit more clear.
</pre>
</li>
</ul>
<h4>1 changed file:</h4>
<ul>
<li class="file-stats">
<a href="#bf951467d4a9aa443cb109cb4c84a2891945649b">
compiler/GHC/Parser.y
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id="bf951467d4a9aa443cb109cb4c84a2891945649b">
<a href="https://gitlab.haskell.org/ghc/ghc/-/commit/4f461e1a31263f052effd03738b11ea123512cb0#bf951467d4a9aa443cb109cb4c84a2891945649b"><strong>compiler/GHC/Parser.y</strong></a>
<hr>
<table class="code white" style="font-family: monospace; font-size: 90%;" bgcolor="#fff" width="100%" cellpadding="0" cellspacing="0">
<tr class="line_holder match" id="" style="line-height: 1.6;">
<td class="diff-line-num unfold js-unfold old_line" data-linenumber="1981" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="diff-line-num unfold js-unfold new_line" data-linenumber="1981" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">...</td>
<td class="line_content match " style="padding-left: 0.5em; padding-right: 0.5em; color: rgba(0,0,0,0.3);" bgcolor="#fafafa">@@ -1981,7 +1981,7 @@ ftype :: { forall b. DisambTD b => PV (Located b) }</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="1981" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1981
</td>
<td class="diff-line-num new_line" data-linenumber="1981" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1981
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC1981" class="line" lang="haskell">        <span class="o" style="font-weight: 600;">|</span> <span class="n" style="color: #333;">tyop</span>                          <span class="p">{</span> <span class="n" style="color: #333;">failOpFewArgs</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="p">}</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="1982" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1982
</td>
<td class="diff-line-num new_line" data-linenumber="1982" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1982
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC1982" class="line" lang="haskell">        <span class="o" style="font-weight: 600;">|</span> <span class="n" style="color: #333;">ftype</span> <span class="n" style="color: #333;">tyarg</span>                   <span class="p">{</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">>>=</span> <span class="nf" style="color: #900; font-weight: 600;">\</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">-></span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="1983" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1983
</td>
<td class="diff-line-num new_line" data-linenumber="1983" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1983
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC1983" class="line" lang="haskell">                                          <span class="n" style="color: #333;">mkHsAppTyPV</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">2</span> <span class="p">}</span></span>
</pre>
</td>
</tr>
<tr class="line_holder old" id="" style="line-height: 1.6;">
<td class="diff-line-num old old_line" data-linenumber="1984" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
1984
</td>
<td class="diff-line-num new_line old" data-linenumber="1984" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #fac5cd; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#f9d7dc">
 
</td>
<td class="line_content old" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#fbe9eb">
<pre style="margin: 0;">-<span id="LC1984" class="line" lang="haskell">        <span class="o" style="font-weight: 600;">|</span> <span class="n" style="color: #333;">ftype</span> <span class="kt" style="color: #458; font-weight: 600;">PREFIX_AT</span> <span class="n" style="color: #333;"><span class="idiff left right">tyarg</span></span>         <span class="p">{</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">>>=</span> <span class="nf" style="color: #900; font-weight: 600;">\</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">-></span></span>
</pre>
</td>
</tr>
<tr class="line_holder new" id="" style="line-height: 1.6;">
<td class="diff-line-num new old_line" data-linenumber="1985" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
 
</td>
<td class="diff-line-num new new_line" data-linenumber="1984" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #c7f0d2; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#ddfbe6">
1984
</td>
<td class="line_content new" style="padding-left: 0.5em; padding-right: 0.5em;" bgcolor="#ecfdf0">
<pre style="margin: 0;">+<span id="LC1984" class="line" lang="haskell">        <span class="o" style="font-weight: 600;">|</span> <span class="n" style="color: #333;">ftype</span> <span class="kt" style="color: #458; font-weight: 600;">PREFIX_AT</span> <span class="n" style="color: #333;"><span class="idiff left right">atype</span></span>         <span class="p">{</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">>>=</span> <span class="nf" style="color: #900; font-weight: 600;">\</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="o" style="font-weight: 600;">-></span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="1985" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1985
</td>
<td class="diff-line-num new_line" data-linenumber="1985" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1985
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC1985" class="line" lang="haskell">                                          <span class="n" style="color: #333;">mkHsAppKindTyPV</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">1</span> <span class="p">(</span><span class="n" style="color: #333;">getLoc</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">2</span><span class="p">)</span> <span class="o" style="font-weight: 600;">$</span><span class="mi" style="color: #099;">3</span> <span class="p">}</span></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="1986" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1986
</td>
<td class="diff-line-num new_line" data-linenumber="1986" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1986
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC1986" class="line" lang="haskell"></span>
</pre>
</td>
</tr>
<tr class="line_holder" id="" style="line-height: 1.6;">
<td class="diff-line-num old_line" data-linenumber="1987" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1987
</td>
<td class="diff-line-num new_line" data-linenumber="1987" style="width: 35px; color: rgba(0,0,0,0.3); border-right-width: 1px; border-right-color: #f0f0f0; border-right-style: solid; padding: 0 5px;" align="right" bgcolor="#fafafa">
1987
</td>
<td class="line_content" style="padding-left: 0.5em; padding-right: 0.5em;">
<pre style="margin: 0;"> <span id="LC1987" class="line" lang="haskell"><span class="n" style="color: #333;">tyarg</span> <span class="o" style="font-weight: 600;">::</span> <span class="p">{</span> <span class="kt" style="color: #458; font-weight: 600;">LHsType</span> <span class="kt" style="color: #458; font-weight: 600;">GhcPs</span> <span class="p">}</span></span>
</pre>
</td>
</tr>

</table>
<br>
</li>

</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #777;">

<br>
<a href="https://gitlab.haskell.org/ghc/ghc/-/commit/4f461e1a31263f052effd03738b11ea123512cb0">View it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.haskell.org.
If you'd like to receive fewer emails, you can
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Commit","url":"https://gitlab.haskell.org/ghc/ghc/-/commit/4f461e1a31263f052effd03738b11ea123512cb0"}}</script>


</p>
</div>
</body>
</html>