Skip to main content
summaryrefslogtreecommitdiffstats
path: root/xlc
diff options
context:
space:
mode:
authorMike Kucera2009-04-20 14:24:34 -0400
committerMike Kucera2009-04-20 14:24:34 -0400
commit0a80b06634e712cbe7c7a5e3256e87db8b464594 (patch)
tree86faef3455a40a88a9843f4819cb14588f4aed92 /xlc
parent21e1364cb500e824afcec492012db84094d92db5 (diff)
downloadorg.eclipse.cdt-0a80b06634e712cbe7c7a5e3256e87db8b464594.tar.gz
org.eclipse.cdt-0a80b06634e712cbe7c7a5e3256e87db8b464594.tar.xz
org.eclipse.cdt-0a80b06634e712cbe7c7a5e3256e87db8b464594.zip
[272950] [LR Parser] Add ability to pass properties to extending parsers and update (regenerate) the parsers to support this.
Diffstat (limited to 'xlc')
-rw-r--r--xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/PreferenceMessages.properties5
-rw-r--r--xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/XlcLanguageOptionsPreferencePage.java44
2 files changed, 27 insertions, 22 deletions
diff --git a/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/PreferenceMessages.properties b/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/PreferenceMessages.properties
index efad63b202..dcc484ed2d 100644
--- a/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/PreferenceMessages.properties
+++ b/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/PreferenceMessages.properties
@@ -1,4 +1,7 @@
XlcLanguageOptionsPreferencePage_link=These settings are project-specific. The settings listed here override <a href="org.eclipse.cdt.core.lrparser.xlc.ui.XlcLanguagePreferencePage">workspace-wide</a> language settings.
XlcLanguageOptionsPreferencePage_group=Support For XL C/C++ Language Extensions
-XlcLanguageOptionsPreferencePage_preference_vectors=Support vector types \ No newline at end of file
+
+XlcLanguageOptionsPreferencePage_preference_vectors=Allow vector type declarations
+XlcLanguageOptionsPreferencePage_preference_decimals=Allow decimal floating-point types (_Decimal32, _Decimal64, _Decimal128)
+
diff --git a/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/XlcLanguageOptionsPreferencePage.java b/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/XlcLanguageOptionsPreferencePage.java
index 7bed893e08..ca4bd108fc 100644
--- a/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/XlcLanguageOptionsPreferencePage.java
+++ b/xlc/org.eclipse.cdt.core.lrparser.xlc/ui/org/eclipse/cdt/internal/core/lrparser/xlc/ui/preferences/XlcLanguageOptionsPreferencePage.java
@@ -39,25 +39,10 @@ public class XlcLanguageOptionsPreferencePage extends PreferencePage implements
private IAdaptable element;
- private Button button_vectors;
+ private Button buttonVectors;
+ private Button buttonDecimals;
- public IAdaptable getElement() {
- return element;
- }
-
- public void setElement(IAdaptable element) {
- this.element = element;
- }
-
- public boolean isPropertyPage() {
- return element != null;
- }
-
- public void init(IWorkbench workbench) {
- // TODO Auto-generated method stub
- }
-
@Override
protected Control createContents(Composite parent) {
Composite page = ControlFactory.createComposite(parent, 1);
@@ -74,8 +59,8 @@ public class XlcLanguageOptionsPreferencePage extends PreferencePage implements
Composite group = ControlFactory.createGroup(page, PreferenceMessages.XlcLanguageOptionsPreferencePage_group, 1);
- button_vectors = ControlFactory.createCheckBox(group, PreferenceMessages.XlcLanguageOptionsPreferencePage_preference_vectors);
- initCheckbox(button_vectors, XlcPreferenceKeys.KEY_SUPPORT_VECTOR_TYPES);
+ buttonVectors = ControlFactory.createCheckBox(group, PreferenceMessages.XlcLanguageOptionsPreferencePage_preference_vectors);
+ initCheckbox(buttonVectors, XlcPreferenceKeys.KEY_SUPPORT_VECTOR_TYPES);
return page;
}
@@ -103,14 +88,14 @@ public class XlcLanguageOptionsPreferencePage extends PreferencePage implements
@Override
protected void performDefaults() {
- button_vectors.setSelection(Boolean.valueOf(XlcLanguagePreferences.getDefaultPreference(XlcPreferenceKeys.KEY_SUPPORT_VECTOR_TYPES)));
+ buttonVectors.setSelection(Boolean.valueOf(XlcLanguagePreferences.getDefaultPreference(XlcPreferenceKeys.KEY_SUPPORT_VECTOR_TYPES)));
super.performDefaults();
}
@Override
public boolean performOk() {
- setPreference(XlcPreferenceKeys.KEY_SUPPORT_VECTOR_TYPES, button_vectors.getSelection(), getProject());
+ setPreference(XlcPreferenceKeys.KEY_SUPPORT_VECTOR_TYPES, buttonVectors.getSelection(), getProject());
return true;
}
@@ -126,5 +111,22 @@ public class XlcLanguageOptionsPreferencePage extends PreferencePage implements
XlcLanguagePreferences.setWorkspacePreference(key, String.valueOf(val));
}
+
+
+ public IAdaptable getElement() {
+ return element;
+ }
+
+ public void setElement(IAdaptable element) {
+ this.element = element;
+ }
+
+ public boolean isPropertyPage() {
+ return element != null;
+ }
+
+ public void init(IWorkbench workbench) {
+ // TODO Auto-generated method stub
+ }
}

Back to the top