Brian Buckley on 22 Nov 2005 12:04:09 -0000

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PhillyOnRails] Random tip of the day

> In the second case, I think the commented out stuff needs to be valid
> enough for it to detect where the end statement is without running into
> errors.  Thus, you won't get dinged for calling nonexistent methods, but
> you can't give it totally broken code.  (I guess I should have used a
> better example, eh?  Sorry!)
> The first one should theoretically work in all cases (unless you are
> trying to commend out a line whose contents are "=end").  However, I
> must admit that since I posted about it, I've had trouble getting it to
> work consistently in ERb templates.  Sometimes it seems to work right
> and sometimes it barfs at me.  Not yet sure why. :(

I'd love for the =begin, =end trick to work so as not to have to worry
at all about the commented out sections but unfortunately it is mostly
barfing on me too.

Ability to nest comments (and the  =end issue) would be nicer still
but for now I'd settle to have just the basics.
talk mailing list