Summary: | ProceedingJoinPoint changes order of input parameters | ||
---|---|---|---|
Product: | [Tools] AspectJ | Reporter: | Sergey Kadaner <sergey.kadaner> |
Component: | Compiler | Assignee: | aspectj inbox <aspectj-inbox> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | major | ||
Priority: | P3 | CC: | aclement |
Version: | 1.8.9 | ||
Target Milestone: | 1.8.10 | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
Whiteboard: |
Description
Sergey Kadaner
2016-08-21 04:10:10 EDT
It isn't so much that it changes the order. It is that although you didn't bind 'this' because 'this' is different to 'target' at a call joinpoint it expects you to pass this as well, in position 0 of the array. The code will work if you do that. However, it should be required, this is a bug but it does seem to be a very long standing one, I'm surprised people are not tripping over it more regularly but perhaps binding only target on join points with differing this and target is unusual (I mean if doing that you would be better using execution() and binding 'this' to advise fewer places). So I need to make a change to the AspectJ runtime, which I don't do lightly but think I must for this problem. Also fixing this breaks the fix for bug 288712, so I've re-fixed that in a better way. Thanks for the code snippet, always helpful. I've created many variants around this scheme (binding this/target, passing them through, changing them, etc) and they all pass with the proposed changes. |