<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -16,14 +16,14 @@ module Immutable
         alias_method &quot;#{UNIQ}_old_#{method}&quot;, method
       end
       
-      @allow_method_override = false
+      instance_variable_set(&quot;@#{UNIQ}_in_method_added&quot;, false)
 
       @args = args; @opts = opts
       module_eval do
         def self.method_added(sym)
           if @args
             @args.each do |method|
-              if method &amp;&amp; sym == method.to_sym &amp;&amp; !@allow_method_override
+              if method &amp;&amp; sym == method.to_sym &amp;&amp; !in_method_added?
                 unless @opts[:silent]
                   raise CannotOverrideMethod, &quot;Cannot override the immutable method: #{sym}&quot;
                 end
@@ -50,10 +50,14 @@ module Immutable
       end # module_eval
 
       def self.allow_method_override
-        @allow_method_override = true
+        instance_variable_set(&quot;@#{UNIQ}_in_method_added&quot;, true)
         yield
       ensure
-        @allow_method_override = false
+        instance_variable_set(&quot;@#{UNIQ}_in_method_added&quot;, false)
+      end
+
+      def self.in_method_added?
+        instance_variable_get(&quot;@#{UNIQ}_in_method_added&quot;)
       end
     end # def immutable_method()
 </diff>
      <filename>lib/immutable.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>8768bbdc1fb84e0bd2a56aec30f77ad2a9afdc48</id>
    </parent>
  </parents>
  <author>
    <name>Garry Dolley</name>
    <email>gdolley@arpnetworks.com</email>
  </author>
  <url>http://github.com/up_the_irons/immutable/commit/08e3a5540694ce151f8b3962ea784f1b1cc72f60</url>
  <id>08e3a5540694ce151f8b3962ea784f1b1cc72f60</id>
  <committed-date>2008-09-27T14:13:07-07:00</committed-date>
  <authored-date>2008-09-27T14:13:07-07:00</authored-date>
  <message>Made instance var that holds state of whether we are already in our own
method_added() unique.</message>
  <tree>53126e54ff6f819e6e88f83e9091d25672a5dfb6</tree>
  <committer>
    <name>Garry Dolley</name>
    <email>gdolley@arpnetworks.com</email>
  </committer>
</commit>
