1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-07 00:05:53 +02:00

Invalidate error variables when the session is resumed.

This commit is contained in:
Mikhail Khodjaiants 2003-08-05 17:49:30 +00:00
parent 02bab456aa
commit 6d5684edff
2 changed files with 25 additions and 1 deletions

View file

@ -1,3 +1,7 @@
2003-08-05 Mikhail Khodjaiants
Invalidate error variables when the session is resumed.
* CVariable.java
2003-07-30 Mikhail Khodjaiants
Moved the 'getReferencedProject' method to 'CDebugUtils'. Added the cycle checking.
* CDebugUtils.java

View file

@ -17,6 +17,7 @@ import org.eclipse.cdt.debug.core.cdi.event.ICDIChangedEvent;
import org.eclipse.cdt.debug.core.cdi.event.ICDIDestroyedEvent;
import org.eclipse.cdt.debug.core.cdi.event.ICDIEvent;
import org.eclipse.cdt.debug.core.cdi.event.ICDIEventListener;
import org.eclipse.cdt.debug.core.cdi.event.ICDIResumedEvent;
import org.eclipse.cdt.debug.core.cdi.model.ICDIArgumentObject;
import org.eclipse.cdt.debug.core.cdi.model.ICDIObject;
import org.eclipse.cdt.debug.core.cdi.model.ICDIStackFrame;
@ -230,7 +231,7 @@ public abstract class CVariable extends CDebugElement
{
try
{
if ( fCDIVariable != null )
if ( fCDIVariable != null && !(fCDIVariable instanceof ErrorVariable) )
getCDISession().getVariableManager().destroyVariable( fCDIVariable );
}
catch( CDIException e )
@ -526,6 +527,25 @@ public abstract class CVariable extends CDebugElement
handleDestroyedEvent( (ICDIDestroyedEvent)event );
}
}
else if ( event instanceof ICDIResumedEvent )
{
handleResumedEvent( (ICDIResumedEvent)event );
}
}
}
private void handleResumedEvent( ICDIResumedEvent event )
{
try
{
if ( getCDIVariable() instanceof ErrorVariable )
{
getInternalVariable().invalidate();
setStatus( ICDebugElementErrorStatus.OK, null );
}
}
catch( CDIException e )
{
}
}