<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>jvoorhis comments on Aliasing Global Variables in Ruby</title>
    <link>http://www.jvoorhis.com/</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>jvoorhis comments</description>
    <item>
      <title>"Aliasing Global Variables in Ruby" by jvoorhis</title>
      <description>&lt;p&gt;And while I am becoming quite the language lawyer, I should mention that Ruby&amp;#8217;s &lt;code&gt;alias&lt;/code&gt; statement treats global variables quite differently from other kinds of variables.&lt;/p&gt;


	&lt;p&gt;When aliasing global symbols, the global variable itself is aliased and not evaluated. The result is a true alias, not a copy, so you cannot modify the global and its alias independently.&lt;/p&gt;


	&lt;p&gt;This feature most likely exists solely for &lt;code&gt;English.rb&lt;/code&gt; in the standard library. This being the case, see that file for examples.&lt;/p&gt;

</description>
      <pubDate>Fri,  6 Jul 2007 10:10:00 NZST</pubDate>
      <guid>&lt;a href="/articles/2007/07/06/aliasing-global-variables-in-ruby"&gt;Aliasing Global Variables in Ruby&lt;/a&gt;</guid>
      <link>&lt;a href="/articles/2007/07/06/aliasing-global-variables-in-ruby"&gt;Aliasing Global Variables in Ruby&lt;/a&gt;</link>
    </item>
  </channel>
</rss>
