Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Cortell2008-01-10 20:03:01 +0000
committerJohn Cortell2008-01-10 20:03:01 +0000
commitda553be6cd1f043352dd3ddba74b8156ab15b856 (patch)
tree27463f969003e730e3e39c13050c1e4a82479875
parentb5db13b8413cb3124aaa53c02663073a40bc6d7e (diff)
downloadorg.eclipse.cdt-da553be6cd1f043352dd3ddba74b8156ab15b856.tar.gz
org.eclipse.cdt-da553be6cd1f043352dd3ddba74b8156ab15b856.tar.xz
org.eclipse.cdt-da553be6cd1f043352dd3ddba74b8156ab15b856.zip
Applied additional 209793 patch to fix regression in original patch.
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CExpression.java4
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java10
2 files changed, 9 insertions, 5 deletions
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CExpression.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CExpression.java
index a13fc022f4f..206bf765e46 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CExpression.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CExpression.java
@@ -27,6 +27,7 @@ import org.eclipse.cdt.debug.core.cdi.model.type.ICDIArrayValue;
import org.eclipse.cdt.debug.core.model.CVariableFormat;
import org.eclipse.cdt.debug.core.model.ICStackFrame;
import org.eclipse.cdt.debug.core.model.ICType;
+import org.eclipse.cdt.debug.core.model.ICValue;
import org.eclipse.debug.core.DebugException;
import org.eclipse.debug.core.model.IExpression;
import org.eclipse.debug.core.model.IValue;
@@ -55,7 +56,6 @@ public class CExpression extends CLocalVariable implements IExpression {
fText = cdiExpression.getExpressionText();
fCDIExpression = cdiExpression;
fStackFrame = frame;
- setInitialFormat();
}
/* (non-Javadoc)
@@ -220,7 +220,7 @@ public class CExpression extends CLocalVariable implements IExpression {
if ( fType == null ) {
synchronized( this ) {
if ( fType == null ) {
- fType = ((AbstractCValue)fValue).getType();
+ fType = ((ICValue)fValue).getType();
}
}
}
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java
index 6f72d51ee1b..62096452cdb 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java
@@ -104,7 +104,9 @@ public abstract class CVariable extends AbstractCVariable implements ICDIEventLi
}
fIsEnabled = ( parent instanceof AbstractCValue ) ? ((AbstractCValue)parent).getParentVariable().isEnabled() : !isBookkeepingEnabled();
getCDISession().getEventManager().addEventListener( this );
- setInitialFormat();
+ if ( cdiVariableObject != null ) {
+ setInitialFormat();
+ }
}
/**
@@ -119,7 +121,9 @@ public abstract class CVariable extends AbstractCVariable implements ICDIEventLi
fIsEnabled = !isBookkeepingEnabled();
setStatus( ICDebugElementStatus.ERROR, MessageFormat.format( CoreModelMessages.getString( "CVariable.1" ), new String[]{ errorMessage } ) ); //$NON-NLS-1$
getCDISession().getEventManager().addEventListener( this );
- setInitialFormat();
+ if ( cdiVariableObject != null ) {
+ setInitialFormat();
+ }
}
/*
@@ -764,7 +768,7 @@ public abstract class CVariable extends AbstractCVariable implements ICDIEventLi
/**
* restore the format stored previously for this variable.
- * Only sets explictly retrieved formats in order to maintain defaults.
+ * Only sets explicitly retrieved formats in order to maintain defaults.
*/
protected void setInitialFormat() {
try {

Back to the top