[nem-en] Re: match on specific parameter
Michal Moskal
michal.moskal at gmail.com
Sun Jan 29 19:36:06 CET 2006
On 1/29/06, Kamil Skalski <kamil.skalski at gmail.com> wrote:
> > > inside classes and variants to:
> > >
> > > foo () : ...
> > > match (this)
> > > | ...
> > >
> > > which I think also makes sense.
>
> Nice, but I think it is a little bit "unclean". That is, 'this' comes
> there from nowhere. Also, would you ommit this rule if there is some
> parameter?
Yes. I would apply it for functions with no parameters.
> > Maybe it should be also possible to say:
> >
> > foo (match this, some_flag : bool)
> > | ...
> >
>
> I guess
> foo (some_flag : bool)
> match (this)
> |
>
> is cleaner.
Well... you're right.
--
Michal Moskal,
http://nemerle.org/~malekith/
More information about the devel-en
mailing list