1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-07 17:56:01 +02:00

Do not allow to modify aggregate variables.

This commit is contained in:
Mikhail Khodjaiants 2002-09-17 17:55:26 +00:00
parent 3befb016c8
commit a83210a3a1

View file

@ -47,12 +47,15 @@ public abstract class CModificationVariable extends CVariable
{ {
try try
{ {
ICDIValue currentValue = getCurrentValue(); IValue value = getValue();
if ( currentValue != null ) if ( value != null && value instanceof ICValue )
{ {
return !( currentValue instanceof ICDIArrayValue || switch( ((ICValue)value).getType() )
currentValue instanceof ICDIStructureValue || {
currentValue instanceof ICDIStringValue ); case ICValue.TYPE_POINTER:
return true;
}
return !( value.hasVariables() );
} }
} }
catch( DebugException e ) catch( DebugException e )