Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 357977 - NoSuchFunctionError when generating a qualified function invocation
Summary: NoSuchFunctionError when generating a qualified function invocation
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EDT (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-16 14:32 EDT by Brian Svihovec CLA
Modified: 2017-02-23 14:18 EST (History)
1 user (show)

See Also:


Attachments
Testcase. (833 bytes, application/octet-stream)
2011-09-16 14:32 EDT, Brian Svihovec CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Brian Svihovec CLA 2011-09-16 14:32:08 EDT
Created attachment 203512 [details]
Testcase.

Import the attached RUIHandler.

When the file is generated you will get the following exception:
org.eclipse.edt.mof.codegen.api.TemplateException: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
	at org.eclipse.edt.mof.codegen.api.TemplateContext.doInvoke(TemplateContext.java:384)
	at org.eclipse.edt.mof.codegen.api.TemplateContext.invoke(TemplateContext.java:260)
	at org.eclipse.edt.gen.javascript.templates.StatementTemplate.genStatement(StatementTemplate.java:25)
	at org.eclipse.edt.gen.javascriptdev.templates.StatementTemplate.genStatement(StatementTemplate.java:26)
	at sun.reflect.GeneratedMethodAccessor351.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.edt.mof.codegen.api.TemplateContext.doInvoke(TemplateContext.java:357)

Caused by: java.lang.reflect.InvocationTargetException
	at sun.reflect.GeneratedMethodAccessor179.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at java.lang.reflect.Method.invoke(Unknown Source)
	at org.eclipse.edt.mof.impl.AbstractVisitor.invokeVisit(AbstractVisitor.java:125)
	... 81 more
Caused by: java.lang.RuntimeException: org.eclipse.edt.mof.egl.NoSuchFunctionError
	at org.eclipse.edt.mof.egl.impl.QualifiedFunctionInvocationImpl.getTarget(QualifiedFunctionInvocationImpl.java:53)
	at org.eclipse.edt.mof.egl.impl.QualifiedFunctionInvocationImpl.getTarget(QualifiedFunctionInvocationImpl.java:1)
	at org.eclipse.edt.gen.ReorganizeCode.processInvocationConstantParameters(ReorganizeCode.java:491)
	at org.eclipse.edt.gen.ReorganizeCode.processInvocation(ReorganizeCode.java:500)
	at org.eclipse.edt.gen.ReorganizeCode.visit(ReorganizeCode.java:475)
	... 85 more
Caused by: org.eclipse.edt.mof.egl.NoSuchFunctionError
	at org.eclipse.edt.mof.egl.impl.QualifiedFunctionInvocationImpl.resolveFunction(QualifiedFunctionInvocationImpl.java:123)
	at org.eclipse.edt.mof.egl.impl.QualifiedFunctionInvocationImpl.getTarget(QualifiedFunctionInvocationImpl.java:51)
	... 89 more
Comment 1 Brian Svihovec CLA 2011-09-16 15:08:06 EDT
This blocks the RUI Technical Sample.
Comment 2 Paul Harmon CLA 2011-09-19 08:08:58 EDT
I have updated TypeUtils to fix this. The code was only searching the source type (in this case EGLAny) for a conversion. I have updated it to search the target type (in this case Widget) for a conversion to the source type in it's supertype chain
Comment 3 Lisa Lasher CLA 2011-10-11 16:20:25 EDT
Closing this defect.