Closed eclipse-ocl-bot closed 1 month ago
By Ed Willink on Jun 23, 2013 16:24
On RC4 I see
Evaluating:\ self.ownedElements->select(e | e.stereotypes->exists(s | s.name = "singleton"))->collect(e | e.name)\ Results:\ Parsing failure
1: no viable alternative at input '"singleton"'\ 1: missing EOF at ')'\ 1: Unresolved Property '::e'
which is not that bad, and requires some determination to try executing what has red squiggles under the = preceding, and the ) following the "singleton".
The classic OCL non-standard functionality of "" was to escape awkward character sequences for names, rather than the QVTo Java-like usage as strings.
Introducing "" as a synoym for '' with a warning gives better diagnosis, buit I'm not sure that it's that necessary.
By Ed Willink on May 27, 2014 09:44
CLOSED after more than a year in RESOLVED state.
By Ed Willink on May 27, 2014 09:52
and CLOSE
| --- | --- | | Bugzilla Link | 411246 | | Status | CLOSED INVALID | | Importance | P3 enhancement | | Reported | Jun 20, 2013 09:08 EDT | | Modified | May 27, 2014 09:52 EDT | | Reporter | Filip Krikava |
Description
In Xtext OCL console following query results in difficult to understand message:
self.ownedElements->select(e | e.stereotypes->exists(s | s.name = "singleton"))->collect(e | e.name)
Evaluating:\ self.ownedElements->select(e | e.stereotypes->exists(s | s.name = "singleton"))->collect(e | e.name)\ Results:\ Parsing failure\ null\ 1: missing EOF at '('\ 1: Unresolved Property 'unknown-type::select'
In the old OCL console a correct problem identification is given:
Evaluating:\ self.ownedElements->select(e | e.stereotypes->exists(s | s.name = "singleton"))->collect(e | e.name)\ Results:\ Usage of non-standard quoted element name: "singleton"
Ref: http://www.eclipse.org/forums/index.php/m/1064110/#msg_1064110