Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Inconsistent stackmap frames error leading to broken code generation
Inconsistent stackmap frames error leading to broken code generation [message #893017] Mon, 02 July 2012 10:18 Go to next message
Marcus Mathioudakis is currently offline Marcus MathioudakisFriend
Messages: 18
Registered: June 2012
Junior Member
I encountered what appeared to be an instance of Bug 380313 which is marked as fixed. My grammar is the following:

grammar org.xtext.example.hyrule.HyRule with org.eclipse.xtext.common.Terminals
//  with org.eclipse.xtext.xbase.Xbase  

generate hyRule "..."//You cannot use links until you have posted more than 25 messages

Start:
	rules+=Rule*;
	
Rule:
	'FOR' 'PAYLOAD' PAYLOAD 'ELEMENTS' elements+=ID+ 'CONSTRAINED''BY'name=ID '!';

PAYLOAD:
	"sse"| "stacons"
;



Which works fine, and with which code generation editor etc. all work. However as soon as I change
with org.eclipse.xtext.common.Terminals

to
with org.eclipse.xtext.xbase.Xbase


And fire up the generated IDE I get the Inconsistent stackmap frames at branch target error exactly as detaied in Bug 380313, as a result of which code generation and auto completion no longer work.

If I change the complier compliance level to 1.6, the afformentioned error goes away, and auto completion works, but the code generation still doens't work (no code is generated in src-gen).


I am using Xtext 2.3 installed from scratch, and java 7.
The build path for the xtext project is unmodified, and I've added the org.eclipse.xtext.xbase.lib_2.3.0.v201206120633.jar to the build path of the DSL project
(i.e. the one in the eclipse instance launched at runtime).

Any help would be much appreciated, I have been racking my brains trying to find the problem.

UPDATE: In the example above I was using the generator.xtend to generate code. If instead I use the JvmModelInferrer, then with compliance set to 1.7 I still get the error mentioned above, and autocompletion is completely broken, but code generation actually works. And of course in this case too, setting compliance level to 1.6 everything works fine. But surely I should be able to use the generator instead of the JvmModelInferrer, and not have to set the compiler compliance level t 1.6?

[Updated on: Mon, 02 July 2012 13:47]

Report message to a moderator

Re: Inconsistent stackmap frames error leading to broken code generation [message #893126 is a reply to message #893017] Mon, 02 July 2012 18:17 Go to previous messageGo to next message
Stephan Herrmann is currently offline Stephan HerrmannFriend
Messages: 1765
Registered: July 2009
Senior Member
Bug 380313 is only one instance in a group of related issues.
If indeed you continue to see verification errors due to inconsistent stackmap frames even when using JDT 3.8 please try to isolate the Java code that causes this and report a bug against JDT/Core.

thanks,
Stephan
Re: Inconsistent stackmap frames error leading to broken code generation [message #893301 is a reply to message #893126] Tue, 03 July 2012 13:43 Go to previous message
Marcus Mathioudakis is currently offline Marcus MathioudakisFriend
Messages: 18
Registered: June 2012
Junior Member
I was using eclipse 3.7.2, updated to Juno release and issue is resolved.
Previous Topic:XText Web proposals engine
Next Topic:EMF repository for Eclipse 3.5 and 3.6
Goto Forum:
  


Current Time: Tue Feb 25 16:52:53 GMT 2020

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

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

Back to the top