Skip to content

Commit 96124ff

Browse files
authored
Feedback from #21406. NFC (#21415)
1 parent f302d4c commit 96124ff

16 files changed

+22
-18
lines changed

src/library.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3555,9 +3555,8 @@ addToLibrary({
35553555

35563556
$HandleAllocator: class {
35573557
constructor() {
3558-
// TODO(sbc): Use class fields once we allow/enable es2022 in
3559-
// JavaScript input to acorn and closure.
3560-
// Reserve slot 0 so that 0 is always an invalid handle
3558+
// TODO(https://github.com/emscripten-core/emscripten/issues/21414):
3559+
// Use inline field declarations.
35613560
this.allocated = [undefined];
35623561
this.freelist = [];
35633562
}

src/library_fs.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,13 @@ FS.staticInit();` +
9999

100100
FSStream: class {
101101
constructor() {
102+
// TODO(https://github.com/emscripten-core/emscripten/issues/21414):
103+
// Use inline field declarations.
102104
this.shared = {};
103105
#if USE_CLOSURE_COMPILER
106+
// Closure compiler requires us to declare all properties in the
107+
// constructor.
104108
this.node = null;
105-
this.flags = 0;
106109
#endif
107110
}
108111
get object() {
@@ -1652,6 +1655,8 @@ FS.staticInit();` +
16521655
this.lengthKnown = false;
16531656
this.chunks = []; // Loaded chunks. Index is the chunk number
16541657
#if USE_CLOSURE_COMPILER
1658+
// Closure compiler requires us to declare all properties in the
1659+
// constructor.
16551660
this.getter = undefined;
16561661
this._length = 0;
16571662
this._chunkSize = 0;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
9887
1+
9883
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
24323
1+
24310
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
9870
1+
9866
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
24291
1+
24278
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
10971
1+
10968
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
28195
1+
28182
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
9854
1+
9850
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
24217
1+
24204
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
10982
1+
10979
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
28196
1+
28183
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
9887
1+
9883
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
24323
1+
24310
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
7843
1+
7840
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
19352
1+
19339

0 commit comments

Comments
 (0)