From: Eric Mahurin Date: 2005-10-19T23:23:08+09:00 Subject: Re: [ANN] [RCR] Cut-based AOP What's the reason for naming the cut? In all of the code I've seen so far, the actual cut is never used. So instead of: cut C < A ... end why not: cut < A ... end or: cut A ... end The only thing I can think of off hand is that you might want to remove the cut down the road. Conceptually, I think it is easier to think of this cut operating on the parent class (make it look like you're just reopening the class). You could think of this "cut" as something just like "class" except that the superclass is treated as the previous definition of "class". This also would extend well to making a cut on the meta class of an object: cut < "foo" class C foo1 = instance_method(:foo) define_method(:foo) { "{"+foo1.bind(self).call+"}" } end c.foo # => "{foo}" class C foo1 = instance_method(:foo) define_method(:foo) { "["+foo1.bind(self).call+"]" } end c.foo # => "[{foo}]" Pretty sweet, huh? I wasn't sure if foo1 kept the previous definition until I tried it, but apparently it does. Maybe just an easier way to do the above is all that is needed. I think the above covers what is really needed for AOP - and we already have it. Just simpler syntax is needed IMO. No extra baggage needs to be added to the class data structures. I'm not sure why you guys made such a lengthy RCR. I think I have the concept now, but with all of the verbosity, it makes it difficult to figure out what you are really proposing. I think a much more concise RCR would have been better. __________________________________ Yahoo! Music Unlimited Access over 1 million songs. Try it free. http://music.yahoo.com/unlimited/