I believe this is just a bug, since the desugaring ought to be strict in
the \x.
On Tue, Dec 8, 2015 at 6:35 PM, Ömer Sinan Ağacan
wrote:
> I think this is a problem/bug in the implementation. In the "function
> definitions" section of the wiki page it says the argument
I agree that this seems to be a bug. I have a lot to do currently, but
might be able to look at it sometime during next week.
Adam Sandberg Eriksson
On Thu, 10 Dec 2015, at 03:34 PM, Johan Tibell wrote:
> I believe this is just a bug, since the desugaring ought to be strict
> in the \x.
>
> On
In which case, I've created a ticket to record this bug and to track its
fix:
https://ghc.haskell.org/trac/ghc/ticket/11193
On 10 December 2015 at 15:26, Adam Sandberg Eriksson <
a...@sandbergericsson.se> wrote:
> I agree that this seems to be a bug. I have a lot to do currently, but
> might be
While there's a fundamental difference between (>>=) and let-bindings,
it might be worth adding to the docs that -XStrict only makes let
bindings strict.
On 12/08/2015 06:22 PM, Rob Stewart wrote:
> Are the following two programs equivalent with respect to the strictness
> of `readFile`?
>
>
Are the following two programs equivalent with respect to the strictness
of `readFile`?
--8<---cut here---start->8---
{-# LANGUAGE BangPatterns #-}
module Main where
main = do
!contents <- readFile "foo.txt"
print contents
--8<---cut
I think this is a problem/bug in the implementation. In the "function
definitions" section of the wiki page it says the argument will have a
bang pattern. But then this code:
do x <- ...
return (x + 1)
which is just a syntactic sugar for `... >>= \x -> return (x + 1)`
doesn't have the