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

Bug 362075

Summary: Debugging JS exception block the variable view need to show something for the exception
Product: z_Archived Reporter: Kathy Carroll <carrollk>
Component: EDTAssignee: Justin Spadea <jspadea>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: jspadea
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Kathy Carroll CLA 2011-10-26 10:07:00 EDT
Debugging JS exception block the variable view need to show something for the exception.  

When debugging with Java and I select the variable used in my onexception statement, I see this in the variables view:

eglx.lang.NumericOverflowException
eglx.lang.NullValueException A null value was used.

JavaScript is empty.

Below is the eunit test to recreate the problem.  Set a breakpoint inside the onException block and look at the variable.

package mine;

// basic library
library tester
	
 	function runAssignmentFunction29() {@Test}
	 	variation string = "operation into overflow";
		try
			overflow decimal(5,2) = 123.45;
			overflow = overflow + 1000.25;
			variation += " no exception. Bug 356228 - EDT 1.0";
			LogResult.skipped(variation);
		onException (oops AnyException)
			if (oops isa NumericOverflowException)
				LogResult.passed("OK");
			else
				variation += " wrong exception.";
				LogResult.skipped(variation);
			end
		end
	end
	
	function runExceptionTest() {@Test}
		nullString string? = null;
		try
			nullString.matchesPattern("sbac");
			LogResult.failed("no exception");
		onException (oops AnyException)
			if (oops isa NullValueException)
				LogResult.passed("OK");
			else
				LogResult.skipped("wrong exception");
			end
		end		
		
	end
	
end
Comment 1 Justin Spadea CLA 2011-10-26 17:54:49 EDT
I noticed Java's display of exceptions was wrong so I added a bunch of missing SMAPs to the runtime.

For RUI I changed it to look like Java ("<type> <message>"). We used to display the actual type instead of AnyException in the Declared Type column, but now that the value of the exception shows the actual type I changed this back to display AnyException.
Comment 2 Kathy Carroll CLA 2011-10-27 15:18:49 EDT
Verified with 20111027_1153 & closed