diff options
author | Zubin Duggal <zubin.duggal@gmail.com> | 2021-06-24 17:55:53 +0530 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-06-28 10:46:29 -0400 |
commit | d4c43df13d428b1acee2149618f8503580303486 (patch) | |
tree | 11272acd7c630226fa4f9f6b0b97bd58a3fc3741 /docs | |
parent | 46c2d0b0ef4f2f2e43facdb84346f36a9d3169ec (diff) | |
download | haskell-d4c43df13d428b1acee2149618f8503580303486.tar.gz |
Update docs for change in parsing behaviour of infix operators like in GHC 9
Diffstat (limited to 'docs')
-rw-r--r-- | docs/users_guide/9.0.1-notes.rst | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/docs/users_guide/9.0.1-notes.rst b/docs/users_guide/9.0.1-notes.rst index 62aaef2a8f..32f4b14847 100644 --- a/docs/users_guide/9.0.1-notes.rst +++ b/docs/users_guide/9.0.1-notes.rst @@ -246,9 +246,15 @@ Language as ``f (-123)``, but ``x-123`` as ``(-) x 123``. Before this amendment, :extension:`NegativeLiterals` caused ``x-123`` to be parsed as ``x(-123)``. -* GHC now requires whitespace between infix operators and their arguments in - some cases where it was not previously necessary as the result of the +* GHC is now more sensitive to whitespace between infix operators and their arguments, + requiring it in some cases where it was not previously necessary as the result of the :ref:`whitespace-sensitive operator parsing proposal <https://github.com/ghc-proposals/ghc-proposals/pull/229>`. + It also affects the usage of ``!``,``~`` and ``@`` as BangPatterns, irrefutable patterns + and type applications respectively. + This means that expressions that were parsed as visible type applications + in previous versions when the ``@`` was surrounded by whitespace will now + be parsed as an operator application. + For more details see the `migration guide on the wiki <https://gitlab.haskell.org/ghc/ghc/-/wikis/migration/9.0#whitespace-sensitive-and->`. Compiler ~~~~~~~~ |