On 23 Nov, Graeme Moss wrote:
>
> So no one minds that `--(Nothing)' is a comment whereas `--?Nothing?'
> is not a comment?
I think that this highlights the fact that the top-bit-set characters
were put into the language with relatively few distinctions; ASCII
brackets (){}[] are not include
Simon Peyton-Jones wrote:
>
> * Comments *start* with a lexeme, as previously discussed, and I think
>this is fine.
>
> * The opening lexeme may be '--', '---' etc for ordinary comments, or
>'{-' for nested comments
>
> * Note that '{--' is not a lexeme at all, so the maximal munch ru
> "Alex" == S Alexander Jacobson <[EMAIL PROTECTED]> writes:
Alex> Just to confirm, What is the official handling of:
>> main = putStr " -- Hello World "
Alex> and
>> main = putStr " {- this is not a comment -} "
in both cases the scanner is insi
> Actually, shouldn't "isn't" be parsed as a single varid? From the 1.4
> report:
OK, OK, let me change my example:
{- A comment, isn 't it? -}
-- Lennart
> I'd better make sure that scanning *can't* give an error, though.
There are several errors that can occur in the lex phase, e.g.,
'\q'bad character literal
"\q"bad string literal
\u0001 bad character in input
I REALLY dislike the idea of having my comment
> "Simon" == Simon Peyton-Jones <[EMAIL PROTECTED]> writes:
>> I don't understand this remark. Are you telling me that after
>> a '{-' token the usual lexical process is used to find the
>> matching '-}' token?
Simon> That's what I intended. Provided that scanning can't gi
| {- A comment, isn't it? -}
|despite the unmatched single quote.
Actually, shouldn't "isn't" be parsed as a single varid? From the 1.4
report:
"An identifier consists of a letter followed by zero or more letters,
digits, underscores, and single quotes."
I don't know of anywhere in the repor
> Come to think of it, that's good:
>
> {- This is a string "-}" burble -}
>
> would now not be confused by the quoted -}; the lexeme is
> a string not a '-}' thing.
I don't understand this remark. Are you telling me that after
a '{-' token the usual lexical process is used to find the
m
|> Starts a comment: `--', `---', `--Hello', `--(', `--;', `--_'
|>
|> Does not start a comment: `-->', `--=>', `--\', `--.', `--|', `--->',
|> `--? What is this', `--! Amazing', `--½ done', `--® Microsoft',
|> `--© 1998 Microsoft', `--«Nothing»'.
|
|Yes, these are correct.
So no one minds t
Just to confirm,
What is the official handling of:
> main = putStr " -- Hello World "
and
> main = putStr " {- this is not a comment -} "
-Alex-
On Mon, 23 Nov 1998, Simon Peyton-Jones wrote:
> > I REALLY dislike the idea of having my comments lexed. Can't we lea
> I REALLY dislike the idea of having my comments lexed. Can't we leave
> this part of the language spec alone?
OK, ok, ok. I am suitably berated and I yield.
* Comments *start* with a lexeme, as previously discussed, and I think
this is fine.
* The opening lexeme may be '--', '---' etc
> I don't understand this remark. Are you telling me that after
> a '{-' token the usual lexical process is used to find the
> matching '-}' token?
That's what I intended. Provided that scanning can't given an error,
that is actually *easier* than searching for the first '-}' sequence.
And it d
Folks, here's a clarification about comment syntax.
Simon
|The new draft (which you won't have seen) says:
|
|"An ordinary comment begins with a lexeme consisting of
|two or more consecutive dashes (e.g. @--@) and extends to the following
|newline. The comment must begin with a lexeme consistin
At 10:40 -0800 1998/11/13, Jeffrey R. Lewis wrote:
> Say you've got some code that wasn't originally
>monadic, and you now need to re-express your code in monadic form. You
>apply the monad translation. Using the `kleisli' functions makes this
>process simpler. Consider:
>
>map f (... xs ..
At 05:53 -0800 1998/11/13, Simon Peyton-Jones wrote:
>* Still no decision about the default default. I'm minded to
> try out the change myself and see how many times it's used
> in the nofib suite. I think the main choices are
> (Int, Double)
> (Integer, Double)
I s
Hans Aberg wrote:
> At 10:40 -0800 1998/11/13, Jeffrey R. Lewis wrote:
> > Say you've got some code that wasn't originally
> >monadic, and you now need to re-express your code in monadic form. You
> >apply the monad translation. Using the `kleisli' functions makes this
> >process simpler. Cons
Hans Aberg wrote:
>
> >** Postfix `M' always stands for a function in the Kleisli category:
> > m is added to function results (modulo currying) and nowhere else.
>
> I am not sure what you use this for: Given a monad M, the Kleisli
> category is equivalent to the full free monad algebra of t
We're nearly done with Haskell 98.
* In my last progress report I said:
However a couple of other similar proposals have been made
- add succ and pred to class Enum
- add atan2 to class RealFloat
I've had no complaints so I consider this done.
* Still no decision about the
Hi Simon, you spake of simple-context restriction:
> My default position is not to change. Question: who, apart from
> Ralf, has actually tripped over the lack of contexts of the
> form (C (a t1 .. tn)) in Haskell 1.4?
*raises hand and jumps up and down* Me, mememe! I provided you
with
On 05-Nov-1998, Lennart Augustsson <[EMAIL PROTECTED]> wrote:
>
> > If Integers can have "error", why shouldn't Monads have "mfail"?
> I'm objecting less to mfail then mzero.
OK, in that case I agree with you.
--
Fergus Henderson <[EMAIL PROTECTED]> | "I have always known that the pursuit
WW
On 05-Nov-1998, Lennart Augustsson <[EMAIL PROTECTED]> wrote:
>
> Simon wrote:
> > - The do-expression and MonadZero debate. You'll have seen a
> > lot about this, and I'll circulate a separate proposal.
> Sorry, I'm not happy with this proposal. Monads are a well
> defined mathematical conc
> Integers are a well defined mathematical concept and the
> Integer class should reflect this. Having a bottom value seems
> wierd to me.
Indeed, I'd be quite happy to exclude it if our type systems were
powerful enough to handle it. Integers with bottom should have type
'Lif
Lennart writes,
> - The default default.
Leave the default default alone. Since we didn't switch to
more generic versions of length et al (good move!) it doesn't
make much sense to do the default change.
I agree. (Even though I argued for the length change.) Switching Int
to Integer w
Lennart wrote:
>Sorry, I'm not happy with this proposal. Monads are a well
>defined mathematical concept and I think the Monad class should
>reflect this. Having a mzero (and mfail) method seems weird to
>me. I would suggest a MonadZero class having these methods,
>and that do notation on work
Simon wrote:
> - The do-expression and MonadZero debate. You'll have seen a
> lot about this, and I'll circulate a separate proposal.
Sorry, I'm not happy with this proposal. Monads are a well
defined mathematical concept and I think the Monad class should
reflect this. Having a mzero (an
- The simple-context restriction. My difficulty here is that there
is just no good place to stop. The 'type variable in head position'
option is attractive, but it's unimplemented, untested, and it's
neither the status quo nor a final destination. On the other hand,
we *believ
26 matches
Mail list logo