[GHC] #1171: GHC doesn't respect the imprecise exceptions semantics

Simon Marlow simonmarhaskell at gmail.com
Wed Feb 28 09:27:04 EST 2007


Simon Marlow wrote:
>> The code in YHC is roughly "if some list is empty then error "No files
>> found"
>> else error "Many files found"". If this code were changed to the
>> equivalent
>> of "error (if some list is empty then "No files found" else "Many files
>> found")", would there still be circumstances where the actual output
>> produced could vary?
> 
> Maybe.  If GHC knows that error is strict (which it might well do) then you could be back where you started.

Oops, error isn't strict, never mind.

Cheers,
	Simon





More information about the Glasgow-haskell-bugs mailing list