Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [Dltk-dev] SourceType.equals() is broken

so the parents are not equaled correctly?
eventually only the 2 projects are compared and those return true?

return projectA != null && projectA.equals(spB.getProject());

johan


On Tue, Jul 8, 2008 at 1:18 PM, Michael Spector <spektom@xxxxxxxxx> wrote:
Hi,

Our unit test fails since two classes with same name, but declared in different files are equal.
For example, you have:

a.php:
class A  {}

b.php:
class A {}

DLTKCore.create(project.getFile("a.php")).getType("A").equals(DLTKCore.create(project.getFile("b.php")).getType("A")) == true !

May be this is due to optimization in ModelElement.compareParents() from 02/06/08 :)

Thanks!

--
Michael
_______________________________________________
dltk-dev mailing list
dltk-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/dltk-dev



Back to the top