Commit 72302b4
committed
Merge pull request #5881 from rhuanjl:reviseJsSetModuleHostInfo
This change allows a nullptr to be supplied as requestModule in JsSetModuleHostInfo in order to use the currentContext when setting callbacks. This means that an embedder can setup module loading callbacks including the dynamic import from script callback without needing a throw away module record.
Note I have updated ch to use this new mechanism whilst leaving the native tests that use the old mechanism untouched so that both options are tested, one by ch and the other by the native tests.
CC: @liminzhu
closes #5875
File tree
3 files changed
+23
-17
lines changed- bin/ch
- lib/Jsrt
- Core
3 files changed
+23
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
419 | 419 | | |
420 | 420 | | |
421 | 421 | | |
422 | | - | |
| 422 | + | |
423 | 423 | | |
424 | 424 | | |
425 | 425 | | |
| |||
1130 | 1130 | | |
1131 | 1131 | | |
1132 | 1132 | | |
1133 | | - | |
1134 | | - | |
1135 | | - | |
1136 | | - | |
1137 | | - | |
1138 | | - | |
1139 | | - | |
1140 | | - | |
| 1133 | + | |
1141 | 1134 | | |
1142 | 1135 | | |
1143 | 1136 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
310 | 310 | | |
311 | 311 | | |
312 | 312 | | |
313 | | - | |
314 | | - | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
315 | 317 | | |
316 | 318 | | |
317 | 319 | | |
318 | 320 | | |
319 | 321 | | |
320 | 322 | | |
321 | 323 | | |
322 | | - | |
| 324 | + | |
323 | 325 | | |
324 | 326 | | |
325 | 327 | | |
326 | 328 | | |
327 | 329 | | |
328 | 330 | | |
329 | 331 | | |
330 | | - | |
| 332 | + | |
331 | 333 | | |
332 | 334 | | |
333 | 335 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
141 | | - | |
| 141 | + | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
| 145 | + | |
| 146 | + | |
145 | 147 | | |
146 | 148 | | |
147 | | - | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
148 | 161 | | |
149 | | - | |
150 | | - | |
151 | 162 | | |
152 | 163 | | |
153 | 164 | | |
| |||
0 commit comments