Aquarium icon indicating copy to clipboard operation
Aquarium copied to clipboard

[#13395] Can't advice string or symbol objects.

Open hedgehog opened this issue 15 years ago • 3 comments

Date: 2007-08-26 19:49
Priority: 2 Submitted By: Dean Wampler (deanwampler)
Assigned To: Dean Wampler (deanwampler) Category: Pointcut Handling State: Open

Summary: Can't advice string or symbol objects.

Detailed description

If you specify a string or symbol object with :object[s] => .... specifiers, when you actually want to match on that object, they are misinterpreted as the names of types.

The fix is to better disambiguate the handling of :type[s] vs. :object[s].

hedgehog avatar Jan 28 '10 10:01 hedgehog

I need to move the list of issues from rubyforge to here. This is a known problem: http://rubyforge.org/tracker/index.php?func=detail&aid=13395&group_id=4281&atid=16494. Using :types would affect all strings. When using :objects, I have no way of knowing if you are referring to something else or the string/symbol itself. I should probably add a special case :string(s) option to work around. Other suggestions are welcome.

deanwampler avatar Jan 28 '10 14:01 deanwampler

OK, I think you misunderstood... I'm about to start porting those RF issues over to Github. I just wanted your input on whether you wanted more info. If the above looks good I'll use that format. One change is that I'll change '[#13395]' to '[Rubyforge-13395]'.

The remark on :types vs :objects was from the original rubyforge entry :)

hedgehog avatar Jan 28 '10 21:01 hedgehog

Yea, I wasn't clear; I got your point ;) Sorry. I'm fine with your recommendations for transferring the issues.

deanwampler avatar Jan 28 '10 21:01 deanwampler