Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » [SOLVED] Error: Multiple markers at this line -Duplicate ...
icon5.gif  [SOLVED] Error: Multiple markers at this line -Duplicate ... [message #1118448] Fri, 27 September 2013 08:22 Go to next message
Lefteris Skoutaris is currently offline Lefteris Skoutaris
Messages: 24
Registered: March 2013
Junior Member
Greetings to all!

I am having a problem when trying to parse a file instance having multiple string instances that are the same. I get the following error:

Multiple markers at this line
-Duplicate Spacecraft_Type 'NamingA'
-Duplicate Spacecraft_Type 'NamingB'
-Duplicate Spacecraft_Type 'NamingC'

The simple grammar I have written is the following:

Active_Spacecraft:
'Active Spacecraft'
(st2+=Spacecraft_Type)+
;

Inactive_Spacecraft:
'Inactive Spacecraft'
(st1+=Spacecraft_Type)+
;

Spacecraft_Type:
('ASc.Active Spacecraft_Type'
(ast=STRING','|ast=STRING)
'end')|('ISc.Active Spacecraft_Type'
(ist=STRING','|ist=STRING)
'end');

That is, each of the nodes Active_Spacecraft and Inactive_Spacecraft shall contain a set of nodes each called Spacecraft_Type and containing a list of string type values. I must note that in the file instance I am parsing there exist string values that are identical.

I have changed the feature name for each rule but with no success. Is this problem related to "unique name" value checking from xtext? If yes how can I disable this property?

Will be waiting for your kind reply!

[Updated on: Fri, 27 September 2013 10:27]

Report message to a moderator

Re: Error: Multiple markers at this line -Duplicate ... [message #1118452 is a reply to message #1118448] Fri, 27 September 2013 08:25 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian Dietrich
Messages: 6205
Registered: July 2009
Senior Member
You can remove nameareuniquevalidationfragment From the workflow

--
Need training, onsite consulting or any other kind of help for Xtext?
Go visit http://xtext.itemis.com or send a mail to xtext at itemis dot de
Re: Error: Multiple markers at this line -Duplicate ... [message #1118560 is a reply to message #1118452] Fri, 27 September 2013 10:31 Go to previous message
Lefteris Skoutaris is currently offline Lefteris Skoutaris
Messages: 24
Registered: March 2013
Junior Member
Hi Christian and thank you for your kind reply.

I have found the fragment you mention in the .mwe2 work flow and have commented it and that solved the duplication error problem.

// java-based API for validation
fragment = validation.JavaValidatorFragment {
//composedCheck = "org.eclipse.xtext.validation.ImportUriValidator"
//composedCheck ="org.eclipse.xtext.validation.NamesAreUniqueValidator"
}

Btw, I have noticed in other posts that you are really active in this forum and a real savior for others having various problems. I think we should be all grateful for having around people like you. RESPECT!
Previous Topic:Couldn't find the mandatory library 'org.eclipse.xtext.xbase.lib' 2.4.0 or higher on the project's c
Next Topic:Conflicting keywords and ID rules
Goto Forum:
  


Current Time: Thu Aug 21 12:22:55 EDT 2014

Powered by FUDForum. Page generated in 0.01886 seconds