system/src/sc/lang/SemanticNode.java
public boolean deepEquals(Object other) {
      if (other == this)
         return true;

      if (other == null)
         return false;

      if (getClass() != other.getClass())
         return false;

      DynType type = TypeUtil.getPropertyCache(getClass());
      IBeanMapper[] props = type.getSemanticPropertyList();
      for (int i = 0; i < props.length; i++) {
         Field field = (Field) props[i].getField();
         Object thisProp = PTypeUtil.getProperty(this, field, false);
         Object otherProp = PTypeUtil.getProperty(other, field, false);
         // If both are null it is ok.  If thisProp is not null it has to equal other prop to go on.
         if (thisProp != otherProp &&
                (thisProp == null || otherProp == null ||
                   !(thisProp instanceof ISemanticNode ? ((ISemanticNode) thisProp).deepEquals(otherProp) :
                           // If thisProp is a String and otherProp is an IString we need to compare it the other way around
                           (thisProp instanceof String ? otherProp.equals(thisProp) : thisProp.equals(otherProp))))) {
            return false;
         }
      }
      return true;
   }
/**
    * The semantic node classes are treated like value classes - they are equal if all of their properties
    * are equal.
    */
The semantic node classes are treated like value classes - they are equal if all of their properties
are equal.
The semantic node classes are treated like value classes - they are equal if all of their properties are equal .
public boolean deepEquals(Object other) {
      if (other == this)
         return true;
      if (other == null)
         return false;
      if (getClass() != other.getClass())
         return false;
      DynType type = TypeUtil.getPropertyCache(getClass());
      IBeanMapper[] props = type.getSemanticPropertyList();
      for (int i = 0; i < props.length; i++) {
         Field field = (Field) props[i].getField();
         Object thisProp = PTypeUtil.getProperty(this, field, false);
         Object otherProp = PTypeUtil.getProperty(other, field, false);
         if (thisProp != otherProp &&
                (thisProp == null || otherProp == null ||
                   !(thisProp instanceof ISemanticNode ? ((ISemanticNode) thisProp).deepEquals(otherProp) :
                           (thisProp instanceof String ? otherProp.equals(thisProp) : thisProp.equals(otherProp))))) {
            return false;
         }
      }
      return true;
   }
public boolean deepEquals ( Object other ) { if ( other == this ) return true ; if ( other == null ) return false ; if ( getClass ( ) != other . getClass ( ) ) return false ; DynType type = TypeUtil . getPropertyCache ( getClass ( ) ) ; IBeanMapper [ ] props = type . getSemanticPropertyList ( ) ; for ( int i = 0 ; i < props . length ; i ++ ) { Field field = ( Field ) props [ i ] . getField ( ) ; Object thisProp = PTypeUtil . getProperty ( this , field , false ) ; Object otherProp = PTypeUtil . getProperty ( other , field , false ) ; if ( thisProp != otherProp && ( thisProp == null || otherProp == null || ! ( thisProp instanceof ISemanticNode ? ( ( ISemanticNode ) thisProp ) . deepEquals ( otherProp ) : ( thisProp instanceof String ? otherProp . equals ( thisProp ) : thisProp . equals ( otherProp ) ) ) ) ) { return false ; } } return true ; }
The semantic node classes are treated like value classes - they are equal if all of their properties
 are equal.
The semantic node classes are treated like value classes - they are equal if all of their properties are equal .
// If both are null it is ok.  If thisProp is not null it has to equal other prop to go on. // If thisProp is a String and otherProp is an IString we need to compare it the other way around