]> git.cworth.org Git - sup/blobdiff - lib/sup/util.rb
fixed bug in label assignment for new messages and cleaned up logging messages
[sup] / lib / sup / util.rb
index 77209bf8033f5b5c0e445f442b12e62f18c35a39..35c087a7e5256ff318d34b7b642cbad3638f3bc9 100644 (file)
@@ -7,6 +7,10 @@ class Module
     bool_reader(*args)
     bool_writer(*args)
   end
+
+  def attr_reader_cloned *args
+    args.each { |sym| class_eval %{ def #{sym}; @#{sym}.clone; end } }
+  end
 end
 
 class Object