Source:
<code>public RefactoringStatus checkInitialConditions(IProgressMonitor monitor) throws CoreException, OperationCanceledException { SubMonitor subMonitor = SubMonitor.convert(monitor, 12); RefactoringStatus status = super.checkInitialConditions(subMonitor.split(8)); if (status.hasError()) { return status; } if (selectedRegion == null) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); return status; } IASTExpression selectedExpression = findSelectedExpression(subMonitor.split(1)); if (selectedExpression == null) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); return status; } if (!isExtractableExpression(selectedExpression)) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); } Collection<IASTLiteralExpression> literalExpressionCollection = findAllLiterals(subMonitor.split(1)); if (literalExpressionCollection.isEmpty()) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); return status; } target = selectedExpression; if (info.getName().isEmpty()) { info.setName(getDefaultName(target)); } info.setMethodContext(NodeHelper.findMethodContext(target, refactoringContext, subMonitor.split(1))); IScope containingScope = CPPVisitor.getContainingScope(target); IASTTranslationUnit ast = target.getTranslationUnit(); info.setNameUsedChecker((String name) -> { IBinding[] bindingsForName = containingScope.find(name, ast); return bindingsForName.length != 0; }); <START> subMonitor.split(1); <END> return status; }</code><technical_language>split method called a piece of work, after. Please correct in other places too</technical_language>

Target:
public RefactoringStatus checkInitialConditions(IProgressMonitor monitor) throws CoreException, OperationCanceledException { SubMonitor subMonitor = SubMonitor.convert(monitor, 12); RefactoringStatus status = super.checkInitialConditions(subMonitor.split(8)); if (status.hasError()) { return status; } if (selectedRegion == null) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); return status; } IASTExpression selectedExpression = findSelectedExpression(subMonitor.split(1)); if (selectedExpression == null) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); return status; } if (!isExtractableExpression(selectedExpression)) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); } Collection<IASTLiteralExpression> literalExpressionCollection = findAllLiterals(subMonitor.split(1)); if (literalExpressionCollection.isEmpty()) { status.addFatalError(Messages.ExtractConstantRefactoring_LiteralMustBeSelected); return status; } target = selectedExpression; if (info.getName().isEmpty()) { info.setName(getDefaultName(target)); } info.setMethodContext(NodeHelper.findMethodContext(target, refactoringContext, subMonitor.split(1))); subMonitor.split(1); IScope containingScope = CPPVisitor.getContainingScope(target); IASTTranslationUnit ast = target.getTranslationUnit(); info.setNameUsedChecker((String name) -> { IBinding[] bindingsForName = containingScope.find(name, ast); return bindingsForName.length != 0; }); return status; }