tweak IntReferences
diff --git a/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractIntReference.java b/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractIntReference.java
index 00f7789..b0e3d5e 100644
--- a/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractIntReference.java
+++ b/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractIntReference.java
@@ -95,8 +95,8 @@
 	// ********** standard methods **********
 
 	/**
-	 * Object identity is critical to int references.
-	 * There is no reason for two different int references to be
+	 * Object identity is critical to <code>int</code> references.
+	 * There is no reason for two different <code>int</code> references to be
 	 * <em>equal</em>.
 	 * 
 	 * @see #equals(int)
diff --git a/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractModifiableIntReference.java b/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractModifiableIntReference.java
index 3459308..5fe3759 100644
--- a/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractModifiableIntReference.java
+++ b/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/AbstractModifiableIntReference.java
@@ -195,7 +195,13 @@
 	}
 
 	public int swap(ModifiableIntReference other) {
+		if (other == this) {
+			return this.getValue();
+		}
 		int otherValue = other.getValue();
+		if (otherValue == this.getValue()) {
+			return this.getValue();
+		}
 		other.setValue(this.getValue());
 		this.setValue(otherValue);
 		return otherValue;
diff --git a/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/SimpleIntReference.java b/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/SimpleIntReference.java
index e1059ca..bf17d4c 100644
--- a/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/SimpleIntReference.java
+++ b/common/plugins/org.eclipse.jpt.common.utility/src/org/eclipse/jpt/common/utility/internal/reference/SimpleIntReference.java
@@ -276,8 +276,8 @@
 	}
 
 	/**
-	 * Object identity is critical to int references.
-	 * There is no reason for two different int references to be
+	 * Object identity is critical to <code>int</code> references.
+	 * There is no reason for two different <code>int</code> references to be
 	 * <em>equal</em>.
 	 * 
 	 * @see #equals(int)