Forum: Ruby on Rails How to define a multi line comment

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
C2d5a90c724ca4a7730f6f422c81e525?d=identicon&s=25 Kushan Jayathilake (Guest)
on 2007-02-14 12:31
(Received via mailing list)
Hi All

Is there who knows to define multi line comment? ( in Java we can define
by
/* and */ )

Best Regards

Kushan Jayathilake
D7c511ce5025d37b8c6bd9134e0f2bd9?d=identicon&s=25 Thorsten L (Guest)
on 2007-02-14 12:58
(Received via mailing list)
you mean in Ruby? like this

=begin
blablabla
bablablabl
abklabla
=end

On 14 Feb., 11:57, "Kushan Jayathilake" <kushan.ra...@gmail.com>
C2d5a90c724ca4a7730f6f422c81e525?d=identicon&s=25 Kushan Jayathilake (Guest)
on 2007-02-15 04:37
(Received via mailing list)
Hello Thorsten L


Yes,I want to know how to define a multiline comment in rails,
In Java we can define it like this
/*
Comment line 1
Comment line 2
Comment line 3
*/
 Anything between /* and */ will be commented

So is there anyway that I can do this in rails
34a7615f38496a5dafbb3e6b721c435e?d=identicon&s=25 Mohit Sindhwani (Guest)
on 2007-02-15 04:50
(Received via mailing list)
Hi Kushan

Thorsten did answer your question.  I've changed it to look similar to
your request.

=begin
Comment line 1
Comment line 2
Comment line 3
=end

Hmm, I wonder if Thorsten's reply looked too much like English and got
ignored? :)

Cheers
Mohit.
1f2eadfb41362800ebc2cf211b91d0f7?d=identicon&s=25 javier ramirez (Guest)
on 2007-02-26 10:13
(Received via mailing list)
> =begin
> blablabla
> bablablabl
> abklabla
> =end
>
just keep in mind that kind of comments are reserved for ruby doc, so
best practices would tell not to use them unless for that purpose..
which leaves us without a general purpose multi line comment in ruby
(AFAIK)

regards,

javier ramirez

--
--------
Estamos de estreno... si necesitas llevar el control de tus gastos
visita http://www.gastosgem.com !!Es gratis!!
This topic is locked and can not be replied to.