made sure map() doesn't mutate internal list linked-ness

pull/95/head
jmoenig 2020-12-01 13:41:37 +01:00
rodzic 7a110b7e2c
commit 5ea2a0af9c
3 zmienionych plików z 4 dodań i 3 usunięć

Wyświetl plik

@ -24,6 +24,7 @@
* blocks: made pen attributes menus static
* blocks: made sensing attributes menus largely static
* threads: changed reportVideo() to be hyper-monadic
* lists: made sure map() doesn't mutate internal list linked-ness
### 2020-11-30
* threads: keep internal linked-list organization intact for hyperblocks

Wyświetl plik

@ -13,7 +13,7 @@
<script src="src/objects.js?version=2020-12-01"></script>
<script src="src/gui.js?version=2020-12-01"></script>
<script src="src/paint.js?version=2020-05-17"></script>
<script src="src/lists.js?version=2020-07-01"></script>
<script src="src/lists.js?version=2020-12-01"></script>
<script src="src/byob.js?version=2020-11-27"></script>
<script src="src/tables.js?version=2020-10-06"></script>
<script src="src/sketch.js?version=2020-07-13"></script>

Wyświetl plik

@ -63,7 +63,7 @@ MorphicPreferences, TableDialogMorph, SpriteBubbleMorph, SpeechBubbleMorph,
TableFrameMorph, TableMorph, Variable, isSnapObject, Costume, contains, detect,
ZERO, WHITE*/
modules.lists = '2020-July-01';
modules.lists = '2020-December-01';
var List;
var ListWatcherMorph;
@ -211,7 +211,7 @@ List.prototype.clear = function () {
List.prototype.map = function(callback) {
return new List(
this.asArray().map(callback)
this.itemsArray().map(callback)
);
};