[Haskell-cafe] New to Haskell

Miguel Mitrofanov miguelimo38 at yandex.ru
Tue Dec 18 05:25:18 EST 2007


> >> - the syntax for an expression
> >> - the syntax for a block
> > Don't see your point.
> The point is the syntax is introduced as transformation of layout form to  
> non layout form.
> As a user, I just want to be able to spot the basic components of a source  
> file without thinking about transformation rules.

Well, most users are.

> > Oh, that's pretty easy, parenthesized expression is not divided by a  
> > comma.
> Thanks! What is the end of a block ? What introduce new blocks ?

Not sure what you mean by "block" here.

> Is this legal (`plus`) x y ?

Never tried to write this myself, it looks stupid.

> It's this a tuple ?  ([a,b,c,d ]) ?

No, since all commas are in the subexpression.

> > then your putStrLn would be performed twice. IO actions are first-class  
> > values, that's a feature, not a bug.
> What guarantees that by running the main, the string "Hello world" will be  
> printed exactly twice ?

What kind of guarantees do you want?

> I just want the sistem to be able to print one of these expressions !
> Its this too much to ask ?

Yes, 'cause it means you want to embed almost all source code into the compiled program.


More information about the Haskell-Cafe mailing list