Community
Participate
Working Groups
(originally from http://trac.objectteams.org/ot/ticket/207) (From Jira:TPX-95) an anonymous type which is instantiated within the scope of a teamlevel-attribute assignment can only be found if the anonymous class declares an innerclass (see org.objectteams.otdt.test.otmodel.anonymousinnerclass.teamlevel.Test5) in all other cases it can not be found (see org.objectteams.otdt.test.otmodel.anonymousinnerclass.teamlevel.Test1, Test3 and Test7) if the anonymous type is instantiated in the scope of a method it can always be found (see org.objectteams.otdt.test.otmodel.anonymousinnerclass.teamlevel.Test2, Test 4, Test6 and Test8) Seems that the SourceElementParser doesn't parse anonymous types correctly. In method notifySourceElementRequestor(TypeDeclaration, boolean) the given TypeDeclaration does not contain the anonymous class in the mentioned cases. Note, that tests in org.objectteams.otdt.test.otmodel.anonymousinnerclass are currently disabled. (comment:1) Rechecking in 1.3.1 seems to indicate that * anonymous classes within roles/teams are not generally a problem * anonymous classes in role field initializers are generally not available in the otmodel * anonymous classes can not have team or role properties. 17 tests out of 60 currently pass. Might want to add jacks tests for anonymous roles etc (and check whether the OTJLD requires an update in this regard).