|
Re: DSL syntax changed - how to provide conversion-on-load? [message #890689 is a reply to message #890507] |
Fri, 22 June 2012 21:01 |
Jan Koehnlein Messages: 760 Registered: July 2009 Location: Hamburg |
Senior Member |
|
|
Funny question, because usually it's the other way around: The syntax
stays the same (its api to the end user) but the model changes.
No, we don't have OOTB support for this. You'd have to build it
yourself. Note that it will be very inefficient deciding on each parse
fail whether that was a previous version or just an erroneous file. I'd
rather have some heuristical approach to detect (find certain patterns)
old projects at startup and then ask the user to convert all models at
once. You could also use project properties/settings to store language
version information.
Am 22.06.12 15:04, schrieb Klaus Birken:
> Hi all,
>
> let's assume an Xtext-based DSL has been rolled out to the users. Now,
> due to some unexpected reasons the DSL's syntax has to be changed in an
> incompatible way - but without changing the underlying EMF model.
> Is there a mechanism to provide a syntax conversion "behind the scenes"?
> I.e., if the latest parser cannot read the file an older parser for the
> previous syntax version will be used. If this is successful, both
> serializer and formatter are used to provide the user with the updated
> version. And, this should work transparently for IDE and standalone
> environments.
>
> Thanks in advance, regards,
> Klaus
>
--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com
---
Get professional support from the Xtext committers at www.typefox.io
|
|
|
Powered by
FUDForum. Page generated in 0.02099 seconds