1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Bug 323206 - [Code templates] Pop up error when using code formatter option and ${line_selection}

This commit is contained in:
Anton Leherbauer 2010-08-20 08:21:32 +00:00
parent edd73c9886
commit eabf8400b2

View file

@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2006 IBM Corporation and others.
* Copyright (c) 2006, 2010 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@ -77,7 +77,7 @@ final class ExclusivePositionUpdater implements IPositionUpdater {
// offset becomes end of event, length adjusted accordingly
int newOffset= eventOffset + eventNewLength;
position.setOffset(newOffset);
position.setLength(end - newOffset);
position.setLength(end - newOffset + deltaLength);
} else {
// event consumes the position - delete it
position.delete();