[Haskell-beginners] Re: Top beginner mistakes

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Mon Mar 9 02:24:23 EDT 2009


On 2009 Mar 8, at 21:55, 7stud wrote:
> Benjamin L. Russell <DekuDekuplex <at> Yahoo.com> writes:
>>>> Common Misunderstandings - HaskellWiki
>>>> http://www.haskell.org/haskellwiki/Common_Misunderstandings
>
> I thought I'd point out something wrong with the first beginner
> mistake listed on that page:
>
> My tests show that the 'then' and 'else' do not have to be indented
> more than the 'if':

They do, but only within layout, i.e. a "let" or "do", because  
otherwise they fall outside the layout block.

-- 
brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university    KF8NH


-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 195 bytes
Desc: This is a digitally signed message part
Url : http://www.haskell.org/pipermail/beginners/attachments/20090309/010df599/PGP.bin


More information about the Beginners mailing list