I've filed https://ghc.haskell.org/trac/ghc/ticket/14842 for it.
On 09/02/2018 10.24, Simon Peyton Jones via ghc-devs wrote:
> At very least the extension should be documented! Would you like to open
> a ticket for that? And even offer a patch?
___
Simon
From: ghc-devs [mailto:ghc-devs-boun...@haskell.org] On Behalf Of Harendra Kumar
Sent: 09 February 2018 02:43
To: Brandon Allbery <allber...@gmail.com>
Cc: ghc-devs@haskell.org Devs <ghc-devs@haskell.org>
Subject: Re: DoAndIfThenElse
Since I started programming in Haske
ber...@gmail.com>
Cc: ghc-devs@haskell.org Devs <ghc-devs@haskell.org>
Subject: Re: DoAndIfThenElse
Since I started programming in Haskell a few years ago I have been using
if-then-else in that manner without indentation and I never knew about this
extension. I thought this is how it wor
Since I started programming in Haskell a few years ago I have been using
if-then-else in that manner without indentation and I never knew about this
extension. I thought this is how it works. It seems this is the default
now. But, I remember encountering an error in an older compiler version
once
Hi,
not sure if this helps.
testsuite/tests/parser/should_compile/DoAndIfThenElse.hs gives us
```
{-# LANGUAGE DoAndIfThenElse #-}
module DoAndIfThenElse where
foo :: IO ()
foo = do if True
then return ()
else return ()
```
and there is some other mention in
Huh. I wonder if a section went missing; seems like none of the extensions
that alter or relax layout are documented currently.
(AlternativeLayoutRule, AlternativeLayoutRuleTransitional, DoAndIfThenElse,
NondecreasingIndentation, RelaxedLayout)
IIRC DoAndIfThenElse relaxes a condition implied by