Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkus Schorn2010-02-08 09:16:28 -0500
committerMarkus Schorn2010-02-08 09:16:28 -0500
commit648f5c93311e6041e3556b315f6ccbbdf0827e0c (patch)
tree50e1d87b2b755bbc684f0a1c1afe647e3a98dd49 /core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter
parentc6176c6b67bf54e0d7932f4d9a1647ab1e21ef47 (diff)
downloadorg.eclipse.cdt-648f5c93311e6041e3556b315f6ccbbdf0827e0c.tar.gz
org.eclipse.cdt-648f5c93311e6041e3556b315f6ccbbdf0827e0c.tar.xz
org.eclipse.cdt-648f5c93311e6041e3556b315f6ccbbdf0827e0c.zip
Bug 294730: Extern templates.
Diffstat (limited to 'core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter')
-rw-r--r--core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter/DeclarationWriter.java26
1 files changed, 11 insertions, 15 deletions
diff --git a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter/DeclarationWriter.java b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter/DeclarationWriter.java
index 5bba3c9ac1..32bb929125 100644
--- a/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter/DeclarationWriter.java
+++ b/core/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/dom/rewrite/astwriter/DeclarationWriter.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2008, 2009 Institute for Software, HSR Hochschule fuer Technik
+ * Copyright (c) 2008, 2010 Institute for Software, HSR Hochschule fuer Technik
* Rapperswil, University of applied sciences and others
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
@@ -35,7 +35,6 @@ import org.eclipse.cdt.core.dom.ast.cpp.ICPPASTTemplateSpecialization;
import org.eclipse.cdt.core.dom.ast.cpp.ICPPASTUsingDeclaration;
import org.eclipse.cdt.core.dom.ast.cpp.ICPPASTUsingDirective;
import org.eclipse.cdt.core.dom.ast.cpp.ICPPASTVisibilityLabel;
-import org.eclipse.cdt.core.dom.ast.gnu.cpp.IGPPASTExplicitTemplateInstantiation;
import org.eclipse.cdt.core.parser.Keywords;
import org.eclipse.cdt.internal.core.dom.parser.ASTQueries;
import org.eclipse.cdt.internal.core.dom.rewrite.commenthandler.NodeCommentMap;
@@ -236,19 +235,16 @@ public class DeclarationWriter extends NodeWriter{
}
private void writeExplicitTemplateInstantiation(ICPPASTExplicitTemplateInstantiation explicitTemplateInstantiation) {
- if (explicitTemplateInstantiation instanceof IGPPASTExplicitTemplateInstantiation) {
- IGPPASTExplicitTemplateInstantiation gppExplicitTemplateInstantiation = (IGPPASTExplicitTemplateInstantiation) explicitTemplateInstantiation;
- switch(gppExplicitTemplateInstantiation.getModifier()){
- case IGPPASTExplicitTemplateInstantiation.ti_extern:
- scribe.print(EXTERN);
- break;
- case IGPPASTExplicitTemplateInstantiation.ti_inline:
- scribe.print(INLINE);
- break;
- case IGPPASTExplicitTemplateInstantiation.ti_static:
- scribe.print(STATIC);
- break;
- }
+ switch(explicitTemplateInstantiation.getModifier()){
+ case ICPPASTExplicitTemplateInstantiation.EXTERN:
+ scribe.print(EXTERN);
+ break;
+ case ICPPASTExplicitTemplateInstantiation.INLINE:
+ scribe.print(INLINE);
+ break;
+ case ICPPASTExplicitTemplateInstantiation.STATIC:
+ scribe.print(STATIC);
+ break;
}
scribe.print(TEMPLATE);

Back to the top