WeakArray.st
branchjv
changeset 18120 e3a375d5f6a8
parent 18045 c0c600e0d3b3
parent 16397 94b58be4d23e
child 18608 7d521f25267c
--- a/WeakArray.st	Tue Feb 04 21:09:59 2014 +0100
+++ b/WeakArray.st	Wed Apr 01 10:20:10 2015 +0100
@@ -258,6 +258,16 @@
     "Modified: 25.1.1997 / 13:41:25 / cg"
 !
 
+at:index ifAbsent:exceptionValue
+    "return the indexed instance variable with index, anInteger,
+     or exceptionValue if the index is invalid.
+     Reimplemented here for IGC readBarrier.
+     (You dont have to understand this.)"
+
+    (index < 0 or:[index > self size]) ifTrue:[^ exceptionValue].
+    ^ self at:index
+!
+
 at:index ifInvalid:exeptionalValue
     "return the indexed instance variable with index, anInteger,
      but only if still valid; otherwise return the value from exceptionalValue"
@@ -1017,11 +1027,11 @@
 !WeakArray class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/WeakArray.st,v 1.69 2013-04-16 12:46:35 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/WeakArray.st,v 1.70 2014-05-06 14:45:50 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libbasic/WeakArray.st,v 1.69 2013-04-16 12:46:35 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/WeakArray.st,v 1.70 2014-05-06 14:45:50 cg Exp $'
 ! !