Lines 16-21
Link Here
|
16 |
import org.eclipse.wst.jsdt.internal.compiler.flow.FlowContext; |
16 |
import org.eclipse.wst.jsdt.internal.compiler.flow.FlowContext; |
17 |
import org.eclipse.wst.jsdt.internal.compiler.flow.FlowInfo; |
17 |
import org.eclipse.wst.jsdt.internal.compiler.flow.FlowInfo; |
18 |
import org.eclipse.wst.jsdt.internal.compiler.lookup.BlockScope; |
18 |
import org.eclipse.wst.jsdt.internal.compiler.lookup.BlockScope; |
|
|
19 |
import org.eclipse.wst.jsdt.internal.compiler.lookup.ProblemReferenceBinding; |
19 |
import org.eclipse.wst.jsdt.internal.compiler.lookup.TypeBinding; |
20 |
import org.eclipse.wst.jsdt.internal.compiler.lookup.TypeBinding; |
20 |
|
21 |
|
21 |
public class ThrowStatement extends Statement implements IThrowStatement { |
22 |
public class ThrowStatement extends Statement implements IThrowStatement { |
Lines 44-59
Link Here
|
44 |
|
45 |
|
45 |
public void resolve(BlockScope scope) { |
46 |
public void resolve(BlockScope scope) { |
46 |
this.exceptionType = this.exception.resolveType(scope); |
47 |
this.exceptionType = this.exception.resolveType(scope); |
47 |
if (this.exceptionType != null && this.exceptionType.isValidBinding()) { |
48 |
if (this.exceptionType == null || !this.exceptionType.isValidBinding()) { |
48 |
// if (this.exceptionType == TypeBinding.NULL) { |
49 |
this.exceptionType = new ProblemReferenceBinding(new char[0][0],null,0); |
49 |
// if (scope.compilerOptions().complianceLevel <= ClassFileConstants.JDK1_3){ |
|
|
50 |
// // if compliant with 1.4, this problem will not be reported |
51 |
// scope.problemReporter().cannotThrowNull(this.exception); |
52 |
// } |
53 |
// } else if (exceptionType.findSuperTypeErasingTo(TypeIds.T_JavaLangThrowable, true) == null) { |
54 |
// scope.problemReporter().cannotThrowType(this.exception, this.exceptionType); |
55 |
// } |
56 |
// this.exception.computeConversion(scope, this.exceptionType, this.exceptionType); |
57 |
} |
50 |
} |
58 |
} |
51 |
} |
59 |
|
52 |
|