--- a/UninterpretedBytes.st Tue Nov 28 15:11:53 2017 +0100
+++ b/UninterpretedBytes.st Tue Nov 28 15:12:04 2017 +0100
@@ -4856,17 +4856,29 @@
sz := self size.
sz <= 32 ifTrue:[
- ^ self computeXorHashFrom:1 to:sz.
+ ^ self computeXorHashFrom:1 to:sz.
].
+
+ "/ the code below is actually not doing what was intended (to take the hashes of the first 16
+ "/ and the last 16 bytes.
+ "/ It does actually take the last 17 bytes (due to a mistake of the original programmer...)
+ "/ However, we will not change it, but keep it that way, in case the hashvalue already found
+ "/ its way into some dictionary (as key-index).
+ "/ It does not really hurt anyway, so there is no need to change it.
^ (sz bitXor:(self computeXorHashFrom:1 to:16)) bitXor:(self computeXorHashFrom:sz-16 to:sz)
"
- #[1 2 3 4] hash
- #[1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4
- 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 ] hash
- #[1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4
- 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1] hash
- "
+ #[1 2 3 4] hash
+ #[1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 ] hash
+
+ #[1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4
+ 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 ] hash
+
+ #[1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4
+ 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1 2 3 4 1] hash
+ "
+
+ "Modified (format): / 28-11-2017 / 15:03:36 / cg"
! !
!UninterpretedBytes methodsFor:'image manipulation support'!