Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » inconsistency of case sensitivity in xtext suffix(xtext is only sometimes sensitive to case of suffix)
inconsistency of case sensitivity in xtext suffix [message #1787405] Thu, 24 May 2018 20:47 Go to next message
Jay Norwood is currently offline Jay NorwoodFriend
Messages: 155
Registered: July 2009
Senior Member
I pulled down the tracing_codegen example from github and substituted 2.14 xtext on the oxygen DSL eclipse, on Windows 10.

Things were looking good.

I created a file with .MyDsl suffix and eclipse recognized it and converted my project to an xtext project.

I edited the model, using the example dsl code from github, and the editor accepted all that, and the outline view updated.

However, the .c and .h suffix files weren't generated, and no clue given why.

After debugging, I found that the code that does the generation was more picky about the suffix, and was accepting only "mydsl", all lower case, which is in fact the suffix in the genmodel file.

So, I don't know, but seems like it should consistently accept or reject if the case doesn't match.

I believe it came down to registry.getExtensionToFactoryMap.containsKey(name.substring(index+1)), which apparently doesn't ignore case (in the UriValidator isPossiblyManaged()

Re: inconsistency of case sensitivity in xtext suffix [message #1787406 is a reply to message #1787405] Thu, 24 May 2018 20:49 Go to previous messageGo to next message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 12237
Registered: July 2009
Senior Member
first thought:

mydsl != MyDsl

yes the editor works regardless the case but builders wont,
thats a well known ugly behaviour


Need professional support for Xtext, Xpand, EMF?
Go to: https://xtext.itemis.com
Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Re: inconsistency of case sensitivity in xtext suffix [message #1787407 is a reply to message #1787406] Thu, 24 May 2018 21:00 Go to previous message
Christian Dietrich is currently offline Christian DietrichFriend
Messages: 12237
Registered: July 2009
Senior Member
btw e.g. java/jdt behave the same

Need professional support for Xtext, Xpand, EMF?
Go to: https://xtext.itemis.com
Twitter : @chrdietrich
Blog : https://www.dietrich-it.de
Previous Topic:Associating data with EMF model
Next Topic:interface default method: how to implement
Goto Forum:
  


Current Time: Sun Sep 23 18:00:12 GMT 2018

Powered by FUDForum. Page generated in 0.02093 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top