Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMikhail Khodjaiants2003-06-20 21:58:16 +0000
committerMikhail Khodjaiants2003-06-20 21:58:16 +0000
commit40e2cbf0b08aa51acdfaeeb48ef18cf83e1be6b3 (patch)
treebc12ae662df5090b9178feed9fa8d74c22808f1a
parent109d948e1f12e5a06185ac419a3957e91a4f842b (diff)
downloadorg.eclipse.cdt-40e2cbf0b08aa51acdfaeeb48ef18cf83e1be6b3.tar.gz
org.eclipse.cdt-40e2cbf0b08aa51acdfaeeb48ef18cf83e1be6b3.tar.xz
org.eclipse.cdt-40e2cbf0b08aa51acdfaeeb48ef18cf83e1be6b3.zip
In the 'getVariableText' and 'getVariableImage' methods of CDTDebugModelPresentation ignore exceptions thrown by getType.
-rw-r--r--debug/org.eclipse.cdt.debug.ui/ChangeLog5
-rw-r--r--debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/CDTDebugModelPresentation.java20
2 files changed, 23 insertions, 2 deletions
diff --git a/debug/org.eclipse.cdt.debug.ui/ChangeLog b/debug/org.eclipse.cdt.debug.ui/ChangeLog
index 108d0a802a..62e579e20f 100644
--- a/debug/org.eclipse.cdt.debug.ui/ChangeLog
+++ b/debug/org.eclipse.cdt.debug.ui/ChangeLog
@@ -1,4 +1,9 @@
2003-06-20 Mikhail Khodjaiants
+ In the 'getVariableText' and 'getVariableImage' methods of CDTDebugModelPresentation
+ ignore exceptions thrown by getType.
+ * CDTDebugModelPresentation.java
+
+2003-06-20 Mikhail Khodjaiants
Variable bookkeeping (phase 0.1).
The 'Enable' and 'Disable' actions added to the Variables view.
* plugin.properties
diff --git a/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/CDTDebugModelPresentation.java b/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/CDTDebugModelPresentation.java
index 5256f6cbcc..9bd6d8cff1 100644
--- a/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/CDTDebugModelPresentation.java
+++ b/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/CDTDebugModelPresentation.java
@@ -544,7 +544,15 @@ public class CDTDebugModelPresentation extends LabelProvider
StringBuffer label = new StringBuffer();
if ( var instanceof ICVariable )
{
- ICType type = ((ICVariable)var).getType();
+ ICType type = null;
+ try
+ {
+ type = ((ICVariable)var).getType();
+ }
+ catch( DebugException e )
+ {
+ // don't display type
+ }
if ( type != null && isShowVariableTypeNames() )
{
String typeName = getVariableTypeName( type );
@@ -872,7 +880,15 @@ public class CDTDebugModelPresentation extends LabelProvider
{
if ( element instanceof ICVariable )
{
- ICType type = ((ICVariable)element).getType();
+ ICType type = null;
+ try
+ {
+ type = ((ICVariable)element).getType();
+ }
+ catch( DebugException e )
+ {
+ // use default image
+ }
if ( type != null && ( type.isArray() || type.isStructure() ) )
return fDebugImageRegistry.get( ( ((ICVariable)element).isEnabled() ) ?
CDebugImages.DESC_OBJS_VARIABLE_AGGREGATE : CDebugImages.DESC_OBJS_VARIABLE_AGGREGATE_DISABLED );

Back to the top