Skip to content

Commit 52b97ef

Browse files
authored
Update docs for TEXTDECODE settings. NFC (#24698)
The behavior for pthreads was changed in #24349 but the docs were not updated.
1 parent 42a3b4d commit 52b97ef

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

site/source/docs/tools_reference/settings_reference.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2695,8 +2695,10 @@ TEXTDECODER
26952695
If enabled, use the JavaScript TextDecoder API for string marshalling.
26962696
Enabled by default, set this to 0 to disable.
26972697
If set to 2, we assume TextDecoder is present and usable, and do not emit
2698-
any JS code to fall back if it is missing. In single threaded -Oz build modes,
2699-
TEXTDECODER defaults to value == 2 to save code size.
2698+
any JS code to fall back if it is missing.
2699+
Note: In -Oz builds, the default value of TEXTDECODER is set to 2, to save on
2700+
code size (except when AUDIO_WORKLET is specified, or when `shell` is part
2701+
of ENVIRONMENT since TextDecoder is not available in those environments).
27002702

27012703
Default value: 1
27022704

src/settings.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1772,8 +1772,10 @@ var EVAL_CTORS = 0;
17721772
// If enabled, use the JavaScript TextDecoder API for string marshalling.
17731773
// Enabled by default, set this to 0 to disable.
17741774
// If set to 2, we assume TextDecoder is present and usable, and do not emit
1775-
// any JS code to fall back if it is missing. In single threaded -Oz build modes,
1776-
// TEXTDECODER defaults to value == 2 to save code size.
1775+
// any JS code to fall back if it is missing.
1776+
// Note: In -Oz builds, the default value of TEXTDECODER is set to 2, to save on
1777+
// code size (except when AUDIO_WORKLET is specified, or when `shell` is part
1778+
// of ENVIRONMENT since TextDecoder is not available in those environments).
17771779
// [link]
17781780
var TEXTDECODER = 1;
17791781

0 commit comments

Comments
 (0)