1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-24 17:35:35 +02:00

Bug 431544 - UnsupportedOperationException in

ControlFlowGraphBuilder.build

Change-Id: I91fd0b4e1a816b80a4bbad5e7a8ee1f61f9862a9
Reviewed-on: https://git.eclipse.org/r/24214
Reviewed-by: Sergey Prigogin <eclipse.sprigogin@gmail.com>
IP-Clean: Sergey Prigogin <eclipse.sprigogin@gmail.com>
Tested-by: Sergey Prigogin <eclipse.sprigogin@gmail.com>
This commit is contained in:
Sergey Prigogin 2014-03-31 10:45:24 -07:00
parent 14bea54256
commit dc19bb3b6b

View file

@ -84,7 +84,8 @@ public class ControlFlowGraphBuilder {
exits.add(returnExit);
for (IBasicBlock ds : dead) {
IBasicBlock dl = findLast(ds);
if (dl != null && dl.getOutgoingSize() == 0 && dl != returnExit) {
if (dl != null && !(dl instanceof IExitNode) && dl.getOutgoingSize() == 0 &&
dl != returnExit) {
((AbstractBasicBlock) dl).addOutgoing(returnExit);
}
}