[Ironruby-core] Code Review: FastFixes1

Peter Bacon Darwin bacondarwin at googlemail.com
Thu May 29 16:21:36 EDT 2008


This bit doesn't work:

+    [RubyModule(Extends = typeof(Kernel))]
+    public static class KernelOps {
+        [RubyMethod("BigDecimal", RubyMethodAttributes.PrivateInstance)]
+        [RubyMethod("BigDecimal", RubyMethodAttributes.PublicSingleton)]
+        public static object CreateBigDecimal(CodeContext/*!*/ context,
object self, [NotNull]MutableString/*!*/ value) {
+            return BigDecimalOps.Create(context, value);
+        }
+
+        [RubyMethod("BigDecimal", RubyMethodAttributes.PrivateInstance)]
+        [RubyMethod("BigDecimal", RubyMethodAttributes.PublicSingleton)]
+        public static object CreateBigDecimal(CodeContext/*!*/ context,
object self, object value) {
+            return BigDecimalOps.Create(context, value);
+        }
+    }
+}

The initializer code builds up the methods nicely but the "Kernel" module is
not in RubyExecutionContext._moduleCache, so the methods don't get added to
Kernel (but instead added to a Module called Ruby::Builtins::Kernel.

Any help here?
Cheers,
Pete


-----Original Message-----
From: ironruby-core-bounces at rubyforge.org
[mailto:ironruby-core-bounces at rubyforge.org] On Behalf Of John Lam
(IRONRUBY)
Sent: Wednesday,28 May 28, 2008 17:04
To: Curt Hagenlocher; IronRuby External Code Reviewers
Cc: ironruby-core at rubyforge.org
Subject: Re: [Ironruby-core] Code Review: FastFixes1

Missing a few method return bangs in BigDecimalOps.cs

I guess you're going to implement Kernel#BigDecimal eventually ...

Otherwise looks good!

Thanks,
-John


-----Original Message-----
From: Curt Hagenlocher
Sent: Wednesday, May 28, 2008 8:43 AM
To: IronRuby External Code Reviewers
Cc: ironruby-core at rubyforge.org
Subject: Code Review: FastFixes1

tfpt review "/shelveset:FastFixes1;REDMOND\curth"

Fixed critical error in Dir.glob
Added File.split
Added stub for BigDecimal class

--
Curt Hagenlocher
curth at microsoft.com
_______________________________________________
Ironruby-core mailing list
Ironruby-core at rubyforge.org
http://rubyforge.org/mailman/listinfo/ironruby-core



More information about the Ironruby-core mailing list