Skip to content

Commit c67256b

Browse files
committed
Use <<< >>> as late-replacement pattern for MINIMAL_RUNTIME. NFC
See #13265
1 parent e74e0af commit c67256b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

emscripten.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,10 @@ def compute_minimal_runtime_initializer_and_exports(post, exports, receiving):
4949
if shared.Settings.DYNCALLS and '$dynCall' in shared.Settings.DEFAULT_LIBRARY_FUNCS_TO_INCLUDE and len([x for x in exports_that_are_not_initializers if x.startswith('dynCall_')]) > 0:
5050
exports_that_are_not_initializers += ['dynCalls = {}']
5151

52-
post = post.replace('/*** ASM_MODULE_EXPORTS_DECLARES ***/', 'var ' + ',\n '.join(exports_that_are_not_initializers) + ';')
52+
post = post.replace('<<< ASM_MODULE_EXPORTS_DECLARES >>>', 'var ' + ',\n '.join(exports_that_are_not_initializers) + ';')
5353

5454
# Generate assignments from all asm.js/wasm exports out to the JS variables above: e.g. a = asm['a']; b = asm['b'];
55-
post = post.replace('/*** ASM_MODULE_EXPORTS ***/', receiving)
55+
post = post.replace('<<< ASM_MODULE_EXPORTS >>>', receiving)
5656
return post
5757

5858

src/postamble_minimal.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ function loadWasmModuleToWorkers() {
120120
#endif
121121

122122
#if DECLARE_ASM_MODULE_EXPORTS
123-
/*** ASM_MODULE_EXPORTS_DECLARES ***/
123+
<<< ASM_MODULE_EXPORTS_DECLARES >>>
124124
#endif
125125

126126
#if MINIMAL_RUNTIME_STREAMING_WASM_INSTANTIATION
@@ -196,7 +196,7 @@ WebAssembly.instantiate(Module['wasm'], imports).then(function(output) {
196196
#if !DECLARE_ASM_MODULE_EXPORTS
197197
exportAsmFunctions(asm);
198198
#else
199-
/*** ASM_MODULE_EXPORTS ***/
199+
<<< ASM_MODULE_EXPORTS >>>
200200
#endif
201201
wasmTable = asm['__indirect_function_table'];
202202
#if ASSERTIONS

0 commit comments

Comments
 (0)