-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 (2011/11/13 5:43), Yehuda Katz wrote: > Unfortunately ruby-head has a deadlock in one of my go-to scenarios > for this feature. Just posting a seed for more discussion... This non-autoload version causes deadlock with trunk, 1.9.3 and 1.8.7. # foo.rb class Foo sleep 2 def self.shared_attributes %w(some list) end require 'bar' include Bar end # bar.rb sleep 1 module Bar require 'foo' attr_accessor *Foo.shared_attributes end # test.rb t1 = Thread.new { require "foo"; Foo } t2 = Thread.new { require "bar"; Bar } t1.join t2.join -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Cygwin) iQEcBAEBAgAGBQJOvxw6AAoJEC7N6P3yLbI2GMMH/1eb15orhb/9Ei1cc4uRBnru 7+QFI1KHcSg9HaHZPbXf61BVgjIpO2d0kmZS9UwMOX2eNtRxnSZbnlo+y3HfK8TZ aLzcFVS5NDtg+sehORv9ZvcR/sFo5hk+E6ukt186vrtjFFJj5q4pyIklhNOhFoXr Y4of3jdGv481/+ubyuFKd2UdHh1RcGWB24i/ZSsxJl6FVHyTDw6WieguuoneIAXY 56gt4iaAzZVhHSeoU4tN+973hPIZROh1gNtZ13aBth77b6ryHaPo6U03uMue0T8t //SMzugh9B/jQIWCmpzm7EdKah0EBLsqGfdQFEcF+JdHFICDqPh14R6uZfBHgB8= =a/yq -----END PGP SIGNATURE-----