Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 360310

Summary: The EGL source code generated by new variable wizard (EGL data view) has syntax errors
Product: z_Archived Reporter: fahua jin <jinfahua>
Component: EDTAssignee: Huo Zhen Zhong <huozz>
Status: CLOSED FIXED QA Contact:
Severity: major    
Priority: P3 CC: chenzhh, huozz, pharmon, svihovec
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
fix lasher: iplog+

Description fahua jin CLA 2011-10-08 04:20:41 EDT
Build Identifier: 0.7.0.v201110072101

1) In the 'EGL Data' view > New > EGL Variable > Primitive > string > check
'Array' > in the Size field > Input 1
2) In the following generated EGL source code, it reports errors.
  mystring1 string[0]{maxSize=1};

Below is the error message.
	- IWN.VAL.6619.e 18/25 H1 - maxSize cannot be resolved. At line 18 in file \Test\EGLSource\client
	 \H1.egl
	- IWN.VAL.3248.e 18/15 Dimension specification is not allowed on an array declaration.


Reproducible: Always
Comment 1 Huo Zhen Zhong CLA 2011-10-08 04:30:16 EDT
Hi, Paul
Is maxSize and Dimension specification are supported in EDT 0.7, should I remove them?
Comment 2 Paul Harmon CLA 2011-10-10 10:14:02 EDT
Some changes to arrays that you are probably not aware of:

You can no longer specify a dimension on an array definition:

myarr1 int[5];  //this is illegal
myarr1 int = new int[5]; this is fine;
myarr1 int {0,0,0,0,0}; this is fine;
myarr1 int = [0,0,0,0,0]; //this is fine

The maxSize annotation has been removed.


So, yes, you should not put in the dimention of 0 (this is the default size anyway) and remove the option to set a maxsize.
Comment 3 Huo Zhen Zhong CLA 2011-10-10 23:20:01 EDT
Created attachment 204917 [details]
fix
Comment 4 Huo Zhen Zhong CLA 2011-10-10 23:20:56 EDT
fixed
Comment 5 Brian Svihovec CLA 2011-10-11 13:23:00 EDT
If we are confident that this is the final solution, we should remove the commented out code so that it does not cause confusion in the future.
Comment 6 Huo Zhen Zhong CLA 2011-10-11 22:25:06 EDT
Hi, Paul, just make sure the change of the language is not a temp change for EDT 0.7.0, if yes, I will remove the commented out code.
Comment 7 fahua jin CLA 2011-10-12 04:31:53 EDT
Verified in 0.7.0.v201110110900.
Comment 8 Paul Harmon CLA 2011-10-12 09:29:15 EDT
This is a permanent semantic difference between EDT and RBD