1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-06 17:26:01 +02:00

Cosmetics.

This commit is contained in:
Sergey Prigogin 2013-11-27 12:17:45 -08:00
parent e9e53fb9fa
commit 2f38016b98
4 changed files with 6 additions and 6 deletions

View file

@ -124,8 +124,8 @@ public class NodeCommentMapTest extends TestCase {
assertEquals(com3, map.getFreestandingCommentsForNode(node1).get(1)); assertEquals(com3, map.getFreestandingCommentsForNode(node1).get(1));
} }
//=== InternalComment class for testing //=== Internal Comment class for testing
private class Comment extends ASTNode implements IASTComment { private static class Comment extends ASTNode implements IASTComment {
private char[] comment; private char[] comment;
@Override @Override

View file

@ -7,7 +7,7 @@
* http://www.eclipse.org/legal/epl-v10.html * http://www.eclipse.org/legal/epl-v10.html
* *
* Contributors: * Contributors:
* Emanuel Graf & Leo Buettiker - initial API and implementation * Emanuel Graf & Leo Buettiker - initial API and implementation
******************************************************************************/ ******************************************************************************/
package org.eclipse.cdt.core.dom.ast; package org.eclipse.cdt.core.dom.ast;

View file

@ -19,7 +19,7 @@ import org.eclipse.cdt.core.dom.ast.INodeFactory;
public abstract class NodeFactory implements INodeFactory { public abstract class NodeFactory implements INodeFactory {
@Override @Override
public final void setOffsets(IASTNode node, int offset, int endOffset) { public final void setOffsets(IASTNode node, int offset, int endOffset) {
((ASTNode) node).setOffsetAndLength(offset, endOffset-offset); ((ASTNode) node).setOffsetAndLength(offset, endOffset - offset);
} }
@Override @Override

View file

@ -274,10 +274,10 @@ public class LocationMap implements ILocationResolver {
CharSequence text = getTrimmedCommentText(input.subSequence(offset, endOffset), isBlockComment); CharSequence text = getTrimmedCommentText(input.subSequence(offset, endOffset), isBlockComment);
IncludeExportPatterns patterns = fLexerOptions.fIncludeExportPatterns; IncludeExportPatterns patterns = fLexerOptions.fIncludeExportPatterns;
if (patterns.getIncludeExportPattern() != null if (patterns.getIncludeExportPattern() != null
&& patterns.getIncludeExportPattern().matcher(text).matches()) { && patterns.getIncludeExportPattern().matcher(text).matches()) {
((LocationCtxFile) fCurrentContext).setOffsetOfIncludeExport(offset); ((LocationCtxFile) fCurrentContext).setOffsetOfIncludeExport(offset);
} else if (patterns.getIncludeBeginExportsPattern() != null } else if (patterns.getIncludeBeginExportsPattern() != null
&& patterns.getIncludeBeginExportsPattern().matcher(text).matches()) { && patterns.getIncludeBeginExportsPattern().matcher(text).matches()) {
((LocationCtxFile) fCurrentContext).setInsideIncludeExportBlock(true); ((LocationCtxFile) fCurrentContext).setInsideIncludeExportBlock(true);
} else if (patterns.getIncludeEndExportsPattern() != null } else if (patterns.getIncludeEndExportsPattern() != null
&& patterns.getIncludeEndExportsPattern().matcher(text).matches()) { && patterns.getIncludeEndExportsPattern().matcher(text).matches()) {