This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_ extPart_001_01C26960.AB71E420
Content-Type: text/plain; charset="iso-8859-1"
Silly me! I think I was trying it with local variables. Read Mark!
> -----Original Message-----
> From: ts [mailto:decoux / moulon.inra.fr]
> Sent: Tuesday, October 01, 2002 10:33 AM
> To: ruby-talk / ruby-lang.org
> Cc: ruby-talk / ruby-lang.org
> Subject: Re: puts "#{expression}" braces always needed?
>
>
> >>>>> "V" Volkmann, Mark <Mark.Volkmann / AGEDWARDS.com> writes:
>
> V> The pickaxe book says (on page 51) that if the expression
> is a global, class
> V> or instance variable then the braces aren't required.
> Omitting them doesn't
> V> seem to work for me. Is the book wrong?
>
> it seems to work for me
>
> pigeon% ruby -e '$a @a a 2; p "#$a #@@a #@a"'
> "12 12 12"
> pigeon%
>
>
> Can you give an example ?
***********************************************************************************
WARNING: All e-mail sent to and from this address will be received or
otherwise recorded by the A.G. Edwards corporate e-mail system and is
subject to archival, monitoring or review by, and/or disclosure to,
someone other than the recipient.
************************************************************************************
------_ extPart_001_01C26960.AB71E420
Content-Type: text/html; charset="iso-8859-1"
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV
ontent-Type" CONTENT ext/html; charset o-8859-1">
<META NAME enerator" CONTENT S Exchange Server version 5.5.2653.12">
<TITLE>RE: puts "#{expression}" braces always needed?</TITLE>
</HEAD>
<BODY>
<P><FONT SIZE Silly me! I think I was trying it with local variables. Read Mark!</FONT>
</P>
<P><FONT SIZE > -----Original Message-----</FONT>
<BR><FONT SIZE > From: ts [<A HREF ailto:decoux / moulon.inra.fr">mailto:decoux / moulon.inra.fr</A>]</FONT>
<BR><FONT SIZE > Sent: Tuesday, October 01, 2002 10:33 AM</FONT>
<BR><FONT SIZE > To: ruby-talk / ruby-lang.org</FONT>
<BR><FONT SIZE > Cc: ruby-talk / ruby-lang.org</FONT>
<BR><FONT SIZE > Subject: Re: puts "#{expression}" braces always needed?</FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > >>>>> "V" Volkmann, Mark <Mark.Volkmann / AGEDWARDS.com> writes:</FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > V> The pickaxe book says (on page 51) that if the expression </FONT>
<BR><FONT SIZE > is a global, class</FONT>
<BR><FONT SIZE > V> or instance variable then the braces aren't required. </FONT>
<BR><FONT SIZE > Omitting them doesn't</FONT>
<BR><FONT SIZE > V> seem to work for me. Is the book wrong?</FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > it seems to work for me</FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > pigeon% ruby -e '$a @a a 2; p "#$a #@@a #@a"'</FONT>
<BR><FONT SIZE > "12 12 12"</FONT>
<BR><FONT SIZE > pigeon% </FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > </FONT>
<BR><FONT SIZE > Can you give an example ?</FONT>
</P>
<CODE><FONT SIZE0<BR>
<BR>
***********************************************************************************<BR>
WARNING: All e-mail sent to and from this address will be received or<BR>
otherwise recorded by the A.G. Edwards corporate e-mail system and is<BR>
subject to archival, monitoring or review by, and/or disclosure to,<BR>
someone other than the recipient.<BR>
************************************************************************************<BR>
</FONT></CODE></BODY>
</HTML>
------_ extPart_001_01C26960.AB71E420--