Lines 1-5
Link Here
|
1 |
/******************************************************************************* |
1 |
/******************************************************************************* |
2 |
* Copyright (c) 2000, 2008 IBM Corporation and others. |
2 |
* Copyright (c) 2000, 2009 IBM Corporation and others. |
3 |
* All rights reserved. This program and the accompanying materials |
3 |
* All rights reserved. This program and the accompanying materials |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
5 |
* which accompanies this distribution, and is available at |
5 |
* which accompanies this distribution, and is available at |
Lines 10-15
Link Here
|
10 |
* Dmitry Stalnov (dstalnov@fusionone.com) - contributed fix for |
10 |
* Dmitry Stalnov (dstalnov@fusionone.com) - contributed fix for |
11 |
* o inline call that is used in a field initializer |
11 |
* o inline call that is used in a field initializer |
12 |
* (see https://bugs.eclipse.org/bugs/show_bug.cgi?id=38137) |
12 |
* (see https://bugs.eclipse.org/bugs/show_bug.cgi?id=38137) |
|
|
13 |
* Benjamin Muskalla <bmuskalla@eclipsesource.com> |
14 |
* 213519: [extract method] Missing return value, while extractiong code out of a loop |
13 |
*******************************************************************************/ |
15 |
*******************************************************************************/ |
14 |
package org.eclipse.jdt.internal.corext.refactoring.code.flow; |
16 |
package org.eclipse.jdt.internal.corext.refactoring.code.flow; |
15 |
|
17 |
|
Lines 172-178
Link Here
|
172 |
} |
174 |
} |
173 |
|
175 |
|
174 |
private void createLoopReentranceVisitor(ASTNode node) { |
176 |
private void createLoopReentranceVisitor(ASTNode node) { |
175 |
if (fLoopReentranceVisitor == null && fDoLoopReentrance) |
177 |
if (fLoopReentranceVisitor == null && fDoLoopReentrance && fSelection.coveredBy(node)) |
176 |
fLoopReentranceVisitor= new LoopReentranceVisitor(fFlowContext, fSelection, node); |
178 |
fLoopReentranceVisitor= new LoopReentranceVisitor(fFlowContext, fSelection, node); |
177 |
} |
179 |
} |
178 |
|
180 |
|
Lines 257-263
Link Here
|
257 |
} |
259 |
} |
258 |
|
260 |
|
259 |
private void handleLoopReentrance(ASTNode node) { |
261 |
private void handleLoopReentrance(ASTNode node) { |
260 |
if (!fSelection.coveredBy(node) || fLoopReentranceVisitor == null || fLoopReentranceVisitor.getLoopNode() != node) |
262 |
if (fLoopReentranceVisitor == null || fLoopReentranceVisitor.getLoopNode() != node) |
261 |
return; |
263 |
return; |
262 |
|
264 |
|
263 |
fLoopReentranceVisitor.process(node); |
265 |
fLoopReentranceVisitor.process(node); |