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

Bug 355528

Summary: int1 **= int2 produces invalid java code
Product: z_Archived Reporter: Kathy Carroll <carrollk>
Component: EDTAssignee: Project Inbox <edt.javagen-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: jeffdouglas
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Kathy Carroll CLA 2011-08-23 11:21:11 EDT
Expecting this code 

		localInt int = 3;
		localInt **= 3;
		writeStdout(localInt);

To write out 27. Works in RBD.  

EDT generated Java

		int localInt = 0;
		localInt = (int)((short) 3);
		localInt **= (int)((short) 3);
Java error msg
    Syntax error on token "*", delete this token

RBD generated JAVA

int localInt = 0;
// localInt = 3;
localInt = (short)3;
// localInt = localInt ** 3;
localInt = com.ibm.javart.operations.AssignToInt.run( ezeProgram, com.ibm.javart.operations.Power.run( ezeProgram, localInt, (short)3 ) );
Comment 1 Jeff Douglas CLA 2011-09-09 15:44:46 EDT
I have fixed this code to use a runtime callout for power of, however until Paul fixes the bug related to the type of a binary expression, this will still give a java error. Please wait to verify this once Paul has fixed the other defect.
Comment 2 Kathy Carroll CLA 2011-09-16 14:03:34 EDT
201109161325
Comment 3 Lisa Lasher CLA 2011-10-11 16:09:38 EDT
Closing this defect.