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

Bug 326849

Summary: Dangling type error produced for valid syntax
Product: z_Archived Reporter: Henrik Lindberg <henrik.lindberg>
Component: b3Assignee: Project Inbox <b3.engine-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Henrik Lindberg CLA 2010-10-02 18:17:46 EDT
The b3 code:
function foo() {
	[<()=>Integer> {<Integer>| 10 }];
}

Results in an error marker for '<()=>Integer>' with an error message like:
The feature 'functionType' of 'org.eclipse.b3.backend.evaluator.b3backend.impl.B3FunctionTypeImpl@4ab98c18{platform:/resource/AutoLinked_B3ExternalFiles/untitled/untitled-3.b3#//@functions.0/@funcExpr/@expressions.0/@entryType}'
   contains a dangling reference 'org.eclipse.b3.backend.evaluator.b3backend.impl.B3TypeImpl@7c224ac7{#//}'

This is a regression.
Comment 1 Henrik Lindberg CLA 2010-10-02 19:04:23 EDT
When functionType was set to null, an attempt was made to coerce this to an EObject IType which resulted in an B3Type referencing Object.class - this instance was indeed dangling.

A check is now made if the type is null.
Comment 2 Henrik Lindberg CLA 2010-10-02 19:04:43 EDT
.