diff --git a/core/org.eclipse.cdt.core/META-INF/MANIFEST.MF b/core/org.eclipse.cdt.core/META-INF/MANIFEST.MF
index bad3554ca8a..0badfaba81b 100644
--- a/core/org.eclipse.cdt.core/META-INF/MANIFEST.MF
+++ b/core/org.eclipse.cdt.core/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.cdt.core; singleton:=true
-Bundle-Version: 5.5.0.qualifier
+Bundle-Version: 5.6.0.qualifier
Bundle-Activator: org.eclipse.cdt.core.CCorePlugin
Bundle-Vendor: %providerName
Bundle-Localization: plugin
diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/ICSettingEntry.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/ICSettingEntry.java
index 2dfdc007014..8bffda5eb33 100644
--- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/ICSettingEntry.java
+++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/ICSettingEntry.java
@@ -1,12 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2007, 2010 Intel Corporation and others.
+ * Copyright (c) 2007, 2013 Intel 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
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * Intel Corporation - Initial API and implementation
+ * Intel Corporation - Initial API and implementation
*******************************************************************************/
package org.eclipse.cdt.core.settings.model;
@@ -23,6 +23,12 @@ import org.eclipse.cdt.core.settings.model.util.CDataUtil;
* entries could be safely pooled by {@link CDataUtil#getPooledEntry(ICSettingEntry)}.
*/
public interface ICSettingEntry {
+ /**
+ * A constant known to be zero (0), used to indicate that no flags are set.
+ * @since 5.6
+ */
+ int NONE = 0;
+
/**
* Flag {@code BUILTIN} indicates settings built in a tool (compiler) itself.
* That kind of settings are not passed as options to a compiler but indexer
@@ -100,5 +106,4 @@ public interface ICSettingEntry {
boolean equalsByContents(ICSettingEntry entry);
int getFlags();
-
}
diff --git a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/LanguageSettingEntriesSerializer.java b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/LanguageSettingEntriesSerializer.java
index c69b3c5a36d..3787a7dd3fa 100644
--- a/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/LanguageSettingEntriesSerializer.java
+++ b/core/org.eclipse.cdt.core/model/org/eclipse/cdt/core/settings/model/util/LanguageSettingEntriesSerializer.java
@@ -1,12 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2007, 2010 Intel Corporation and others.
+ * Copyright (c) 2007, 2013 Intel 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
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * Intel Corporation - Initial API and implementation
+ * Intel Corporation - Initial API and implementation
*******************************************************************************/
package org.eclipse.cdt.core.settings.model.util;
@@ -45,6 +45,8 @@ public class LanguageSettingEntriesSerializer {
public static final String SOURCE_PATH = "sourcePath"; //$NON-NLS-1$
public static final String OUTPUT_PATH = "outputPath"; //$NON-NLS-1$
+ /** @since 5.6 */
+ public static final String NONE = "NONE"; //$NON-NLS-1$
public static final String BUILTIN = "BUILTIN"; //$NON-NLS-1$
public static final String READONLY = "READONLY"; //$NON-NLS-1$
public static final String LOCAL = "LOCAL"; //$NON-NLS-1$
@@ -225,7 +227,10 @@ public class LanguageSettingEntriesSerializer {
}
public static String composeFlagsString(int flags) {
- StringBuffer buf = new StringBuffer();
+ if (flags == ICSettingEntry.NONE) {
+ return NONE;
+ }
+ StringBuilder buf = new StringBuilder();
if ((flags & ICSettingEntry.BUILTIN) != 0) {
buf.append(BUILTIN);
}
@@ -272,7 +277,7 @@ public class LanguageSettingEntriesSerializer {
* @since 5.4
*/
public static int composeFlags(String flagsString) {
- if (flagsString == null || flagsString.length() == 0)
+ if (flagsString == null || flagsString.isEmpty() || flagsString.equals(NONE))
return 0;
StringTokenizer tokenizer = new StringTokenizer(flagsString, FLAGS_SEPARATOR);
@@ -298,5 +303,4 @@ public class LanguageSettingEntriesSerializer {
return flags;
}
-
}
diff --git a/core/org.eclipse.cdt.core/pom.xml b/core/org.eclipse.cdt.core/pom.xml
index 8d842b35176..4d076adc086 100644
--- a/core/org.eclipse.cdt.core/pom.xml
+++ b/core/org.eclipse.cdt.core/pom.xml
@@ -11,7 +11,7 @@
../../pom.xml
- 5.5.0-SNAPSHOT
+ 5.6.0-SNAPSHOT
org.eclipse.cdt.core
eclipse-plugin