|
@@ -1153,6 +1153,27 @@ referencedClasses: []
|
|
|
}),
|
|
|
smalltalk.IndexableCollection);
|
|
|
|
|
|
+smalltalk.addMethod(
|
|
|
+smalltalk.method({
|
|
|
+selector: "at:ifAbsentPut:",
|
|
|
+protocol: 'accessing',
|
|
|
+fn: function (aKey,aBlock){
|
|
|
+var self=this;
|
|
|
+return smalltalk.withContext(function($ctx1) {
|
|
|
+var $1;
|
|
|
+$1=self._at_ifAbsent_(aKey,(function(){
|
|
|
+return smalltalk.withContext(function($ctx2) {
|
|
|
+return self._at_put_(aKey,_st(aBlock)._value());
|
|
|
+}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
|
|
|
+return $1;
|
|
|
+}, function($ctx1) {$ctx1.fill(self,"at:ifAbsentPut:",{aKey:aKey,aBlock:aBlock},smalltalk.IndexableCollection)})},
|
|
|
+args: ["aKey", "aBlock"],
|
|
|
+source: "at: aKey ifAbsentPut: aBlock\x0a\x09^ self at: aKey ifAbsent: [\x0a\x09\x09self at: aKey put: aBlock value ]",
|
|
|
+messageSends: ["at:ifAbsent:", "at:put:", "value"],
|
|
|
+referencedClasses: []
|
|
|
+}),
|
|
|
+smalltalk.IndexableCollection);
|
|
|
+
|
|
|
smalltalk.addMethod(
|
|
|
smalltalk.method({
|
|
|
selector: "at:ifPresent:",
|
|
@@ -1474,27 +1495,6 @@ referencedClasses: []
|
|
|
}),
|
|
|
smalltalk.HashedCollection);
|
|
|
|
|
|
-smalltalk.addMethod(
|
|
|
-smalltalk.method({
|
|
|
-selector: "at:ifAbsentPut:",
|
|
|
-protocol: 'accessing',
|
|
|
-fn: function (aKey,aBlock){
|
|
|
-var self=this;
|
|
|
-return smalltalk.withContext(function($ctx1) {
|
|
|
-var $1;
|
|
|
-$1=self._at_ifAbsent_(aKey,(function(){
|
|
|
-return smalltalk.withContext(function($ctx2) {
|
|
|
-return self._at_put_(aKey,_st(aBlock)._value());
|
|
|
-}, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
|
|
|
-return $1;
|
|
|
-}, function($ctx1) {$ctx1.fill(self,"at:ifAbsentPut:",{aKey:aKey,aBlock:aBlock},smalltalk.HashedCollection)})},
|
|
|
-args: ["aKey", "aBlock"],
|
|
|
-source: "at: aKey ifAbsentPut: aBlock\x0a\x09^ self at: aKey ifAbsent: [\x0a\x09\x09self at: aKey put: aBlock value ]",
|
|
|
-messageSends: ["at:ifAbsent:", "at:put:", "value"],
|
|
|
-referencedClasses: []
|
|
|
-}),
|
|
|
-smalltalk.HashedCollection);
|
|
|
-
|
|
|
smalltalk.addMethod(
|
|
|
smalltalk.method({
|
|
|
selector: "at:ifPresent:ifAbsent:",
|