Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » How to solve IllegalArgumentException thrown by SwitchConstantExpressionsInterpreter
How to solve IllegalArgumentException thrown by SwitchConstantExpressionsInterpreter [message #1239522] Tue, 04 February 2014 11:11 Go to next message
Axel Guckelsberger is currently offline Axel GuckelsbergerFriend
Messages: 344
Registered: July 2009
Senior Member
After upgrading a project to 2.5.1 it does still compile fine within the IDE.
The Jenkins build gives the following exception:

20080 [main] ERROR text.validation.CompositeEValidator  - Error executing EValidator
java.lang.IllegalArgumentException: Unhandled parameter types: [null, null]
	at org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter.internalEvaluate(SwitchConstantExpressionsInterpreter.java:107)
	at org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter._internalEvaluate(SwitchConstantExpressionsInterpreter.java:71)
	at org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter.internalEvaluate(SwitchConstantExpressionsInterpreter.java:93)
	at org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter.evaluate(SwitchConstantExpressionsInterpreter.java:46)
	at org.eclipse.xtext.xbase.validation.XbaseJavaValidator.checkDuplicatedCases(XbaseJavaValidator.java:1343)
	at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.eclipse.xtext.validation.AbstractDeclarativeValidator$MethodWrapper.invoke(AbstractDeclarativeValidator.java:115)
	at org.eclipse.xtext.validation.AbstractDeclarativeValidator.internalValidate(AbstractDeclarativeValidator.java:292)
	at org.eclipse.xtext.validation.AbstractInjectableValidator.validate(AbstractInjectableValidator.java:66)
	at org.eclipse.xtext.validation.CompositeEValidator.validate(CompositeEValidator.java:127)
	at org.eclipse.emf.ecore.util.Diagnostician.doValidate(Diagnostician.java:171)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:158)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
	at org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
	at org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
	at org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
	at org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
	at org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
	at org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
	at org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
	at org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
	at org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
	at org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
	at org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
	at org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
	at org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
	at org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
	at org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
	at org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
	at org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
	at org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:120)
	at org.eclipse.xtext.validation.ResourceValidatorImpl.validate(ResourceValidatorImpl.java:141)
	at org.eclipse.xtext.validation.ResourceValidatorImpl.validate(ResourceValidatorImpl.java:119)
	at org.eclipse.xtext.validation.ResourceValidatorImpl.validate(ResourceValidatorImpl.java:99)
	at org.eclipse.xtend.core.validation.CachingResourceValidatorImpl.access$0(CachingResourceValidatorImpl.java:1)
	at org.eclipse.xtend.core.validation.CachingResourceValidatorImpl$1.get(CachingResourceValidatorImpl.java:28)
	at org.eclipse.xtend.core.validation.CachingResourceValidatorImpl$1.get(CachingResourceValidatorImpl.java:1)
	at org.eclipse.xtext.util.OnChangeEvictingCache.get(OnChangeEvictingCache.java:75)
	at org.eclipse.xtend.core.validation.CachingResourceValidatorImpl.validate(CachingResourceValidatorImpl.java:48)
	at org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler.validate(XtendBatchCompiler.java:490)
	at org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler.compile(XtendBatchCompiler.java:393)
	at org.eclipse.xtend.core.compiler.batch.Main.main(Main.java:55)


The project contains 96 switch statements. Any idea what to look for when reviewing the code?

TIA,
Axel
Re: How to solve IllegalArgumentException thrown by SwitchConstantExpressionsInterpreter [message #1239695 is a reply to message #1239522] Tue, 04 February 2014 20:32 Go to previous messageGo to next message
Sven Efftinge is currently offline Sven EfftingeFriend
Messages: 1823
Registered: July 2009
Senior Member
Could you please file a bugzilla for that?
I briefly looked at the code and couldn't see how this can happen.

Am 04/02/14 12:11, schrieb Axel Guckelsberger:
> After upgrading a project to 2.5.1 it does still compile fine within the
> IDE.
> The Jenkins build gives the following exception:
>
>
> 20080 [main] ERROR text.validation.CompositeEValidator - Error
> executing EValidator
> java.lang.IllegalArgumentException: Unhandled parameter types: [null, null]
> at
> org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter.internalEvaluate(SwitchConstantExpressionsInterpreter.java:107)
>
> at
> org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter._internalEvaluate(SwitchConstantExpressionsInterpreter.java:71)
>
> at
> org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter.internalEvaluate(SwitchConstantExpressionsInterpreter.java:93)
>
> at
> org.eclipse.xtext.xbase.interpreter.SwitchConstantExpressionsInterpreter.evaluate(SwitchConstantExpressionsInterpreter.java:46)
>
> at
> org.eclipse.xtext.xbase.validation.XbaseJavaValidator.checkDuplicatedCases(XbaseJavaValidator.java:1343)
>
> at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>
> at java.lang.reflect.Method.invoke(Method.java:597)
> at
> org.eclipse.xtext.validation.AbstractDeclarativeValidator$MethodWrapper.invoke(AbstractDeclarativeValidator.java:115)
>
> at
> org.eclipse.xtext.validation.AbstractDeclarativeValidator.internalValidate(AbstractDeclarativeValidator.java:292)
>
> at
> org.eclipse.xtext.validation.AbstractInjectableValidator.validate(AbstractInjectableValidator.java:66)
>
> at
> org.eclipse.xtext.validation.CompositeEValidator.validate(CompositeEValidator.java:127)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.doValidate(Diagnostician.java:171)
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:158)
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
>
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
>
> at
> org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
>
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
>
> at
> org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
>
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
>
> at
> org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.doValidateContents(Diagnostician.java:185)
>
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.doValidateContents(CancelableDiagnostician.java:48)
>
> at
> org.eclipse.xtext.xbase.validation.XbaseDiagnostician.doValidateContents(XbaseDiagnostician.java:46)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:161)
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:137)
> at
> org.eclipse.xtext.validation.CancelableDiagnostician.validate(CancelableDiagnostician.java:36)
>
> at
> org.eclipse.emf.ecore.util.Diagnostician.validate(Diagnostician.java:120)
> at
> org.eclipse.xtext.validation.ResourceValidatorImpl.validate(ResourceValidatorImpl.java:141)
>
> at
> org.eclipse.xtext.validation.ResourceValidatorImpl.validate(ResourceValidatorImpl.java:119)
>
> at
> org.eclipse.xtext.validation.ResourceValidatorImpl.validate(ResourceValidatorImpl.java:99)
>
> at
> org.eclipse.xtend.core.validation.CachingResourceValidatorImpl.access$0(CachingResourceValidatorImpl.java:1)
>
> at
> org.eclipse.xtend.core.validation.CachingResourceValidatorImpl$1.get(CachingResourceValidatorImpl.java:28)
>
> at
> org.eclipse.xtend.core.validation.CachingResourceValidatorImpl$1.get(CachingResourceValidatorImpl.java:1)
>
> at
> org.eclipse.xtext.util.OnChangeEvictingCache.get(OnChangeEvictingCache.java:75)
>
> at
> org.eclipse.xtend.core.validation.CachingResourceValidatorImpl.validate(CachingResourceValidatorImpl.java:48)
>
> at
> org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler.validate(XtendBatchCompiler.java:490)
>
> at
> org.eclipse.xtend.core.compiler.batch.XtendBatchCompiler.compile(XtendBatchCompiler.java:393)
>
> at org.eclipse.xtend.core.compiler.batch.Main.main(Main.java:55)
>
>
> The project contains 96 switch statements. Any idea what to look for
> when reviewing the code?
>
> TIA,
> Axel
>


--
Need professional support for Xtext or other Eclipse Modeling technologies?
Go to: http://xtext.itemis.com
Twitter : @svenefftinge
Blog : http://blog.efftinge.de
Re: How to solve IllegalArgumentException thrown by SwitchConstantExpressionsInterpreter [message #1239840 is a reply to message #1239695] Wed, 05 February 2014 07:07 Go to previous messageGo to next message
Axel Guckelsberger is currently offline Axel GuckelsbergerFriend
Messages: 344
Registered: July 2009
Senior Member
Done: https://bugs.eclipse.org/bugs/show_bug.cgi?id=427432
Re: How to solve IllegalArgumentException thrown by SwitchConstantExpressionsInterpreter [message #1240041 is a reply to message #1239840] Wed, 05 February 2014 15:27 Go to previous message
Axel Guckelsberger is currently offline Axel GuckelsbergerFriend
Messages: 344
Registered: July 2009
Senior Member
Solved by adding a dependency to org.objectweb.asm like recommended in the Bugzilla issue.
Previous Topic:Example of the power of Xtext and Xbase
Next Topic:maven build fails for to long names
Goto Forum:
  


Current Time: Fri Jul 10 20:36:05 GMT 2020

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

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

Back to the top