Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Re: pre/post question/idea
David Naseby
11/28/2003 2:54:00 AM
>-----Original Message-----
>From: David A. Black [mailto:dblack@wobblini.net]
> class C
> def x
> puts "how are you?"
> end
>
> pre x
> puts "hello"
> end
>
> post x
> puts "goodbye"
> end
> end
>
I agree that it looks better, but my eyes completely skipped over the
replacement def's. I thought you were just def-ing the same thing 3 times,
and were depending on order to distinguish them, which is obviously a silly
idea.
Nothing against this idea, just noting how my brain reads Ruby code right
now. The x:*** syntax screams special case to me, and this doesn't.
David
http://homepages.ihug.com.a...
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Re: pre/post question/idea
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password