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

Bug 360008

Summary: Library CONST constUPD decimal = 543.21; incorrectly producing validation errors
Product: z_Archived Reporter: Kathy Carroll <carrollk>
Component: EDTAssignee: Project Inbox <edt.compiler-inbox>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: pharmon
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Kathy Carroll CLA 2011-10-05 11:59:41 EDT
this declaration 

  CONST constUPD decimal = 543.21;

produces these errors

Multiple markers at this line
	- IWN.VAL.3465.e 7/27 The number of non-decimal digits in value 543.21 is 3, which is longer than the defined length 0 for non-decimal digits of constant 
	 constUPD.
	- IWN.VAL.3466.e 7/27 The number of decimal digits in value 543.21 is 2, which is longer than the defined number of decimal digits 0 for constant constUPD.

However, this is OK

constUPD decimal = 543.21;

Full test is
// basic library
library TestVariable
	
	updated decimal = 543.21;
	CONST constUPD decimal = 543.21;
//	constUPD decimal = 543.21;
	
	// Function Declarations
	function verify() {@Test}
		general decimal = 543.21;
		specific decimal(5,2) = 543.21;
		LogResult.assertTrue1(general == specific);
	end
	
	function variation2() {@Test}
		specific decimal(5,2) = 543.21;
		LogResult.assertTrue1(updated == specific);
	end
	
	function variation3() {@Test}
		specific decimal(5,2) = 543.21;
		LogResult.assertTrue1(constUPD == specific);
	end
end
Comment 1 Paul Harmon CLA 2011-11-07 14:20:14 EST
I have removed this restriction (in AbstractBinder) so that the messages are no longer produced for reference type Decimal types
Comment 2 Kathy Carroll CLA 2011-11-08 07:18:28 EST
verified with 201111072101 & closed