Bug 468303 - Unclear warning of incompatible transformation import
Summary: Unclear warning of incompatible transformation import
Status: NEW
Alias: None
Product: QVTo
Classification: Modeling
Component: Engine (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-26 08:37 EDT by Christopher Gerking CLA
Modified: 2015-05-28 08:38 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christopher Gerking CLA 2015-05-26 08:37:09 EDT
An imported transformation is diagnosed as a warning if its signature is incompatible to the importing transformation. If the import uses neither access nor extends, the warning is always displayed in line 1 due to the absence of proper start/end positions at CST level. This is very confusing in case of numerous imports. In addition, the warning message does not clearly state which import is affected.
Comment 1 Christopher Gerking CLA 2015-05-26 09:09:30 EDT
Patch pushed to master.

Commit ID: 6da9e48eeab70f43df75ac610028bc11bb02be24
Comment 2 Christopher Gerking CLA 2015-05-27 08:57:48 EDT
By now I wonder if the warning should rather be displayed for the line with the reusing module declartion (which is also the place that requires adjustment), instead of the line with the import statement.
Comment 3 Sergey Boyko CLA 2015-05-27 10:28:32 EDT
(In reply to Christopher Gerking from comment #2)
> By now I wonder if the warning should rather be displayed for the line with
> the reusing module declartion (which is also the place that requires
> adjustment), instead of the line with the import statement.

Possibly warning should be displayed for both places (reusing decl and import statement)?
Comment 4 Christopher Gerking CLA 2015-05-27 10:33:54 EDT
(In reply to Sergey Boyko from comment #3) 
> Possibly warning should be displayed for both places (reusing decl and
> import statement)?

Especially in case of multiple modules per unit, nothing is actually wrong with the import as such. The imported module may just reused incorrectly by specific modules, that's why I prefer a warning for the reusing declaration only.
Comment 5 Sergey Boyko CLA 2015-05-27 11:04:16 EDT
(In reply to Christopher Gerking from comment #4)
> (In reply to Sergey Boyko from comment #3) 
> > Possibly warning should be displayed for both places (reusing decl and
> > import statement)?
> 
> Especially in case of multiple modules per unit, nothing is actually wrong
> with the import as such. The imported module may just reused incorrectly by
> specific modules, that's why I prefer a warning for the reusing declaration
> only.

I see. Then I'm ok with displaying the warning message only for reusing declaration statement.
Comment 6 Christopher Gerking CLA 2015-05-28 07:53:58 EDT
On the other hand, when there is no explicit access/extends, such a warning would very often be caused by the legacy implicit import by extends. I wonder how helpful a warning for the reusing declaration is in such a case, because there is no visible link to the import. Users might not even understand why there is an incompatibility. It could be helpful to explain at least that the problem is caused by the (implicit) 'extends', but in general I'm still incertain about where to display the warning at all.
Comment 7 Ed Willink CLA 2015-05-28 08:38:23 EDT
(In reply to Christopher Gerking from comment #6)
> On the other hand

Definitely not something to experiment with at RC3.