Issue 16161: OCL 2.3 7.5.3 Missing Association End name problems (ocl2-rtf) Source: Model Driven Solutions (Dr. Edward Willink, ed(at)willink.me.uk) Nature: Uncategorized Issue Severity: Summary: The 'clarified' text in OCL 2.3 for missing association ends, is still unclear. Problem 1: if multiple association ends acquire the same name, what happens? Suggest: they all acquire the same name and the resulting lookup up finds multiple names which should be diagnosed as an ambiguity and consequently a semantic error. Problem 2: if a missing association end is recursive, a class acquires a property with the same name as the class. Consequently invocation of e.g X.allInstances() for class X may encounter an ambiguity while resolving X. Is it self.X or global X? Suggest: auto-generated missing names may only be invoked via a navigation operator. Problem 3: does a derived association end get a resolution for a missing name? if OCL is used to define a number of helper properties that all return the same type, then provision of the missing 'opposites' results in unhelpful clutter at best. Suggest: missing names are not provided for derived association ends. Resolution: Revised Text: Actions taken: April 26, 2011: received issue Discussion: End of Annotations:===== ronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AvsEAD0xt01UXeb0/2dsb2JhbAClZ3fHZYV2BJJNihU Date: Tue, 26 Apr 2011 22:00:35 +0100 From: Ed Willink User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-GB; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 To: "ocl2-rtf@omg.org" Subject: OCL 2.3 7.5.3 Missing Association End name problems Hi The 'clarified' text in OCL 2.3 for missing association ends, is still unclear. Problem 1: if multiple association ends acquire the same name, what happens? Suggest: they all acquire the same name and the resulting lookup up finds multiple names which should be diagnosed as an ambiguity and consequently a semantic error. Problem 2: if a missing association end is recursive, a class acquires a property with the same name as the class. Consequently invocation of e.g X.allInstances() for class X may encounter an ambiguity while resolving X. Is it self.X or global X? Suggest: auto-generated missing names may only be invoked via a navigation operator. Problem 3: does a derived association end get a resolution for a missing name? if OCL is used to define a number of helper properties that all return the same type, then provision of the missing 'opposites' results in unhelpful clutter at best. Suggest: missing names are not provided for derived association ends. Regards Ed Willink