eclipse-ocl / org.eclipse.ocl

Eclipse Public License 2.0
0 stars 0 forks source link

[pivot-uml] Inadequate diagnosis and usage of bad profiles #1828

Closed eclipse-ocl-bot closed 2 hours ago

eclipse-ocl-bot commented 2 hours ago

| --- | --- | | Bugzilla Link | 515027 | | Status | RESOLVED FIXED | | Importance | P3 normal | | Reported | Apr 10, 2017 09:06 EDT | | Modified | May 17, 2017 14:11 EDT | | Depends on | 515050, 515038 | | Reporter | Ed Willink |

Description

https://www.eclipse.org/forums/index.php?t=msg&th=1085495&goto=1759300&#msg_1759300

from OCL Forum : Possible problems with implicit properties of Stereotypes

provides a repro in which use of both Class and Interface stereotypes gives confusing results. Looks as if one erroneously inherits from the other.

eclipse-ocl-bot commented 2 hours ago

By Ed Willink on Apr 10, 2017 10:00

The repro is not well-formed; two [1..1] stereotypes with only one defined.

Correcting this momentarily made things better, but then something magically indeterminate; maybe two copies of the profile somehow conflict.

eclipse-ocl-bot commented 2 hours ago

By Ed Willink on Apr 10, 2017 10:00

Maybe the blank URIs make things worse.

eclipse-ocl-bot commented 2 hours ago

By Ed Willink on Apr 10, 2017 10:31

(In reply to Ed Willink from comment #1)

Correcting this ... but then something magically indeterminate

It help to correct both the defined stereotype used by the UML Ecore technology validation as well as the UML stereotype used by the Pivot validation.

The ambiguous property is correct. There are two possible declared stereotypes only one of which is dynamically in use. But using the disambiguation syntax fails.

The navigation through the unused prototype should give null but doesn't.

(In reply to Ed Willink from comment #2)

Maybe the blank URIs make things worse.

This asserts that Profile and Package are to be merged, then who only knows what chaos ensues?


With valid models, behaviour seems good.

But no doubt there are additional checks that we should add to help the idiot user realize their idiocy.

eclipse-ocl-bot commented 2 hours ago

By Ed Willink on Apr 10, 2017 11:02

The reported ambiguity is ignored in more complex scenarios. See Bug 515038.

eclipse-ocl-bot commented 2 hours ago

By Ed Willink on Apr 10, 2017 13:13

There should not be an ambiguity. Bug 515050.

eclipse-ocl-bot commented 2 hours ago

By Ed Willink on May 17, 2017 14:11

This specific bug is fixed via Bug 515038 and Bug 515050.