[Soot-list] loading class files with Soot in abc

Oege de Moor Oege.de.Moor at comlab.ox.ac.uk
Sun Feb 5 16:35:08 EST 2006


Thanks again, Pat, but I don't want a file to appear if it's just
in the dir as *.java. So I've done as Ondrej suggested, and written
a specialised version for abc, which fixes my problem.



On Sun, 5 Feb 2006, Patrick LAM wrote:

> The attached patch may be useful.  Ondrej: it doesn't appear to be correct
> to add 'X' twice to the return value of SourceLocator.getClassesUnder, but
> I'm not quite sure about what that method should really do.  We can start
> by checking to see if it fixes Oege's problem, though.
>
> pat
>
> On Sun, 5 Feb 2006, Oege de Moor wrote:
>
>>
>> thanks, pat!
>>
>> Unfortunately that doesn't help;
>>
>> SourceLocator.getClassesUnder(String apath)
>>
>> still returns a list with multiple copies of the same name X when
>> there are X.java and X.class in the same directory. Looking at
>> the code, it seems that this method isn't influenced by the
>> kind of src_prec option we've set.
>>
>> On Sun, 5 Feb 2006, Patrick LAM wrote:
>>
>>> On Sun, 5 Feb 2006, Oege de Moor wrote:
>>>
>>>> I'm not sure I understand what I should do in abc to take advantage
>>>> of your change... can you elaborate a little?
>>>
>>> Ok, so I committed the only-class option in Soot revision 2285.  In abc,
>>> you need to invoke:
>>>
>>> 	soot.Options.v().set_src_prec(soot.Options.src_prec_only_class);
>>>
>>> before calling Soot.  Let me know if that's what you need.
>>>
>>> pat
>>>
>>>
>>>
>>
>>
>


More information about the Soot-list mailing list