[macruby-changes] [3160] MacRuby/trunk/test_vm/cvar.rb

source_changes at macosforge.org source_changes at macosforge.org
Tue Dec 22 21:00:58 PST 2009


Revision: 3160
          http://trac.macosforge.org/projects/ruby/changeset/3160
Author:   lsansonetti at apple.com
Date:     2009-12-22 21:00:54 -0800 (Tue, 22 Dec 2009)
Log Message:
-----------
adding one more evil cvar test

Modified Paths:
--------------
    MacRuby/trunk/test_vm/cvar.rb

Modified: MacRuby/trunk/test_vm/cvar.rb
===================================================================
--- MacRuby/trunk/test_vm/cvar.rb	2009-12-23 04:00:41 UTC (rev 3159)
+++ MacRuby/trunk/test_vm/cvar.rb	2009-12-23 05:00:54 UTC (rev 3160)
@@ -1,2 +1,13 @@
 assert ":ok", "begin; p @@foo; rescue NameError; p :ok; end"
 assert "42",  "@@foo = 42; p @@foo"
+
+assert "42", %{
+  class X
+    @@foo = 41
+    def foo; @@foo; end
+  end
+  class Y < X
+    @@foo += 1
+  end
+  p X.new.foo
+}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20091222/3fdf9e09/attachment.html>


More information about the macruby-changes mailing list