#TUNING by stefan
authorStefan Vogel <sv@exept.de>
Fri, 16 Mar 2018 12:18:50 +0100
changeset 22622 b044b21ece42
parent 22621 ea38224ef388
child 22623 a4a3c7bfd522
#TUNING by stefan class: Collection changed: #firstOrNil
Collection.st
--- a/Collection.st	Fri Mar 16 11:45:00 2018 +0100
+++ b/Collection.st	Fri Mar 16 12:18:50 2018 +0100
@@ -366,8 +366,6 @@
     ^ self
 ! !
 
-
-
 !Collection methodsFor:'Compatibility-ANSI'!
 
 identityIncludes:anObject
@@ -724,10 +722,12 @@
      If it's empty, return nil.
      (i.e. don't trigger an error as done in #first)"
 
-    ^ self firstIfEmpty:nil
+    self isEmpty ifTrue:[^ nil].
+    ^ self first.
 
     "Created: / 04-06-2007 / 22:36:07 / cg"
     "Modified (comment): / 13-02-2017 / 19:58:28 / cg"
+    "Modified: / 16-03-2018 / 12:16:11 / stefan"
 !
 
 fourth