diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/IEnumeration.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/IEnumeration.java index e824997fd8c..44ac69481e4 100644 --- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/IEnumeration.java +++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/model/IEnumeration.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2005 QNX Software Systems and others. + * Copyright (c) 2000, 2006 QNX Software Systems 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 @@ -7,11 +7,19 @@ * * Contributors: * QNX Software Systems - Initial API and implementation + * Markus Schorn (Wind River Systems) *******************************************************************************/ package org.eclipse.cdt.core.model; /** * An Enumeration type. */ -public interface IEnumeration extends IVariable, IParent { +public interface IEnumeration extends IParent, IDeclaration { + + /** + * Return "enum" + * @throws CModelException + * @deprecated + */ + String getTypeName() throws CModelException; } diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Enumeration.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Enumeration.java index 1d0bdbe30a7..b398b9ffcfd 100644 --- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Enumeration.java +++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/internal/core/model/Enumeration.java @@ -7,6 +7,7 @@ * * Contributors: * Rational Software - Initial API and implementation + * Markus Schorn (Wind River Systems) *******************************************************************************/ package org.eclipse.cdt.internal.core.model; @@ -28,12 +29,6 @@ public class Enumeration extends SourceManipulation implements IEnumeration{ private EnumerationInfo getEnumerationInfo() throws CModelException{ return (EnumerationInfo) getElementInfo(); } - /** - * @see org.eclipse.cdt.core.model.IVariable#getInitializer() - */ - public String getInitializer() { - return null; - } /** * @see org.eclipse.cdt.core.model.IVariableDeclaration#getTypeName() diff --git a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/missingapi/CIndexQueries.java b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/missingapi/CIndexQueries.java index fd9eea120a7..dd1816bff74 100644 --- a/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/missingapi/CIndexQueries.java +++ b/core/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/missingapi/CIndexQueries.java @@ -342,10 +342,7 @@ public class CIndexQueries { return element; } if (element instanceof org.eclipse.cdt.core.model.IVariable) { - // bug 156844 - if (!(element instanceof org.eclipse.cdt.core.model.IEnumeration)) { - return element; - } + return element; } try { if (element instanceof IParent) {