Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 356819 - NPE when generate Java for program or library with const string variable
Summary: NPE when generate Java for program or library with const string variable
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EDT (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 blocker (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-06 10:16 EDT by Kathy Carroll CLA
Modified: 2017-02-23 14:18 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kathy Carroll CLA 2011-09-06 10:16:32 EDT
Using install build     EGL Development Tools (EDT)	0.7.0.v201109060901

Create a EGL project that only uses the java compiler
create a new program named driver
Results in these errors:

IWN.JavaGen.9998.e 11/203 Exception occurred: java.lang.NullPointerException	
IWN.JavaGen.9999.e 11/203 Stack Trace: java.lang.NullPointerException	
Syntax error, insert ";" to complete FieldDeclaration	
Syntax error, insert "}" to complete ClassBody	 
The type driver must implement the inherited abstract method Program.main()
Comment 1 Kathy Carroll CLA 2011-09-06 10:21:25 EDT
Additional problem with this. Fix this one first.

1. Create the egl java-compiler project
2. create new library which as errors due to the const variable
3. create a new program which will also have errors due to the const variable
4. delete the egl source of the library
5. Problem the problem list still shows issues with the library source file
6. Clean of the project doesn't clear 'em out either
Comment 2 Matt Heitz CLA 2011-09-06 10:45:45 EDT
Kathy, please open a separate bug against IDE UI for the additional problem.  JavaGen doesn't find or display the Java compile errors.
Comment 3 Kathy Carroll CLA 2011-09-06 11:07:05 EDT
Created separate Bug 356825
Comment 4 Jeff Douglas CLA 2011-09-06 13:37:45 EDT
Kathy. I didn't get a failure when I created this testcase. Am I on the right track?

package acme.xxxx;

library l5
const a string = "jeff";
end
Comment 5 Kathy Carroll CLA 2011-09-06 13:54:17 EDT
This is what I used to get the problem in both install build and development environment.

package acme.xxxx;

library little
	const constantName string = "literalString";
	function functionName()
	end
	
end


I will refresh my development environment to see if that resolves the problem for me.
Comment 6 Kathy Carroll CLA 2011-09-06 14:03:05 EDT
Refresh cleared problem.  Please resolve the defect and I will verify it when the next install build is available.
Comment 7 Matt Heitz CLA 2011-09-07 07:38:52 EDT
Resolving as you requested.
Comment 8 Kathy Carroll CLA 2011-09-07 10:08:41 EDT
Verified with install build 0.7.0v201109061723
Comment 9 Lisa Lasher CLA 2011-10-11 16:11:19 EDT
Closing this defect.