Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [aspectj-dev] reflective calls

Alexandre Vasseur wrote:
> I have been asked what is the "AspectJ answer" to "how to match
> reflective calls" such as with: 

Hi, Alex. The issue you are raising is actually not an AspectJ specific
problem. It's indeed a problem for any program which employs interprodedural
analysis as well. Up till now I have seen no decent solution to this
problem, which does not surprise me because I think there actually cannot be
one. The one possible method you mentioned (runtime matching) is actually
the only possible way IMHO since obviously *any possible String* could be
passed in to Method.invoke(...). What this String looks like cannot
generally be determined statically. Thus runtime evaluation/matching is
unavoidable for a general solution.

Hope that helps,
Eric

-- 
Eric Bodden
Chair I2 for Programming Languages and Program Analysis
RWTH Aachen University




Back to the top