2023-07-05 [02:04:16.0414] [The September Tokyo plenary invite](https://github.com/tc39/Reflector/issues/499) is now posted on the Reflector. If anyone needs support on visas (e.g. generating an invite letter from the host), please let me know. It is just under 12 weeks away. [04:56:12.0750] Note that we are working on a community event the evening before, on the 25th. [07:20:55.0627] oops i didn't see this before, thanks for this! i actually didn't mean to include that slide, ha! [12:13:57.0838] https://github.com/tc39/agendas/pull/1423 โ˜๏ธ this is a low-stakes change, but would be nice to get some more blessings on it 2023-07-06 [01:59:18.0773] https://docs.google.com/presentation/d/1m5R5J98W6adegghgkAlbSuFgAYJDT52yyFVdAqLjm00/edit#slide=id.geaea8d83af_0_4 [01:59:27.0695] https://github.com/tc39/proposal-iterator.range/issues/60 https://tc39.es/proposal-iterator.range/#sec-create-numeric-range-iterator [01:59:35.0049] also in Iterator.range [10:01:29.0622] https://github.com/tc39/proposal-integer-and-modulus-math appears to have Issues turned off so I can't comment on it. littledan ? [10:20:05.0849] they're on afaict [10:20:12.0632] * they're on afaict - https://github.com/tc39/proposal-integer-and-modulus-math/issues [10:20:26.0139] * TabAtkins: they're on afaict - https://github.com/tc39/proposal-integer-and-modulus-math/issues [10:21:04.0036] Wth, nothing was there on my desktop 2023-07-09 [05:06:20.0083] Do we already have a matrix room for the in-person participants to the meeting? [05:09:04.0578] I don't think so [05:15:50.0048] Please create one, Nicolo! [10:43:59.0133] nicolo-ribaudo: can you link the room here or send me an invite? [10:55:31.0958] You already joined it some hours ago ๐Ÿ˜… [11:09:18.0673] I am so confused [11:09:52.0993] I have been in transit for far too long [11:11:37.0939] I literally thought I imagined that lmao 2023-07-10 [00:47:17.0133] wait 10am in Oslo is 5pm in Tokyo? [00:47:19.0423] wild [03:50:50.0254] Sorry if this is a basic element/matrix question, but how do I join the TC39 space, like the thing that organizes all of the TC39 rooms into one view? [03:51:45.0811] https://matrix.to/#/#tc39-space:matrix.org try this [03:51:55.0289] https://matrix.to/#/#tc39-space:matrix.org [04:30:05.0188] Well, it looks like that should work, but my element client just spins on `loading` for 30 minutes :/ I'll try again later. [05:51:59.0214] Is anyone available to dial into zoom to help confirm AV in 20 mins time? [06:00:12.0717] I'll try the zoom from the hotel Wi-fi [06:08:35.0032] Thanks, Ashley [06:10:14.0035] ping me a link when you're ready [06:54:05.0941] Works now, thanks for the help :) [15:42:13.0216] Chairs: Any concern if I extend the timebox for the Explicit Resource Management update by 15 minutes to cover a suggestion that came up last week? The schedule currently calls for a 15 minute underflow on the day/time I'm currently scheduled to present. If that's not feasible, I'll see what I can squeeze in in the time I have available and offer to discuss further with interested parties after the plenary. 2023-07-11 [18:25:52.0330] rbuckton: you got it [00:31:33.0476] The sign-in form is now posted if you wish to dial into the Zoom for today's plenary: https://github.com/tc39/Reflector/issues/473 [00:49:58.0332] Please could someone attempt dial in so we can confirm AV is working [01:01:52.0052] it's working [01:02:02.0596] * it's working (zoom web) [01:18:25.0714] huh, "OramaSearch" is new to me; any delegates from them here today? [01:18:36.0784] Michele Riva is the delegate, I think? [01:18:45.0192] yeah [01:18:52.0250] it's a new org [01:20:03.0996] i found the voice quality is bad... i need more effort to heard what are the meetings talking about [01:28:58.0433] Jack Works: is it one person's voice quality? [01:31:46.0692] > <@robpalme:matrix.org> Jack Works: is it one person's voice quality? it's the in-person one [01:32:59.0612] The whole room is "hot". Meaning all mics on the whole time. So we need everyone to avoid noise unless they are speaking, e.g. placing cups down gently. [01:34:37.0740] Rob Palmer: Although it would be possible to mute each mic directly, because they have a direct mute button. [01:35:40.0179] That is a good point - lets try using that [01:41:53.0253] Yeah, this does look nicer! Thanks editors [01:44:57.0772] tcq does indeed appear to be down [01:45:04.0842] chaos :( [01:46:45.0808] I don't even know what to do without TCQ anymore [01:47:12.0593] we are now 100% dependent [01:47:13.0374] A google doc with someone manually sorting the items by priority? [01:47:54.0823] current discussion is not audible remotely [01:48:30.0154] Sorry! We forgot to unmute; it was about missing conclusions. [01:49:42.0120] Just give us a nod and we will signal, unmute. [01:52:40.0196] is TCQ still just running off of some Azure account Brian is expensing? [01:54:16.0507] bakkot: Looks so -> https://github.com/bterlson/tcq/blob/b5be1287a6843f24dc570c1d951d1c26ac566d66/src/server/db.ts#L1C14-L1C18 [01:55:49.0783] why is #783 being done as a needs-consensus PR and not a staged proposal? [02:00:32.0459] I don't think it's that useful to make things like this optional? [02:00:41.0029] at least not optional for web browsers [02:00:50.0660] as a programmer I am going to want to rely on their existence [02:00:55.0438] +1 [02:01:11.0604] and as a user I'm going to be annoyed if the page behaves differently in my browser than the one the developer was using [02:01:57.0939] but when it comes to internationalization, that's bound to happen, right? [02:02:05.0159] I mean, I totally agree with the general sentiment [02:02:54.0023] ... is it? [02:03:01.0769] bakkot: ligatures and opentype features are optional; that doesn't make a font not useful [02:03:25.0043] > <@usharma:igalia.com> but when it comes to internationalization, that's bound to happen, right? well, we still try to limit the scope of this [02:03:36.0561] > <@bakkot:matrix.org> ... is it? it is because different browsers make different tailorings of the data [02:05:32.0991] sffc: Can you link to that PR for number format for the notes? [02:05:45.0188] oops it's in TCQ [02:05:46.0250] https://github.com/tc39/proposal-intl-numberformat-v3/pull/130 [02:09:01.0571] > <@michaelficarra:matrix.org> I don't even know what to do without TCQ anymore There is a defined backup plan involving a spreadsheet. [02:09:27.0488] good to hear! [02:10:25.0322] someone is typing surprisingly loudly? [02:10:29.0927] does import attr support boolean values? [02:10:55.0269] I think it may be ryzokuken ๐Ÿ‡ณ๐Ÿ‡ด aggressively typing. [02:11:16.0168] > <@haxjs:matrix.org> does import attr support boolean values? no [02:11:25.0796] I think it is littledan just surprisingly close to the mic [02:11:52.0528] Is someone typing on an open mic? [02:12:20.0835] sorry that may be me. Is it fixed now? [02:12:25.0935] (I moved off of the table) [02:12:38.0389] there are not currently typing noises [02:13:34.0084] > <@jackworks:matrix.org> no If support boolean I would like it also support `null` :) [02:14:16.0015] HE Shi-Jun: Jack Works: I would oppose that because I want to keep a future open where we do not ToString these value [02:15:17.0439] yeah I like keeping the restrictions tight until there are concrete things we want to loosen them for [02:15:52.0249] definitely I can imagine features where we'd want `true`, `false`, `null` etc but I think we can come back when that's relevant? [02:15:55.0320] we do ToString for attribute values now? [02:16:05.0743] otoh I guess this is partially for bundlers to build out there own things so maybe that doesn't make sense [02:34:23.0743] I support auto deferral in this case, but I don't want this or iterators to be considered precedent to justify auto deferring in future proposals [02:43:02.0107] could someone remind me what "hint" means in this context? [02:43:15.0233] it's an alias in the spec [02:43:15.0834] it means "flag" in practice [02:43:19.0440] it's a silly name [02:43:35.0402] it's used in places where we provide an AO with context about its use [02:44:18.0802] so it's not something specific to the syntax for Explicit Resource Management, then. Thanks [02:44:33.0013] yeah, I always assumed that it was a contextual hints from the caller, as in toPrimitive [02:44:34.0259] correct, entirely spec internal [02:44:45.0428] * yeah, I always assumed that it was a contextual hint from the caller, as in toPrimitive [02:44:46.0996] > <@bradfordcsmith:matrix.org> so it's not something specific to the syntax for Explicit Resource Management, then. Thanks Well, in this specific case the hint is whether we are using `using` or `await using` [02:45:18.0103] hmm, I would've said the word "context" is better but at this point it's so overloaded that it's probably not [02:45:50.0132] same with "flag" [02:48:39.0885] ptomato (at TC39, limited availability): It is not possible unless we want all the `const` and `let` declaration to perform property access [02:52:05.0891] or if we change the semantics of `using`, like suggested here [02:52:16.0159] > <@nicolo-ribaudo:matrix.org> ptomato (at TC39, limited availability): It is not possible unless we want all the `const` and `let` declaration to perform property access Oh well, the resource could throw if it's used before accessing its `[Symbol.dispose]` property [02:52:49.0591] that's kinda cute actually [02:53:04.0025] And also, it is totally reasonable to move around disposables using `let` or `const`, before passing it to a `using` [02:53:08.0261] but probably confusing [02:53:25.0187] if we want to seriously consider Symbol.enter, we should demote this proposal to Stage 2 [02:55:58.0663] > <@lucacasonato:matrix.org> And also, it is totally reasonable to move around disposables using `let` or `const`, before passing it to a `using` I don't quite understand how you envision this [02:56:18.0885] littledan: I think it works fine as a follow-on [02:58:48.0537] this is not the kind of thing that will be good to have a compatibility matrix around. It's also not some complicated uncertain technology--we know the design space already. [03:00:11.0620] littledan: Are you concerned about avoiding a future where some disposables are wrapper objects that pseudo-enforce use of `using` and some are not? [03:00:45.0616] it will be annoying to have to reason about different possible ways that this protocol could be implemented, in general. Possible, but annoying [03:01:33.0965] Queue: Reply: Concern with disposers that throw exception in GC for embeddings Philip Chimento 2 New Topic: I am not in favour of recommending GC based cleanup. Should -> may? Luca Casonato (@denoland) 3 New Topic: Is it possible to enforce use of `using` in the language, rather than in tooling Philip Chimento 4 New Topic: Test sanitizers can be used to help with this Luca Casonato (@denoland) 5 New Topic: I support looking into the @@enter/@@asyncEnter, possibly part of this proposal. Michael Saboff [03:02:16.0960] thanks, could we perhaps also put this in the notes so we have a copy stored? [03:03:53.0942] is tcq.app down for anyone else? The console says ``` WebSocket connection to '' failed: WebSocket is closed before the connection is established. wKFO:1 Unchecked runtime.lastError: The message port closed before a response was received. ``` [03:04:03.0581] yeah, it's down again [03:09:53.0928] To clarify, I am fine with not providing a recommendation to ensure cleanup if a disposable is dropped on the floor, regardless as to the practice in other languages. It was brought up in #159 as one of the concerns about dropping a disposable is that native handles that are usually just tracked by a `number` value can leak and are not visible in a heap dump. [03:11:23.0275] That said, it is feasible to implement a "cleanup on GC" behavior using `FinalizationRegistry` in user code if needed, given that's one of `FinalizationRegistry`'s use cases, and such behavior already exists in NodeJS for many native handles. [03:24:49.0138] Regarding the `Symbol.enter` suggestion, I have been considering the following as a follow-on proposal: `Symbol.enter` (or `Symbol.enterContext`?) - indicates a method that, when invoked, enters a context and returns a value associated with that context. This method is optional, and if missing is implicitly handled as if the definition was: ``` [Symbol.enter]() { return this; } ``` `Symbol.exit` (or `Symbol.exitContext`?) - indicates a method that is invoked when the context is exited at the end of the block. Receives two arguments, `hasError` and `error`, that indicate whether an exception occurred prior to context exit. The method may return `true` to inform the caller not to throw `error` (swallowing the exception). Any other return value is ignored, indicating the caller should throw `error`. The method may also choose to throw its own error, but should not throw `error` itself. This method is also optional, and if missing is implicitly handled as if the definition was: ``` [Symbol.exit](hasError, error) { try { this[Symbol.dispose](); } catch (e) { if (hasError) { throw new SuppressedError(e, error); } else { throw e; } } return undefined; } ``` Thus, `[Symbol.dispose]()` on its own would constitute a lightweight context manager. [03:28:48.0847] Things do become more complex for async context managers, however, given that they must `await` the result of `[Symbol.asyncEnter]()` if we were to adhere to the Python design. `await using x = y` would potentially Await twice: once at the declaration site in the presence of a `[Symbol.asyncEnter]()` method, and once at the end of the block for the `[Symbol.asyncExit]()` or `[Symbol.asyncDispose]()` call. [03:31:45.0193] Finally, `AsyncDisposableStack.prototype.use` becomes *slightly* more complicated as it may return a `Promise` if the resource that is passed to `use` is an async context manager. `use` itself doesn't necessarily need to become async, however, since all it needs to do is return the result of calling `[Symbol.asyncEnter]()`. If you were to pass in a sync context or a disposable, it would not need to return a `Promise`. [03:32:56.0584] Context managers are extremely powerful, but also extremely complex, which is why I have been reticent to consider them for this proposal. [03:36:08.0463] I also didn't want the general purpose `[Symbol.dispose]` behavior to be complicated by the error handling and error suppression semantics of `__exit__`, as the majority of cases related to resource management have no need of that complexity. [04:08:10.0949] you may come back ljharb Chris de Almeida [04:08:13.0713] Please return to the Zoom [04:10:08.0221] > <@usharma:igalia.com> I don't quite understand how you envision this ```js const resource = createResource() promises.push(doSomethingWithResource(resource)); async function doSomethingWithResource(resource) { using r = resource; ... } `` [04:10:15.0808] > <@usharma:igalia.com> I don't quite understand how you envision this * ```js const resource = createResource() promises.push(doSomethingWithResource(resource)); async function doSomethingWithResource(resource) { using r = resource; ... } ``` [04:19:44.0993] littledan: My preferred source-maps scope change would be to expand the two "including ECMAScript code" mentions to be something like "including CSS and ECMAScript code". [04:21:49.0741] -> https://notlaura.com/is-css-turing-complete/ [04:28:06.0197] Thank you for ensuring that the CoC Committee member list is accurate [04:28:08.0901] with the pruning [04:28:12.0080] and thanks to new volunteers [04:34:55.0982] The delegate's organization is not listed in https://github.com/tc39/notes/blob/main/delegates.txt. Is that information available somewhere? [04:35:37.0309] We are divided in teams in the tc39 GH org based on our org [04:35:41.0292] * We are divided in teams in the tc39 GH org based on our organization [04:35:43.0747] * We are divided in teams in the tc39 GH org based on our organizations [04:36:25.0754] Example: https://github.com/orgs/tc39/teams/member-igalia [04:36:49.0356] Thanks for that reminder. I still don't really know how to "look up" the information that way. I mean go from name/abbreviation -> organization [04:37:01.0761] so, the public calendar email address to invite will be shared with the committee to make events public? [04:37:37.0280] Bradford Smith: type their name here: https://github.com/orgs/tc39/teams/eligible-meeting-participants?query=membership%3Achild-team [04:44:09.0800] yes [04:45:02.0712] I'm confused, don't only the chairs have edit access? [04:45:22.0193] the public calendar is managed by way of the private calendar [04:45:43.0664] yes, I mean edit access to the private calendar [04:45:52.0817] no, we can all edit the private calendar [04:46:01.0136] not everyone can edit it [04:46:07.0997] several people have permission though [04:46:18.0736] https://github.com/tc39/how-we-work/issues/94#issuecomment-1518375862 [04:46:38.0625] calendar id there is the address to invite the public calendar to a private calendar meeting [04:47:01.0032] as discussed, we will place this information in a more accessible place rather than buried in a GH issue [04:48:22.0110] we should document some points of contact who have edit access so it's not ambiguous who to contact when needing to make calendar updates [04:48:55.0502] at the very least the chairs, but other folks with edit access may be willing to make themselves available for this purpose [04:49:06.0971] i've been fielding calendar update requests for awhile [04:49:31.0461] I think the admin role is perfect for this tbh [04:49:33.0674] * i've been fielding calendar update requests for awhile fwiw [04:49:52.0354] so it makes sense for you to be among the listed contacts ljharb [04:49:54.0835] maybe we should give edit access somewhat more broadly? [04:50:16.0756] I don't really see why I should have more access than others [04:50:32.0879] I think we have a high enough degree of trust within the committee to share edit access to the calendar more broadly, yes [04:50:48.0997] like the calendar edit permission is not really that critical now that I think about it [04:50:50.0081] that said, calendar management can be tricky and it's really easy to accidentally fire off dozens of email notifications [04:51:01.0635] true [04:51:02.0722] * that said, calendar management can be tricky and it's really easy to accidentally fire off dozens of email notifications, and there's no audit log to restore deleted events [04:51:36.0474] > <@ljharb:matrix.org> that said, calendar management can be tricky and it's really easy to accidentally fire off dozens of email notifications, and there's no audit log to restore deleted events In fact it looks like the source map meetings might've been randomly deleted or something [04:52:07.0727] oof, ping me with the deets you want and i'll be happy to set it back up [04:52:32.0144] > <@ljharb:matrix.org> that said, calendar management can be tricky and it's really easy to accidentally fire off dozens of email notifications, and there's no audit log to restore deleted events I guess that makes sense given that those operations are not actually part of the calendar protocol [04:52:49.0996] yeah I'm fine with delegating the calendar management as long as the people are decently responsive [04:52:52.0625] the calendar protocol is weird actually, but maybe you have some degree of a backlog in your emails [04:53:07.0891] or CalDAV [04:54:08.0837] source maps still on my calendar, but not on the tc39 calendar [04:54:33.0292] it's 2023 and calendaring is still in the dark ages [04:54:46.0907] TG5: Calendar Spec [04:55:29.0626] Chris de Almeida: 100% seriously I've been thinking about it a lot lately [04:55:34.0242] and trying to fix that somewhat [04:56:05.0939] I'd support you [04:57:42.0176] littledan: so actually for the loop bound recomputation bugs there are already tests AFAICT [04:58:09.0969] (marja implemented and wrote the tests for them, but i didn't correctly fix the spec draft) [04:58:14.0402] syg: I wonder if throwing if there was a concurrent too-large grow makes sense, since if the concurrent grow happens just after this thread's grow returns, you'd still have a too-large buffer when you try to use it [04:58:18.0684] the only one missing is the detach timing [04:58:46.0734] * shu: I wonder if throwing if there was a concurrent too-large grow makes sense, since if the concurrent grow happens just after this thread's grow returns, you'd still have a too-large buffer when you try to use it [04:58:47.0436] Andreu Botella: you mean throwing if there is _any_ race? [04:59:18.0103] i don't think so, because racing for too-large cannot be reliably detected [04:59:37.0176] no, I mean you'd still have a race in user code if the concurrent grow happens just a bit too late [04:59:46.0784] right, you can't detect that [04:59:57.0035] so why try to detect it inside the loop? [05:00:15.0695] well, I guess you'd have to detect it anyway, but why throw [05:00:24.0443] the race inside the loop is for the opposite case, where grow(10) races with grow(20) [05:00:32.0321] https://github.com/tc39/proposal-array-grouping/issues/57 [05:00:35.0443] and grow(20) happens first, and grow(10) is now a shrink [05:00:38.0615] and is disallowed [05:00:49.0337] it's throwing not because of a race per se, it's throwing because shrinks already throw [05:01:07.0247] you could have it silently do nothing, that's a possibility [05:01:09.0094] After a grow, you know the SAB is *at least* the size you've grown it too [05:01:15.0527] so I'm not thinking of the grow(10) as a shrink [05:01:21.0051] maybe a user might [05:01:32.0322] * maybe a user might though [05:02:05.0767] that's fair, this could be relaxed, but it's shipped with these semantics already and i don't feel particularly compelled to change it [05:02:13.0487] oh, right, a slightly-too-late grow(10) would indeed throw [05:02:21.0297] that makes sense then [05:02:22.0007] the actual answer is just... don't race your grows [05:02:23.0926] synchronize another way [05:03:16.0858] I understand that but given the level of abstraction we work on, couldn't we do a bit of hand holding here? [05:03:36.0345] make it a bit harder to run into this issue to begin with to whatever extent we can [05:04:07.0424] > <@shuyuguo:matrix.org> that's fair, this could be relaxed, but it's shipped with these semantics already and i don't feel particularly compelled to change it oh, this is quite compelling, nvm [05:04:27.0025] > <@usharma:igalia.com> I understand that but given the level of abstraction we work on, couldn't we do a bit of hand holding here? yeah I think this is generally not the right kind of thing to do with low-level concurrency primitives [05:05:11.0115] So, should we have a brief overflow topic to get through the conditionality? [05:05:20.0725] if msaboff expects to review it tonight [05:05:59.0809] it has not really been helpful to replace what we were calling "conclusion" with "summary". The idea was to be more detailed. [05:06:17.0467] agreed with littledan, i think hand-holding lock-free concurrency stuff is just not a good idea [05:06:18.0216] we've had a conclusion for a long time [05:07:01.0905] the request from this morning is just that we don't forget to add a conclusion [05:07:56.0271] this is false. The request from Ecma has been to add summaries. We had been adding conclusions previously. [05:08:23.0330] I'm really confused by the resistance from the committee to summaries. I really think they would make the notes more accessible. [05:08:42.0882] the idea is to cover the main points in the presentation and discussion, not only the things we got consensus on [05:09:08.0246] if a delegate doesn't want to write a summary, that's OK, but I don't understand why they should oppose others writing summaries... [05:10:49.0452] i don't recall any opposition to someone just going in and adding a summary - i thought the opposition was just to pausing the meeting and/or asking champions to write a summary [05:11:07.0858] * i don't recall any opposition to someone just going in and adding a summary - i thought the opposition was just to pausing the meeting and/or asking champions to write a summary, but maybe i'm not remembering right [05:21:34.0330] the summaries (with or without a conclusion) are very helpful. it takes only a moment for the speaker to dictate a summary. I don't think there's a lot of controversy with this, but in the past IIRC it was only because it was perceived to take up too much committee time. but I think that was also when we were sitting there waiting for the speaker (or someone else) to type up the summary, whereas it should just be dictated, which should only take a moment, and can be cleaned up async as needed [05:22:45.0343] so yes, Jordan is right that it was in opposition to pausing the meeting. it's such a small sacrifice though and is a lot easier to do when it's timely [05:24:23.0552] but 100% almost every time in recent memory where I needed to refer to meeting notes, it was so helpful to have those summaries rather than having to scour the entire dialog [05:24:31.0004] * 100% almost every time in recent memory where I needed to refer to meeting notes, it was so helpful to have those summaries rather than having to scour the entire dialog [05:38:44.0161] syg: The profile ^^ [05:43:01.0547] ljharb: if you don't use namespace imports, you will have effects triggered on reading a local [05:43:11.0229] reading a local shouldn't have an effect [05:44:48.0092] i agree with that [05:45:08.0092] that doesn't mean `import *` is any more palatable tho [05:45:23.0883] > <@ljharb:matrix.org> that doesn't mean `import *` is any more palatable tho Do you have any other suggestions? [05:45:44.0068] > <@michaelficarra:matrix.org> reading a local shouldn't have an effect `with` would like a word /s [05:46:05.0684] "why not `with` but *everywhere*?" [05:46:47.0664] I don't understand current page... [05:47:16.0716] > <@littledan:matrix.org> Do you have any other suggestions? no, the design goals of ESM didn't really leave many options here i can see :-/ [05:47:38.0436] > <@michaelficarra:matrix.org> reading a local shouldn't have an effect but imported variable isn't a local. [05:47:47.0719] sure it is [05:47:58.0622] like it could be `import with` instead of `import defer`? [05:48:01.0096] personally i think some magic like `with` is acceptable in this specific case :) [05:48:03.0070] altho it's slightly different in that its value can change out from under you [05:48:15.0287] * altho it's slightly different in that its value can change out from under you if the export is a `let` that's reassigned [05:48:30.0539] > <@ljharb:matrix.org> no, the design goals of ESM didn't really leave many options here i can see :-/ I don't really understand why the namespace restriction is fatal, but I guess you'll explain in your queue item? [05:48:46.0419] i didn't say it was fatal. but yes, i will [05:48:58.0855] * i didn't say it was fatal. but yes, i will elaborate on my queue item [05:49:09.0148] * like it could be `import with` instead of `import defer`? (joking) [05:49:31.0238] * i didn't say it was fatal. but yes, i will elaborate on my queue item (i just combined my two into one) [05:49:38.0708] I support allowing `import defer { ... }`, we have already using it by the webpack implementation and we found enforcing a namespace is somewhat a bad DX . [05:50:25.0662] in our use at Bloomberg, we've found that the restriction to a namespace is a little annoying but not really that bad [05:50:58.0852] bakkot: adding TLA to a module is already a breaking change i think [05:51:07.0360] the more significant thing is the decision about whether to include deferred * re-exports (coming later in the slides, proposed to discuss during stage 2) [05:51:10.0177] > <@lucacasonato:matrix.org> sent an image. is the second column milliseconds? [05:51:18.0316] > <@ljharb:matrix.org> bakkot: adding TLA to a module is already a breaking change i think well. ot [05:51:33.0009] > <@ljharb:matrix.org> bakkot: adding TLA to a module is already a breaking change i think * well. it's observable but it's intended to not be quite breaking [05:52:02.0676] > <@danielrosenwasser:matrix.org> is the second column milliseconds? i think either function call count or sample count - but I don't know for sure [05:52:17.0953] i believe there's nonzero use cases where if a module starts using TLA, things will break - i forget which off the top of my head tho [05:52:31.0102] > <@littledan:matrix.org> in our use at Bloomberg, we've found that the restriction to a namespace is a little annoying but not really that bad I wonder if we could employ a heuristic where named imports that are only used in functions are deferred until the first function call? [05:53:55.0166] > <@ljharb:matrix.org> i believe there's nonzero use cases where if a module starts using TLA, things will break - i forget which off the top of my head tho If it has side effects and a module that does not list it as a dependency relies on its side effects [05:55:02.0965] hm, that's not what i was thinking of, but since i can't recall specifics rn, ยฏ\_(ใƒ„)_/ยฏ [05:55:05.0042] i.e.: ```js // a.js import defer * as ns from "foo"; // defer until `ns` property accessed. // b.js import defer { a, b } from "foo"; export function f() { console.log(a, b); } // defer until `f` is called // c.js import defer { a, b } from "foo"; console.log(a, b); // not actually deferred ``` [05:55:08.0139] * hm, that's not what i was thinking of, but since i can't recall specifics rn, ยฏ\\\_(ใƒ„)\_/ยฏ [05:55:23.0649] > <@ljharb:matrix.org> i believe there's nonzero use cases where if a module starts using TLA, things will break - i forget which off the top of my head tho for well-behaved graphs I don't think it's ever breaking; it's only if there's weird side-effect ordering problems that it breaks [05:56:27.0366] > <@rbuckton:matrix.org> I wonder if we could employ a heuristic where named imports that are only used in functions are deferred until the first function call? fwiw that seems like too much magic to me [05:56:47.0885] > <@bakkot:matrix.org> for well-behaved graphs I don't think it's ever breaking; it's only if there's weird side-effect ordering problems that it breaks we've hit that. we have code `onAppInstall.addListener(...)` which the callback is _only_ called if the callback is registered in 1st event loop. [05:57:37.0460] > <@bakkot:matrix.org> fwiw that seems like too much magic to me `defer` itself is too much like magic [05:58:08.0841] the thing where the namespace object implicitly has side-effecting accessors is, just barely, not too magic for me [05:58:19.0640] the previous suggestion of having local access be side-effecting was too magic [05:58:24.0891] but property access can already be side-effecting [05:58:28.0838] bakkot: Most places I have seen TLA in is leaf modules (for example Wasm loading), or the top level entrypoint (for example data fetching in a CLI). In my experience TLA anywhere between entrypoint and leaf is very rare. [05:58:30.0912] you can explain this feature in terms of existing ones [05:58:37.0248] * you can (mostly) explain this feature in terms of existing ones [05:58:38.0417] it still feels too magic to me tbh [05:58:40.0307] so it is, just barely, ok with me [05:58:56.0073] > <@lucacasonato:matrix.org> bakkot: Most places I have seen TLA in is leaf modules (for example Wasm loading), or the top level entrypoint (for example data fetching in a CLI). In my experience TLA anywhere between entrypoint and leaf is very rare. why would wasm loading be a leaf? [05:59:00.0824] wasm is just like... code [05:59:08.0479] > <@rbuckton:matrix.org> `defer` itself is too much like magic but also, determining whether named imports are lexically scoped to functions is statically analyzable, with the exception of direct-`eval` (which could just block deferred evaluation anyways). [05:59:24.0022] +1 I don't think it's magical for the `ns` case. Direct import binding is a little bit magic but also good to me. [06:00:17.0505] > <@bakkot:matrix.org> why would wasm loading be a leaf? ... because it needs to be passed an imports object? how can it not be a leaf? [06:01:51.0372] I guess I mean a difference sense of "loading" [06:02:00.0740] yes, loading the bytecode is a leaf, of cousre [06:02:03.0623] * yes, loading the bytecode is a leaf, of course [06:03:02.0537] but if you have a library which has a wasm component, it seems like "TLA to async-compile the wasm" is a pretty normal use case [06:03:56.0303] which means your library's entry point would have a TLA, not just the leafs of the library [06:05:57.0951] i don't think i'm confused [06:06:08.0207] i'm saying in JS, compilation can be transparently deferred and folded into evaluation [06:06:19.0838] in wasm because timing is of a bigger concern, it cannot be generally transparently deferred [06:06:54.0635] I also want to notice the deferred is not only the compilation happened in the engine, but also the _execution_ of the JS code [06:06:55.0388] and the motivating number of "half the time spent in evaluation" as shown by the profiler output suggests that that includes main-thread deferred compilation [06:07:07.0677] well yes, obviously the execution is the main thing to be deferred [06:07:16.0402] i'm questioning the "half the time" measure and what it includes [06:07:18.0551] https://developer.mozilla.org/en-US/docs/WebAssembly/JavaScript_interface/Instance/Instance#syntax says in a big red box, "Warning: Since instantiation for large modules can be expensive, developers should only use the Instance() constructor when synchronous instantiation is absolutely required; the asynchronous WebAssembly.instantiateStreaming() method should be used at all other times." [06:07:58.0049] ^ This is about the sync constructor after you already have an async compiled Module [06:08:01.0853] for example https://github.com/alexcorvi/anchorme.js/pull/127 this library cost 30ms to init (this PR is reverted by the author). We now using `defer` to save this 30ms [06:08:11.0708] > <@shuyuguo:matrix.org> i'm questioning the "half the time" measure and what it includes right, the thing is, we have a whole bunch of data about the benefit of this, and the champions were conservative about what they included on slides. I think it's reasonable that you ask how much benefit this will get on the web. [06:08:28.0228] I would point out, though, that when it's a cache hit, the fetching and compiling part might be pretty quick [06:08:30.0139] i'm convinced it's a win for JS for sure [06:08:57.0427] the wasm questions got me doubting about how well the performance story composes [06:08:58.0946] Synchronous lazy loading in CommonJS is sometime known as "inline requires". Jest managed to [half their startup time](https://jestjs.io/blog/2016/03/11/javascript-unit-testing-performance#inline-requires-and-lazy-mocking) by incorporating this technique. [06:09:03.0020] or are we also introducing performance footguns [06:09:17.0379] I guess I don't understand the performance breakdown case [06:10:35.0663] you're all right that we should investigate this better for Wasm. I think this should block Stage 3. [06:10:52.0626] I should've realized that earlier, so thanks for raising it [06:11:06.0324] Chris de Almeida: have you considered just implementing https://github.com/bterlson/tcq/issues/14? [06:11:26.0430] there's so many good things on the TCQ issue tracker [06:11:28.0100] I wonder if a module could say e.g. `"defer load"` to communicate that if it's loaded via `import defer`, all of its imported dependencies could be completely deferred until its evaluation. [06:11:50.0878] well i think the wasm case is generalizable to a certain kind of module with a certain weight profile of time spent in which phases [06:12:04.0521] the high-order bit for me is "does the performance story compose" [06:12:16.0381] concretely, I have published exactly one wasm-based library (z3-solver). It's CJS-based so it has an async `init` function, but if it was ESM-based it would totally have a top-level `await` in its entrypoint, not at a leaf. and it's doing a nontrivial amount of computation on load, of exactly the sort I'd hope to be deferring by the use of `defer`. [06:12:20.0177] can someone who doesn't need sync evaluation can just always insert `defer` and get some loading wins [06:12:37.0123] Michael Ficarra: yeah.. I think we need a DX workflow presentation from BT first [06:13:50.0703] > <@shuyuguo:matrix.org> the high-order bit for me is "does the performance story compose" right, I think this comes down to some details of the algorithm for exactly what is made eager. It's a good action item for the champions to articulate some more cases to investigate this. My intuition is that it should work out as long as you do `import defer` for the imports from within the module that uses TLA--then you get the deferred-ness back [06:13:56.0556] > <@shuyuguo:matrix.org> the high-order bit for me is "does the performance story compose" Given our experience deploying an ESM system, we've found the ESM performance composition story is not viable without this feature. [06:14:16.0435] let me rejoin [06:14:22.0337] > <@robpalme:matrix.org> Given our experience deploying an ESM system, we've found the ESM performance composition story is not viable without this feature. this matches what Yulia shared for Firefox DevTools at the outset of this project [06:14:34.0731] that's not what i mean by composition, i don't think [06:14:40.0681] It also matches what I've said at every plenary where this item is brought up ;-) [06:14:54.0305] i understand Yulia's original claim to be "ESM performance story is not viable without this feature" [06:15:01.0274] ok sorry if I misinterpreted the point [06:15:01.0834] maybe that's the overriding thing [06:15:45.0646] > <@littledan:matrix.org> right, I think this comes down to some details of the algorithm for exactly what is made eager. It's a good action item for the champions to articulate some more cases to investigate this. My intuition is that it should work out as long as you do `import defer` for the imports from within the module that uses TLA--then you get the deferred-ness back does this match what you're asking about, shu ? [06:17:11.0507] let me try to articulate what i'm asking for plenary littledan [06:18:12.0048] webpack might be the TLA breaking change i was thinking of [06:19:08.0400] I know bakkot mentioned something like this - but it does feel like `import defer` is going to ring the wrong bells for a lot of people who expect this won't even do script parsing. Not that I am necessarily advocating for that behavior. [06:19:13.0871] this proposal is good enough for sync usage. I have no idea about TLA and WASM and we haven't try that yet. [06:19:59.0506] so it did get stage 2? [06:20:07.0380] yeah [06:20:14.0369] k [06:20:14.0875] fwiw, at Bloomberg we still encourge use of fully-async dynamic import when that is viable. This proposal has been great for the places where it has not been viable to go fully async [06:20:32.0170] Ashley Claymore: see that smells really off to me [06:21:54.0675] the current situation when it is not viable is that code is written to be fully eager. [06:22:41.0030] hm my internet is not down but zoom disappeared for me [06:23:01.0080] just me? [06:23:07.0938] no, I can see zoom [06:25:16.0660] okay, took a while to come back [06:25:25.0899] Ashley Claymore: right, agreed on that premise [06:26:02.0853] > <@shuyuguo:matrix.org> Ashley Claymore: see that smells really off to me it's pretty common that you're writing code that's not in an async function... I don't think that's going to go away. [06:26:03.0505] Ashley Claymore: but it doesn't smell right to me (yet) that we've been saying "asyncify" and now saying "well, if you did asyncify if you wanna take advantage of this new deferral thing you might not be able to" [06:27:14.0899] shu: Using dynamic import would only neuter the deferred import if the dynamic import were awaited at top-level. The general advice is to never do that. Instead, dynamic import is best used just-in-time inside async functions that require it. [06:27:51.0339] i mean top-level await is a thing? [06:28:08.0535] i don't know how to reconcile that we added it with "actually the general advice is to never do that"? [06:28:10.0047] > <@shuyuguo:matrix.org> Ashley Claymore: but it doesn't smell right to me (yet) that we've been saying "asyncify" and now saying "well, if you did asyncify if you wanna take advantage of this new deferral thing you might not be able to" In some way, this is a key part of providing a well-scoped amount of feature parity from CJS into, since CJS has always supported this pattern (differently, just by having sync require, which is more general than this feature) [06:28:20.0975] > <@shuyuguo:matrix.org> Ashley Claymore: but it doesn't smell right to me (yet) that we've been saying "asyncify" and now saying "well, if you did asyncify if you wanna take advantage of this new deferral thing you might not be able to" * In some way, this is a key part of providing a well-scoped amount of feature parity from CJS into ESM, since CJS has always supported this pattern (differently, just by having sync require, which is more general than this feature) [06:28:25.0857] interesting framing [06:28:29.0606] i don't know enough about CJS to say [06:28:35.0316] "never do that" -> "avoid if possible" (I was too strong) [06:28:38.0618] * i don't know enough about CJS to say if i find that compelling [06:28:53.0915] ๐Ÿ˜ฎ I had no idea they didn't have an FPU! [06:29:21.0317] > <@shuyuguo:matrix.org> i don't know how to reconcile that we added it with "actually the general advice is to never do that"? I think this isn't actually the advice--it's more like, if you want the deferral to happen, you also need to defer the imports within the TLA-containing module, and not put the only `defer` things higher up in the module graph [06:31:46.0607] someone is spamming the notes with the letter t [06:32:04.0571] did someone fall asleep at their keyboard? /j [06:32:44.0720] why would we want `irandom` to take bounds if `random` doesn't? I don't like it [06:32:53.0419] ๐Ÿˆ๏ธ โŒจ๏ธ [06:37:02.0388] Because it's very common? `Math.random()` actually have bounds implicitly [06:37:15.0742] Note that our internal membership lists don't exactly match what Ecma has recorded. We should work to reconcile these. cc saminahusain [06:37:35.0058] > <@michaelficarra:matrix.org> why would we want `irandom` to take bounds if `random` doesn't? I don't like it don't think if it as "like random, but gives an int" [06:37:49.0311] think of it as "like randInt, the extremely useful function in every other standard library" [06:38:12.0854] (probably it should also not be spelled `irandom`) [06:39:19.0127] sffc: is divrem considered an alternative to divmod or is it still useful even when you have divmod? [06:40:50.0226] why not operator `a /% b` instead of `divrem`? ๐Ÿ˜ [06:40:52.0511] littledan: doesn't Ecma only keep one point of contact per member? [06:41:14.0822] sffc: ... because we don't have 64-bit integers? [06:42:04.0082] yeah i think... that's just that [06:42:10.0274] also i don't want to allocate BigInts? [06:43:43.0332] yeah I guess if we wanted to support 64-bit integers we'd need stuff for, like, adding two bigints and then rounding to the right 64-bit int (possible to define in multiple ways for signed vs unsigned). I'm not convinced we need that--my hope was that BigInt.asUintN would be a suitable replacement (to call after the bigint arithmetic op) [06:44:29.0045] > <@shuyuguo:matrix.org> also i don't want to allocate BigInts? I guess the hope is that the compiler would do representation analysis and avoid allocating BigInts [06:44:39.0229] lol, lmao [06:45:06.0065] why lol? [06:45:26.0341] I mean, it's fine that you don't do it now, but I don't know what the blocker would be if it were used commonly enough [06:46:07.0858] like, this is a totally classical optimization in the Scheme world [06:46:18.0426] i don't think that will ever happen outside of the optimizing tier [06:46:37.0947] oh yeah definitely [06:46:50.0885] and i don't consider optimizing tier hope to be very compelling for proposal motivations, or alleviating proposal performance concerns [06:47:50.0884] I mean, this logic went into the decision to not add int64 and instead go for bigint, in the first place [06:48:38.0121] yes, and in retrospect i think it was wrong [06:49:08.0722] for Promise.withResolvers: i have another meeting at 7am (didn't realize this went until 7:15) [06:49:35.0151] shu: Are you OK with the presentation going on? we can return to it later if you want to give more comments [06:49:41.0503] but you might have time for yours [06:49:52.0338] yes of course [06:59:43.0716] > <@michaelficarra:matrix.org> sffc: is divrem considered an alternative to divmod or is it still useful even when you have divmod? I was referring to the Euclid divrem, which always returns positive numbers for the remainder and rounds the quotient toward negative Infinity instead of zero. At least this is what Rust calls the operation (added a link to the notes) [07:02:20.0756] > <@sffc:mozilla.org> I was referring to the Euclid divrem, which always returns positive numbers for the remainder and rounds the quotient toward negative Infinity instead of zero. At least this is what Rust calls the operation (added a link to the notes) thanks for clarifying in the notes [07:03:11.0061] I maintain that `defer` and `deferred` are awful names for anyone who doesn't know the history, which is 95%+ of users [07:03:14.0771] it doesn't defer anything [07:03:22.0572] and `deferred` is not a noun [07:07:17.0236] > <@bakkot:matrix.org> I maintain that `defer` and `deferred` are awful names for anyone who doesn't know the history, which is 95%+ of users Yeah, bikeshedding names is sort of the rare case where it is reasonable to make decisions based on the knowledge of percentages of JS developers [07:07:41.0385] Rob Palmer: We'd gladly host you in Dresden :) [07:08:18.0983] than we can name it `import duck` until stage 3 ๐Ÿ˜‡ [07:09:45.0193] ok I'm assuming nothing else important is happening so I am going to go sleep [07:27:01.0679] ``` // wasm.js const mod = await WASM.instantiateStreaming(fetch(โ€ฆ)); export const foo = mod.exports.foo; ``` [07:27:15.0750] This is a leaf. No imports [08:02:56.0556] bakkot: looks like we're missing the logs for today? https://matrixlogs.bakkot.com/TC39_Delegates/2023-07-11 [08:19:27.0865] > <@mhofman:matrix.org> bakkot: looks like we're missing the logs for today? https://matrixlogs.bakkot.com/TC39_Delegates/2023-07-11 I think it's a cron job that runs, not realtime (?) [08:32:40.0089] I forgot who asked, but I added the TG3 slides to the agenda (`07.md`) [08:37:28.0392] https://www.ecma-international.org/news/ecma-tc39-ecmascript-has-formed-a-new-task-group-tg3-dedicated-to-the-security-of-the-ecmascript-javascript-language/ do we want/need to work with Ecma on drafting something like this for TG4? littledan jkup [09:08:51.0792] > <@softwarechris:matrix.org> https://www.ecma-international.org/news/ecma-tc39-ecmascript-has-formed-a-new-task-group-tg3-dedicated-to-the-security-of-the-ecmascript-javascript-language/ > > do we want/need to work with Ecma on drafting something like this for TG4? littledan jkup I think that would be great! [09:14:00.0568] Array Grouping has now met its stage 3 condition [09:48:18.0682] peetk: i am fine with Promise.withResolvers advancing to Stage 3 given the explanations [09:48:30.0602] sorry for having to drop out early [09:48:56.0598] (though for the future i'd still prefer to not have meetings end on :15 which is kinda weird) [10:02:32.0506] i think it's good and healthy to revisit, and overturn, previous design decisions based on new evidence [10:03:52.0542] but still in this particular case and future ones i don't want to conflate "good" defaults and developer signal [10:07:10.0173] the end goal for me is users, not developers, and good defaults for me should be chosen to nudge developers to the result (responsiveness, correctness, fast loading, whatever) we want on products they build for the user. if _all_ developers ignore a default constantly, then we obviously failed and nobody benefits. Google-internally, i did not get this sense when talking with practitioners [10:08:48.0957] this is all to say that it's a common argument in committee to say "look developers all do X and want Y", and it's not really that much signal to me most of the time [10:09:17.0646] * the end goal for me is users, not developers, and good defaults for me should be chosen to nudge developers to the result (responsiveness, correctness, fast loading, whatever) we want on products they build for the user. if _all_ developers ignore a default constantly, then we obviously failed and nobody benefits. Google-internally, i did not get this sense when talking with practitioners about a lack of a defer-like thing [10:10:13.0442] how do you feel about DX as motivation for proposals in general? [10:11:17.0446] i think it is a weak motivation by itself [10:13:07.0335] as a general rule i do not think DX outweighs other concerns like security and performance [10:13:28.0533] if the other concerns are minimal, then DX is the right thing to optimize for [10:14:59.0532] but at the scale of JS and the web, until we figure out a way to do zero-cost DX improvements, it is explicitly a non-goal for me [10:21:27.0525] (it is not an anti-goal, i'm not saying i will actively oppose DX proposals, just that it is not a thing i will push for and find compelling standalone, but i certainly won't block absent other concerns) [10:24:29.0662] > <@mhofman:matrix.org> bakkot: looks like we're missing the logs for today? https://matrixlogs.bakkot.com/TC39_Delegates/2023-07-11 ugh, yes, something's up with my server [10:25:43.0010] it keeps making the boot disk read-only [10:25:47.0847] for reasons I have not been able to discern [10:26:08.0481] I will fix it later today and the logs will come back [10:50:14.0227] https://hackmd.io/BkORU_-kTKmR43Ipuohwog schedule has been updated. there is no difference in terms of constraints, but please review if you are presenting [10:50:57.0578] * https://hackmd.io/BkORU\_-kTKmR43Ipuohwog schedule has been updated. there is no difference in terms of constraints, but please review if you are presenting. edit: I think only Day 3 was affected, and changes are minor [11:58:14.0652] I do not see Explicit resource management in the overflow section but from reading the notes I gather it did overflow its timebox? [12:02:44.0087] > Consensus on PRs: 180,178,175,171 and 167. > Debates about the appropriate use of GC and Symbol.enter are ongoing and will take place in overflow time [12:04:34.0115] rbuckton: are we scheduling a continuation? if so, how much time do you estimate? [13:01:17.0639] Thank you! [13:17:33.0245] > <@softwarechris:matrix.org> rbuckton: are we scheduling a continuation? if so, how much time do you estimate? Yes, if we could. 15 minutes, maybe? [13:18:15.0496] tomorrow morning work? [13:18:45.0109] if other topics run long or if 15 mins turns out to not be enough, there's still time available on Friday morning [13:19:33.0680] done [13:20:24.0545] * if other topics run long or if 15 mins turns out to not be enough, there's still time available on Thursday morning 2023-07-12 [17:15:44.0630] > <@mhofman:matrix.org> bakkot: looks like we're missing the logs for today? https://matrixlogs.bakkot.com/TC39_Delegates/2023-07-11 fixed. I suspect my boot disk is failing; will have it replaced tomorrow. [19:17:00.0903] > <@shuyuguo:matrix.org> the end goal for me is users, not developers, and good defaults for me should be chosen to nudge developers to the result (responsiveness, correctness, fast loading, whatever) we want on products they build for the user. if _all_ developers ignore a default constantly, then we obviously failed and nobody benefits. Google-internally, i did not get this sense when talking with practitioners about a lack of a defer-like thing the problem is we cannot everything by default because it's a breaking change [20:03:24.0392] not sure i follow [20:03:36.0124] the context of my previous comment was about the Promise constructor vs withResolvers [20:04:14.0834] oh [20:04:29.0446] the "good default" was referring to the hope that the Promise constructor would, even though it's more inconvenient to use, would bring about better correctness results wrt uncaught exceptions -> rejections [20:04:56.0737] but since then we've learned that maybe that doesn't have quite the effect we hoped because people ignore it [20:05:01.0237] or because there are legitimate use cases [20:05:15.0239] and so, it's fine to add withResolvers, even though it's explicitly against what we thought was the good default [20:05:51.0139] but the broader point is that that's the kind of argument i'm looking to hearing, not simply "developers use pattern X" [20:06:00.0275] * but the broader point is that that's the kind of argument i'm looking to hear, not simply "developers use pattern X" [01:02:00.0423] g'morning all [01:10:12.0088] I have a question about calendars. The source map monthly call was on the TC39 calendar but I don't see it on there anymore. How can I go about adding it back? Do I make a personal event and then invite the calendar? Or do I need a special permission to do this? [01:18:16.0682] my understanding was that an event needs to be added to the private calendar first, and the public calendar is invited as an attendee of that event [01:18:37.0120] the public calendar has an email address to invite [01:19:04.0106] most of us regular-folk don't have permission to create such an event on the private calendar, though, so you should contact a chair or ljharb [01:19:11.0594] Thank you! [01:24:16.0833] > <@shuyuguo:matrix.org> but since then we've learned that maybe that doesn't have quite the effect we hoped because people ignore it I think this is the key point--despite many years passing, people are generally unaware both of the implied best practice and the fact that the promise constructor helps lead you to it, and on the other hand, the best practice is enforced by async/await. An illustration of the widespread lack of awareness is that no one even raised this concern in committee until you did, and without this awareness, people can't even really be expected to use the promise constructor in the way where it's helpful. [01:33:29.0463] If `dayOfWeek` returns `2`, indicating this is the 2nd day of the week relative to the `firstDayOfWeek`, it could be confusing that both are numbers 1-7 but don't represent the same value. [01:33:38.0594] https://unicode.org/reports/tr35/#UnicodeFirstDayIdentifier [01:33:46.0417] (this is what Shane is talking about) [01:34:47.0922] > <@rbuckton:matrix.org> If `dayOfWeek` returns `2`, indicating this is the 2nd day of the week relative to the `firstDayOfWeek`, it could be confusing that both are numbers 1-7 but don't represent the same value. Assuming my interpretation is correct. [01:38:18.0510] This Unicode extension for locale identifiers seems nuts to me. You have to use the first part of the identifier "en" to know how to interpret the identification of the day of the week "tue". [01:42:21.0338] It also maintains a list of all of the delegates to TC39; this is listed in the Ecma memento. When organizations add or remove delegates, someone is supposed to inform Ecma of this so they can update their lists (I think the chairs do this?). But anyway things have gone out of sync. [01:50:51.0528] I think the summary can omit the back-and-forth that Frank and I had, and instead be in paragraph form. Will Frank be doing this rephrasing, or should I do so? (I don't see Frank here, maybe another Google could ask him?) [01:51:07.0255] * I think the summary can omit the back-and-forth that Frank and I had, and instead be in paragraph form. Will Frank be doing this rephrasing, or should I do so? (I don't see Frank here, maybe another Googler could ask him?) [01:51:59.0685] (or bullet form) [01:53:28.0183] Unless the presenter explicitly delegates, they remain responsible for the summary. The secretary will chase presenters where summaries appear insufficient. I'll make sure we say this on the Reflector. [02:07:43.0222] Ashley Claymore: should I put the link in the notes? [02:08:54.0651] ryzokuken ๐Ÿ‡ณ๐Ÿ‡ด: yes, there is a spot for you to do so already [02:09:12.0182] search for "slides presented but no link in agenda" [02:14:59.0719] I slightly prefer `offset` solution because I guess developers use BYOB for perf, and would like to use `offset` to get perf benefit (even a little), and even without `offset`, it already complicated ๐Ÿ˜‰ [02:16:59.0014] HE Shi-Jun: I wouldn't want to do that without compelling evidence that the perf is significantly better [02:17:10.0586] also, it would be safe to add later, right? [02:21:09.0997] > <@michaelficarra:matrix.org> ryzokuken ๐Ÿ‡ณ๐Ÿ‡ด: yes, there is a spot for you to do so already done, thanks again for the reminder [02:22:08.0423] > <@michaelficarra:matrix.org> also, it would be safe to add later, right? agree it could be add later. I just think it very likely will have some perf benefit, especially on embed engines. [02:27:15.0855] So, the alternative to having these "inputOffset" and "outputOffset" parameters is to have to create a separate view into the input & output base arrays on each iteration of the loop? [02:29:43.0338] Bradford Smith: yes, or a shifting view, and views should be very lightweight [02:30:24.0287] * Bradford Smith: yes, and views should be very lightweight [02:46:54.0982] After listening all queue discussion, I feel maybe we'd better leave the streaming api to future follow-on proposal ... [02:48:12.0314] I think we want the full cake, we want the un-disputed oneshot methods to fast-track, and have the streaming API versions that share consistency with them added later. Looks like a good challenge... [02:48:48.0806] I think the streaming design is as fleshed out as it's going to be, we just need to decide whether it's justified for inclusion or not [02:49:08.0894] I don't think splitting helps with that [02:50:44.0468] > <@michaelficarra:matrix.org> Bradford Smith: yes, and views should be very lightweight views are apparently not that lightweight in JSC per https://github.com/tc39/proposal-arraybuffer-base64/pull/26#issuecomment-1617312928 [02:51:03.0791] or at least not the first view [02:51:40.0116] *should* [02:51:58.0011] I dont think views are in general "lightweight" in comparison to actually know the place where you want to put yyour data [02:52:28.0435] > <@michaelficarra:matrix.org> I think the streaming design is as fleshed out as it's going to be, we just need to decide whether it's justified for inclusion or not But, yes this might be true [02:52:44.0996] > <@michaelficarra:matrix.org> *should* I think there's always going to tradeoffs in any representation, and a representation in which the second view of a buffer is expensive in exchange for the first view being faster is not obviously incorrect [02:52:52.0890] so I don't think "should" is at all obvious here [02:54:24.0000] Luca Casonato: https://github.com/tc39/proposal-arraybuffer-base64/issues/13 is the streaming issue, and https://github.com/tc39/proposal-arraybuffer-base64/issues/21 the one for encoding into an existing buffer [02:55:56.0867] the thing where you have a "prefix" argument to the one-shot API was my first suggestion, if I have understood correctly that this is what you were proposing; see response from justin in https://github.com/tc39/proposal-arraybuffer-base64/issues/13#issuecomment-911968641 [02:56:18.0460] (and from peter, two comments down) [03:00:40.0426] re: streaming: I think, in general, it's vaguely best practice that primitives that deals with data should have zero-copy and streaming APIs for doing stuff with them. To me, the main question is whether there are valid use cases for doing base64 on a fairly big thing that can't fit in memory/packets all together. I don't know of such use cases/environments. [03:01:47.0809] might be a bit cursed but I've seen people pass around entire images encoded in base64 [03:02:18.0555] that's not even unusual [03:02:18.0742] * might be a bit cursed but I've seen people pass around entire images encoded in encoded base64 [03:02:52.0075] yeah, not sure how ideal it is, but it's certainly not uncommon [03:03:13.0457] I know but there's a certain limit on how big they can get, right? [03:04:06.0984] also I don't think HTML has a streaming API to set the src of an img tag... [03:04:14.0076] there are a lot of APIs that don't handle binary data at all. You can only send e.g. images via encoding [03:04:22.0509] bakkot: My suggestion was this: https://gist.github.com/lucacasonato/06a74fe2658fbe5a2d9c24cc767006c0 No need for any `extra` option on the static API. This performs at most 3 byte copies for every remainder. The code can be optimized further. [03:05:01.0526] at Shape, we one-shot base64 decode something like 150kb of bytecode on the main thread every page load [03:05:08.0499] haven't run into any long task issues yet [03:05:55.0014] There is no "real" upper limit of the length of a string. Most of the limits are imposed by the server software that is used [03:06:10.0467] yes please [03:06:15.0714] let me introduce you to my good friend 2**53 [03:06:21.0608] :D [03:06:54.0155] You might compress you string before you hit that ห†ห† [03:07:01.0180] *your [03:07:14.0245] ah, got it [03:07:44.0484] > <@tkopp:matrix.org> there are a lot of APIs that don't handle binary data at all. You can only send e.g. images via encoding it'd be good to understand use cases like this in some more detail [03:07:49.0401] bakkot: do you have a link to your Web Streams impl ontop of the streaming API? I can't find it in your slides [03:07:56.0024] * bakkot: do you have a link to your Web Streams impl ontop of the proposed streaming API? I can't find it in your slides [03:08:03.0376] it's in the playground [03:08:11.0266] https://tc39.es/proposal-arraybuffer-base64/ [03:08:39.0667] Ah, thanks! [03:10:50.0639] rbuckton: my personal opinion is that I'd like to investigate `Symbol.enter` but with what I know at this time, full context manager support seems excessive. I'd hesitate to speak for the committee, but that would be my recommendation [03:10:50.0954] soap APIs from transportation/shipping companies come to mind immediately. [03:11:24.0800] great, I'd love to hear about your experience with these and how they relate to data size and streaming [03:11:28.0671] github rest API returns contents as base64-encoded strings [03:11:54.0509] for files up to 100MB in size [03:14:52.0272] actually I guess only up to 1MB; the API changes a bit for larger files [03:14:56.0838] From my point of view Ron was just considering a related problem - how to make sure developers are nudged toward using the resource management features he's defining - and then coming up with a possible solution to this. He presented it as a possible follow-on proposal. DE seemed at first to be saying that this problem is important enough to force changes to the existing stage 3 proposal, but I think he's backed down from this. I think the conclusion is not to include such a feature in the current proposal. [03:15:19.0969] I'll reiterate that I don't have an appetite for full context managers. They add a level of complexity that I'm not sure is suitable for ECMAScript, and they would have a negative impact on the ability for static type checkers like TypeScript to make reasonable assumptions about control flow due to ability for any context manager bound to a `using` to swallow an exception. [03:18:34.0245] Regarding the GC cleanup issue: I thought Ron was suggesting that engines could be encouraged to clean up any disposables that they themselves created (not every possible disposable) if they go out of scope without "leaking" anywhere else from the scope where they were created. [03:19:05.0387] just encouraged, not required [03:19:37.0644] If we're not doing full context managers, then the goal of the proposed change would be to resolve a concern about "unused" disposables. That would be addressed by `Symbol.enter` without the need to introduce a `Symbol.asyncEnter`. `await using` would still verify/capture `[Symbol.asyncDispose]` as it does today, but would call `[Symbol.enter]()` synchronously without the need to introduce an extra `Await` at the declaration site. That would also avoid needing to rethink `AsyncDisposableStack.prototype.use` to handle the async case. [03:20:18.0955] for using `Symbol.enter` as a way for types to _enforce_ they are being assigned to `using`, could this also be done with `Symbol.dipose` setting a `userHasAcknoledgedLifetime` flag that either errors/warns if other methods are called without that flag set? [03:20:24.0521] > <@littledan:matrix.org> re: streaming: I think, in general, it's vaguely best practice that primitives that deals with data should have zero-copy and streaming APIs for doing stuff with them. To me, the main question is whether there are valid use cases for doing base64 on a fairly big thing that can't fit in memory/packets all together. I don't know of such use cases/environments. it's not just about whether it all fits in memory; for example, one might reasonably stream base64'd wasm bytecode into WebAssembly.compileStreaming. the advantage of streaming in this case is that you can start doing work before waiting for the whole download to finish. which is nice! [03:21:12.0270] similarly, if you're uploading base64'd data to a server, you might do binary data -> compression stream -> base64 stream -> `fetch`; it's nice to be able to start the network request as early as possible [03:21:43.0418] my gut feeling is also that `DisposeStack.p.return` is a simpler API to explain that the enter/exit symbols. [03:21:44.0173] > <@aclaymore:matrix.org> for using `Symbol.enter` as a way for types to _enforce_ they are being assigned to `using`, could this also be done with `Symbol.dipose` setting a `userHasAcknoledgedLifetime` flag that either errors/warns if other methods are called without that flag set? Yes, a user-defined implementation could conceivably make `[Symbol.dispose]` a getter that indicates the method was at least read. [03:21:58.0224] > <@aclaymore:matrix.org> my gut feeling is also that `DisposeStack.p.return` is a simpler API to explain that the enter/exit symbols. what is `return`? [03:22:03.0391] sorry, move [03:22:06.0860] * sorry, `move` [03:22:13.0457] * my gut feeling is also that `DisposeStack.p.move` is a simpler API to explain that the enter/exit symbols. [03:24:46.0181] > <@bradfordcsmith:matrix.org> Regarding the GC cleanup issue: I thought Ron was suggesting that engines could be encouraged to clean up any disposables that they themselves created (not every possible disposable) if they go out of scope without "leaking" anywhere else from the scope where they were created. My intent was to state that as a remediation for an "unused" disposable, a host could leverage GC if necessary to ensure native handles don't leak, and that a user could use `FinalizationRegistry` to do the same. I worded it too strongly to expect that to always be the case, and that the outcome should be resource cleanup rather than a warning message like as what can happen for unhandled promise rejections. That wording was based on my prior experience with C#'s `IDisposable` and the C# team's recommendations to do likewise. [03:25:24.0264] > <@rbuckton:matrix.org> Yes, a user-defined implementation could conceivably make `[Symbol.dispose]` a getter that indicates the method was at least read. Personally, I think you're chasing an impossible goal here. The Explicit Resource Management proposal as-is provides a useful feature. There's no need to try so hard to force its correct use. Leave that problem for another day. Just my $0.02. [03:26:04.0982] > <@aclaymore:matrix.org> sorry, `move` `move` and `exit` are somewhat orthogonal to each other, so I'm not clear on the correlation you are making? [03:28:55.0303] > <@bradfordcsmith:matrix.org> Personally, I think you're chasing an impossible goal here. The Explicit Resource Management proposal as-is provides a useful feature. There's no need to try so hard to force its correct use. Leave that problem for another day. Just my $0.02. I concur. JavaScript itself can't reliably enforce lifetimes and ownership in the same way a language like Rust can, as that essentially requires a fully-baked runtime type system. Without that, we would be forced to take a major performance hit for every `var`/`let`/`const` declaration and every assignment to check or transfer ownership of an object's lifetime, which is a non-starter. [03:29:21.0151] for the examples where code is switching if the exit was a throw or return completion. Reaching DisposeStack.p.move also indicates that [03:29:28.0113] * can also indicate that [03:29:36.0049] I'm not convinced we even need `[Symbol.enter]()`. [03:29:59.0588] > <@aclaymore:matrix.org> for the examples where code is switching if the exit was a throw or return completion. Reaching DisposeStack.p.move also indicates that Ah, thank you for the clarification. [03:32:41.0219] > <@rbuckton:matrix.org> I concur. JavaScript itself can't reliably enforce lifetimes and ownership in the same way a language like Rust can, as that essentially requires a fully-baked runtime type system. Without that, we would be forced to take a major performance hit for every `var`/`let`/`const` declaration and every assignment to check or transfer ownership of an object's lifetime, which is a non-starter. In a way, `DisposableStack.p.move` is a close approximation of Rust's `move` semantics as a way to "transfer ownership on assignment" similar to an affine type system, but in an imperative form: ```js const stack1 = new DisposableStack(); ... const stack2 = stack1.move(); // stack1 can no longer be used, its contents have been moved to stack2. ... const stack3 = stack2.move(); // stack2 can no longer be used, its contents have been moved to stack3. ``` [03:33:07.0184] (which is part of the reason for the choice of method name as well) [03:34:09.0148] > <@rbuckton:matrix.org> I concur. JavaScript itself can't reliably enforce lifetimes and ownership in the same way a language like Rust can, as that essentially requires a fully-baked runtime type system. Without that, we would be forced to take a major performance hit for every `var`/`let`/`const` declaration and every assignment to check or transfer ownership of an object's lifetime, which is a non-starter. * In a way, `DisposableStack.p.move` is a close approximation of Rust's `move` semantics as a way to "transfer ownership on assignment" similar to an affine type system, but in an imperative form: ```js using stack1 = new DisposableStack(); ... using stack2 = stack1.move(); // stack1 can no longer be used, its contents have been moved to stack2. ... using stack3 = stack2.move(); // stack2 can no longer be used, its contents have been moved to stack3. ``` [04:01:49.0293] > <@rbuckton:matrix.org> I'm not convinced we even need `[Symbol.enter]()`. I agree. But if we did want to go in that direction, I think we should retract this proposal to Stage 2, as it's a big change and we don't have a concrete form of this yet. [04:02:02.0069] I think we should conclude that we're not going in this Symbol.enter direction [04:02:56.0606] this is just a very big thing to be considered an open question for a Stage 3 proposal [04:05:24.0149] > <@littledan:matrix.org> I think we should conclude that we're not going in this Symbol.enter direction nicolo-ribaudo's suggestion to make `[Symbol.dispose]` a getter if you want to opt-in to requiring the use of `using` or a `DisposableStack` holds water and may be satisfactory, without the need to introduce a new symbol-named method to the Disposable protocol: https://github.com/tc39/proposal-explicit-resource-management/issues/159#issuecomment-1630532470 [04:25:02.0382] it's so strange to me that IETF would explicitly *not* want to support sub-minute offsets [04:25:21.0014] it just feels like painting yourself into a corner for no good reason [04:25:51.0665] be the change you want to see in the world [04:26:05.0419] do you want sub-minute offset timezone in the world [04:26:17.0593] I am not a politician, I do not get to decide that [04:26:22.0208] they considered it vestigial and unnecessary [04:26:29.0086] * they considered it vestigial and unnecessary moving forwards [04:26:36.0713] if all the computer people collectively refuse to implement support for it, what are the politicians gonna do? [04:26:41.0899] fwiw, the ISO format still accepts all sorts of input [04:26:43.0352] I would not be at all surprised if the DPRK changed their timezone (again) to a sub-minute offset [04:26:46.0519] the time is whatever my phone tells me it is, not what a politician announces [04:26:48.0902] but IETF prefers to maintain a leaner profile [04:27:10.0009] > <@michaelficarra:matrix.org> I am not a politician, I do not get to decide that you sell yourself short dear mr ficarra [04:27:18.0144] bakkot: the DPRK makes their own OS [04:27:31.0189] i too skinned Linux when i was 10 [04:28:09.0018] > <@michaelficarra:matrix.org> bakkot: the DPRK makes their own OS I really wanted to respond but this isn't TDZ ๐Ÿ˜› [04:28:55.0537] yes, the limitation of being unhinged and deranged about time zones [04:51:38.0020] FWIW, `Asia/Pyongyang` could still have a sub-minute offset. the limitation doesn't apply to named time zones [04:54:17.0596] Yes, this only applies to in-timestamp offsets [04:59:40.0555] I think the details of whether engines ship the Intl-only part separately or just together with Intl is something that we can leave to engines to decide. If an engine expects to take a really long time to do Temporal, they might do the Intl-only part. But Temporal should only ship with this included, and it'd be valid to ship at the same time. Within this, I think 2a would be the simplest way to organize the explanations. [05:02:47.0075] > <@littledan:matrix.org> I think the details of whether engines ship the Intl-only part separately or just together with Intl is something that we can leave to engines to decide. If an engine expects to take a really long time to do Temporal, they might do the Intl-only part. But Temporal should only ship with this included, and it'd be valid to ship at the same time. Within this, I think 2a would be the simplest way to organize the explanations. err, never mind--I'm convinced by what Shu and Justin said, about how missing the .equals method is fatal for shipping separately [05:05:04.0393] sffc: no we can't implement the non-temporal parts sooner [05:05:11.0432] because of what dan just said [05:09:10.0194] It still seems like we should stop returning Saigon and Kiev despite the lack of a Temporal.TimeZone.prototype.equals [05:10:08.0107] that's what I was getting at, but I take Shu's point that that causes interoperability problems [05:11:45.0978] I do like this proposal but I still wish we had `import program from 'source.wasm' with { imports: whatever, memory: new ArrayBuffer(1000) }` etc [05:12:38.0521] instead of needing to import the source and then compile it yourself [05:12:41.0274] that's just kinda silly [05:12:46.0366] is that a static import with a `new ArrayBuffer` [05:12:51.0341] how does that work [05:12:52.0202] > <@bakkot:matrix.org> I do like this proposal but I still wish we had `import program from 'source.wasm' with { imports: whatever, memory: new ArrayBuffer(1000) }` etc Evaluating expressions even before linking the modiule graph seems... hard [05:13:12.0160] > <@bakkot:matrix.org> I do like this proposal but I still wish we had `import program from 'source.wasm' with { imports: whatever, memory: new ArrayBuffer(1000) }` etc * Evaluating expressions even before linking the module graph seems... difficult [05:13:35.0779] you do the downloading and so on right away but don't do the actual instantiation until you hit the `import` declaration [05:13:39.0066] this does not seem hard to me? [05:14:25.0720] > <@pchimento:igalia.com> that's what I was getting at, but I take Shu's point that that causes interoperability problems ok, sorry for my misunderstanding [05:14:46.0733] And you cannot capture bindings from outside the import declaration? i.e. ```js let buf = new ArrayBuffer() import program from 'source.wasm' with { memory: buf } ``` [05:15:27.0104] no I am imagining that would work as written [05:15:34.0819] don't see why it shouldn't [05:15:36.0398] That could work with CJS where modules are evaluated before their dependencies, but with ESM `buf` does not exist until when all the imported modules are evaluated [05:15:57.0130] there are multiple notions of "evaluated" wrt wasm [05:16:38.0994] the obvious thing for it to do is to download the thing but not actually instantiate until you hit the import declaration, at which point `buf` is available [05:16:57.0949] what is "hit the import declaration" [05:17:16.0348] like, get to that line in the program [05:17:17.0321] evaluation semantics for an ImportDeclaration [05:18:16.0737] the import declaration is just parsed and collected and processed ahead of time right now, it's not even in the compiled AST [05:18:20.0578] i don't think import has evaluation does it [05:18:31.0659] like we could add it but that seems a radical departure from what it does right now [05:18:48.0162] * the import declaration is just parsed and collected and processed ahead of time right now, it's not even in the AST sent to the compiler [05:18:56.0784] Also, import declarations are hoisted. Capturing from inside them has the same problems discussed for function declaration decorators [05:19:06.0607] to be clear I am not super-seriously proposing this [05:19:17.0483] I agree the hoisting is annoying technically [05:19:28.0278] however, no real program relies on hoisting import declarations, because that's batshit [05:19:29.0807] Also to be clear, I also hope we'll have direct imports for wasm one day [05:19:47.0291] so it still feels like the code sample above should just work as written [05:20:03.0047] hm, can you `class extends AbstractModuleSource { }` if it's not constructable or callable? [05:20:13.0416] i don't understand the spec draft as written [05:20:14.0554] if you use direct Wasm imports, then that Wasm module can import a memory from a different ESM module that explicitly constructs it. [05:20:16.0379] > <@bakkot:matrix.org> however, no real program relies on hoisting import declarations, because that's batshit (hoisting in the function declaration sense, that is) [05:20:19.0578] > <@ljharb:matrix.org> hm, can you `class extends AbstractModuleSource { }` if it's not constructable or callable? Yes but you cannot then call `super()` [05:20:39.0739] > (hoisting in the function declaration sense, that is) really? you don't write mutually recursive functions? [05:20:47.0656] * > (hoisting in the function declaration sense, that is) really? you don't write mutually recursive functions? [05:21:00.0981] > <@nicolo-ribaudo:matrix.org> Yes but you cannot then call `super()` ok so there's no way for a subclass to get the internal slot in a self-hosted-in-JS implementation? [05:21:10.0502] > <@shuyuguo:matrix.org> > (hoisting in the function declaration sense, that is) > > really? you don't write mutually recursive functions? Well, you don't write mutually recursive imports [05:21:21.0031] oh i misunderstood the point [05:21:34.0201] not that nobody relies on the hoisting function semantics, but the hoisting import semantics that are like the hoisting function semantics [05:21:36.0090] It's pretty common to use function hoisting in a sillier way, like ```js foo.onbar = fn; function fn() { } ``` In fact, fear of breaking this particular pattern is what's holding back function decorators [05:21:51.0062] > <@shuyuguo:matrix.org> not that nobody relies on the hoisting function semantics, but the hoisting import semantics that are like the hoisting function semantics right exactly [05:21:54.0218] > <@shuyuguo:matrix.org> not that nobody relies on the hoisting function semantics, but the hoisting import semantics that are like the hoisting function semantics anyway yes this is how import statements work [05:22:21.0767] concretely, no one writes an `import` declaration at the bottom of a file and code which runs right away which uses a binding from the `import` at the top of the file [05:22:22.0907] nicolo-ribaudo: it shouldn't unconditionally throw, it should just throw if it's its own NewTarget [05:22:54.0128] i think the current spec draft is just wrong about the abstract constructor thing [05:22:59.0819] https://github.com/tc39/ecma262/pull/3094#discussion_r1230304753 [05:23:01.0666] (I need to look at the proposal spec before answering to that) [05:23:02.0403] it's unconditionally throwing now but the comment suggests otherwise [05:23:16.0136] > <@shuyuguo:matrix.org> it's unconditionally throwing now but the comment suggests otherwise This is resolved by the Wasm subclass behavior [05:23:28.0229] how can you resolve that in the subclass behavior [05:23:52.0796] what installs the brand? [05:23:58.0826] the cyclic module record superclass throws; the wasm module subclass does another thing [05:24:11.0493] it's installed when parsing the Wasm module, by construction [05:24:12.0201] > <@littledan:matrix.org> It's pretty common to use function hoisting in a sillier way, like > > ```js > foo.onbar = fn; > function fn() { } > ``` > > In fact, fear of breaking this particular pattern is what's holding back function decorators sillier? This is a common practice in the TS codebase, i.e.: ```ts function createFoo() { const quxx = ...; return { bar, baz, }; function bar() { ... } function baz() { ... } } ``` [05:24:23.0473] > <@rbuckton:matrix.org> sillier? This is a common practice in the TS codebase, i.e.: > ```ts > function createFoo() { > const quxx = ...; > > return { > bar, > baz, > }; > > function bar() { ... } > function baz() { ... } > } > ``` sorry I shouldn't've included a value judgement [05:24:25.0924] littledan: i don't understand. happy to see spec text though [05:24:54.0723] shu: https://webassembly.github.io/esm-integration/js-api/index.html#get-module-source [05:25:09.0966] how does that interface with %AbstractModuleSource% [05:25:42.0504] It sets the internal slot in step 4 of https://webassembly.github.io/esm-integration/js-api/index.html#construct-a-webassembly-module-object [05:25:53.0020] (oops sorry I was answering the wrong question) [05:26:05.0437] someone is typing loudly again [05:26:19.0464] However yes, there is no way for JS code to create objects with that internal slot with the current spec (@ljharb) [05:26:23.0324] > <@bakkot:matrix.org> someone is typing loudly again Sorry, me [05:26:24.0134] that seems like a problem [05:26:49.0912] > <@bakkot:matrix.org> someone is typing loudly again did it stop for you? [05:26:53.0920] Do y'all think that throwing only if constructed directly would be an acceptable solution? [05:27:07.0450] that works for me [05:27:11.0211] > <@nicolo-ribaudo:matrix.org> Do y'all think that throwing only if constructed directly would be an acceptable solution? (I do not remember why we throw) [05:27:13.0447] * that works for me, based on new.target or something [05:27:15.0532] > <@littledan:matrix.org> did it stop for you? it has stopped now yes [05:28:06.0095] nicolo-ribaudo: yes, that is what we suggested here: https://github.com/tc39/ecma262/pull/3094#discussion_r1230304753 [05:28:48.0752] I'm trying to find references as to why we introduced the throwing behavior in the first place [05:29:27.0069] if there's no JS-exposed API for setting that internal brand slot (e.g., a super constructor parameter), then the constructor isn't very useful [05:29:32.0848] whether or not it throws [05:30:01.0191] hm, that is true [05:30:12.0103] it seems important to be able to self-host in JS tho [05:30:34.0546] to me this feels like something that's OK to unconditionally throw "for now" with a hope that we expand this out soon (maybe in the context of compartments) [05:31:07.0558] > <@ljharb:matrix.org> it seems important to be able to self-host in JS tho Without custom module loading you cannot self-host modules anyway [05:31:28.0024] you could with on-the-fly source rewriting, no? [05:31:40.0321] "instantiable" would be a name reflecting intuition? I think this sounds just vaguely computer-y. [05:31:43.0042] * you could with on-the-fly source rewriting, no? i don't mean virtualization which indeed would require custom module loading [05:32:21.0074] I don't like any of these new name suggestions [05:32:28.0165] the exiting names are fine [05:32:37.0037] > <@ljharb:matrix.org> you could with on-the-fly source rewriting, no? i don't mean virtualization which indeed would require custom module loading If you're rewriting source, why do you care about using a real source object at all? [05:32:41.0845] * the existing names are fine [05:32:46.0999] 'source' is much easier to write and spell than 'instantiable' [05:33:00.0024] > <@littledan:matrix.org> If you're rewriting source, why do you care about using a real source object at all? because user code would still need to interact with the resulting source phase object [05:33:23.0352] sorry, which sorts of interactions are you picturing? [05:33:37.0807] > <@aclaymore:matrix.org> 'source' is much easier to write and spell than 'instantiable' The good news is this is a power-user feature with a keyword that can get auto-completed [05:34:21.0336] importing and using wasm is power user now? [05:34:23.0786] > <@littledan:matrix.org> sorry, which sorts of interactions are you picturing? anything that's observable. i don't have a use case except that a self-hosted implementation should be able to be made indistinguishable from a C++ one [05:34:36.0575] > <@michaelficarra:matrix.org> importing and using wasm is power user now? when linking it yourself? yes, I think so [05:34:37.0237] since when has it not been [05:34:50.0142] I wish writing code snippets in non-IDES have auto-complete [05:35:00.0519] * I wish writing code snippets in non-IDEs had auto-complete [05:36:09.0432] I find "instantiable" even less understandable than "source". [05:36:39.0186] What's your definition of an IDE? Even notepad++ has auto-complete for JavaScript :D [05:36:48.0188] * What's your definition of a non-IDE? Even notepad++ has auto-complete for JavaScript :D [05:36:51.0861] apparently I don't understand the limits of the average developer nowadays [05:36:55.0201] Matrix [05:36:58.0320] github [05:37:02.0495] Slack [05:37:07.0899] Whatsapp [05:37:12.0647] not convinced you ever did [05:37:15.0067] * Whatsapp ;) [05:37:32.0966] i'm surprised but point taken [05:37:37.0345] Twitter bio [05:37:39.0915] If someone judges you for a code typo in Whatsapp please let me yell at them [05:37:43.0012] Threads? [05:37:44.0299] that said it is getting less and less power-user-y as it becomes a more first-class target in languages like go and rust [05:37:48.0014] (like, what do you think you want to do with the thing you get from this phase, if not to instantiate it later?) [05:37:48.0137] no JS in Whatsapp please [05:37:52.0358] JavaScript doesn't have threads [05:38:06.0188] does Threads have JS tho? [05:38:13.0760] sorry, I'll show myself out [05:38:24.0087] > <@shuyuguo:matrix.org> (like, what do you think you want to do with the thing you get from this phase, if not to instantiate it later?) Well, with WebAssembly.Module you might do reflection and nothing else [05:38:25.0666] Probably only in a bytecode format nowadays [05:38:40.0907] * Probably only in Hermes' bytecode format nowadays [05:38:43.0503] But yes, you would almost always want to instantiate it [05:38:50.0504] i don't get what that means, you just want to hold on to it? [05:38:51.0983] I think ljharb is saying the opposite? [05:38:55.0461] HHVM for JS [05:39:09.0679] WebAssembly.Module.imports() or exports() [05:39:14.0699] https://nodejs.org/api/worker_threads.html#workerismainthread [05:39:24.0059] * WebAssembly.Module.imports() or .exports() [05:39:25.0714] as it gets support in languages targeting wasm, using it manually becomes more niche [05:39:27.0939] how can their be a main thread if there are no threads...... [05:39:31.0195] it's part of the host, not JS [05:39:31.0665] :D [05:39:34.0770] `import reflectable` [05:39:39.0497] ๐Ÿ™ˆ [05:39:46.0913] I'm bad at jokes [05:40:05.0433] `import sourceable` [05:40:23.0709] No, you're doing good here by backing *my* joke ryzokuken ๐Ÿ‡ณ๐Ÿ‡ด , [05:40:34.0426] `import saucable` [05:40:39.0632] oh no [05:40:44.0143] `import sauceable`? [05:40:44.0445] I think I'm old enough to start writing my own jokes eventually [05:40:48.0014] `import raw` [05:41:01.0033] `import uninstantiated`? [05:41:09.0488] this is not TDZ [05:41:12.0498] `import saukable` [05:41:14.0670] uninstantiated is fine but how is that worse than instantiable? [05:41:22.0269] i would argue that usage of "not JS" to interoperate directly with JS is still a power user thing [05:41:34.0435] > <@eemeli:mozilla.org> `import raw` that could work actually [05:41:36.0069] "uninstantiated" is at least a word I have literally ever used before [05:41:44.0122] a word can be more precise and yet worse ergonomically [05:41:47.0561] "raw" sounds more like asset/blob/bytes to me [05:41:59.0220] But how often is this word getting typed out? [05:41:59.0740] An "uninstantiated module" makes sense to me more than "instantiable module" [05:42:15.0251] * i would argue that usage of "not JS" to interoperate directly with JS is still a power user thing, and will likely remain so for the foreseeable future [05:42:52.0451] > <@danielrosenwasser:matrix.org> But how often is this word getting typed out? hopefully often enough to warrant this proposal advancing [05:45:09.0747] I think for JS developers, yes [05:45:27.0048] what are the "phases" identified for modules during this process? like what comes after "source" [05:45:35.0152] but if you are a Go programmer, you are going to want to write Go, and then a small JS wrapper to let the Go program interact with the webapp [05:45:42.0015] `raw` is worse than `source` for the same confusion, yeah [05:45:51.0136] and the way you do that is, you compile the Go to wasm, and then import the wasm from a JS module [05:45:55.0690] honestly `import compiled` captures things well for Wasm (or `import parsed`??), but I'm not sure if it will be intuitive. [05:45:59.0504] this does not require being a poweruser of either language [05:46:13.0906] I was going to make a `String.raw` joke but Michael Ficarra said this wasn't TDZ [05:46:16.0680] I guess some people might think that it AOT-compiles the module code for JS? [05:46:30.0096] * I guess some people might think that `import compiled` AOT-compiles the module code for JS? [05:47:11.0729] do we imagine using this for things other than wasm [05:47:17.0378] no one is stopping you from making terrible jokes in TDZ [05:47:18.0671] if not, can we just make it `import.wasm` [05:47:35.0141] My impression is that the anticipated frequency of use is not the reason why this proposal exists - moreso, it's a small set of important use-cases that compose well [05:47:39.0809] > <@bakkot:matrix.org> do we imagine using this for things other than wasm KKL has a proposal for JS sources [05:47:57.0460] To do reflection on them, as well as custom linking [05:48:02.0875] ah, right [05:48:11.0560] and to bypass CSP I guess [05:48:21.0523] * and to avoid running afoul of CSP I guess [05:48:35.0319] > <@danielrosenwasser:matrix.org> My impression is that the anticipated frequency of use is not the reason why this proposal exists - moreso, it's a small set of important use-cases that compose well Which is why "pick the most explicit name" seems like the right option for me [05:48:35.0577] Yep, to avoid eval-like [05:48:55.0942] > <@danielrosenwasser:matrix.org> My impression is that the anticipated frequency of use is not the reason why this proposal exists - moreso, it's a small set of important use-cases that compose well * Which is why "pick the most explicit name" seems like the right option for me, even if it's a little verbose [05:49:12.0365] But `import source` is still better than `import module` [05:49:16.0069] that suggests maybe `import.reflect`? [05:49:42.0908] please, source is fine ๐Ÿ˜ฉ [05:49:44.0113] though I guess reflection might suggest also evaluation [05:50:06.0792] > <@bakkot:matrix.org> that suggests maybe `import.reflect`? I think this was the original world in the proposal, but there are two use cases (custom instantiation and reflection) and it only covers one [05:50:07.0925] `import fetched` [05:50:31.0529] `fetched` also suggests just raw bytes to me [05:50:50.0992] maybe the answer is there is just no intuition for half-processed things having names [05:51:00.0002] `import parsed` [05:51:05.0383] > <@shuyuguo:matrix.org> maybe the answer is there is just no intuition for half-processed things having names `import half mod from "x"` [05:51:31.0425] `parsed` i can live with but wasm isn't parsed but validated? [05:51:47.0933] validation is like parsing [05:51:50.0596] `analyzed` [05:51:51.0074] yeah [05:51:57.0168] `parsed` sgtm [05:52:01.0612] who hates `parsed` [05:52:09.0274] who hates the truth [05:52:09.0736] I could live with `parsed` [05:52:32.0302] What I dislike about it is that also a fully evaluated module has been parsed [05:52:47.0788] yeah but it's "only" parsed [05:52:51.0048] a fully evaluated module has also been source though [05:52:56.0289] yeah, pragmatics!! [05:53:13.0034] implicatures, specifically [05:53:44.0146] love me a gricean implicature [05:54:05.0311] ooh grice fans [05:54:54.0927] we do have some time available tomorrow if folks would like to have further discussion regarding source phase imports naming [05:55:09.0356] the Racket programming language uses "syntax" to refer to data that has been parsed -- ranging from simple expressions like `42` to entire modules -- but not yet evaluated [05:56:02.0382] that's in the context of macros [05:56:22.0439] in that there's a unified representation they manipulate [05:56:29.0607] whereas the thing we're getting is just kinda abstract [05:56:56.0813] > <@danielrosenwasser:matrix.org> `import sauceable`? I would unironically support `sauce` [05:57:13.0953] `import abstract mod from "paper.js";` [05:57:19.0923] > <@softwarechris:matrix.org> I would unironically support `sauce` that would be so confusing as an english language learner [05:57:33.0963] fair [05:57:39.0942] > <@softwarechris:matrix.org> we do have some time available tomorrow if folks would like to have further discussion regarding source phase imports naming maybe come back and see if `import parsed` is amenable to everyone? [05:59:18.0974] > <@shuyuguo:matrix.org> `parsed` i can live with but wasm isn't parsed but validated? also since it gives you a different representation than the input I think it is in fact parsed rather than validated? [05:59:30.0673] bakkot: okay i'm convinced [05:59:35.0450] at least according to the taxonomy of https://lexi-lambda.github.io/blog/2019/11/05/parse-don-t-validate/ [05:59:48.0634] also just polled internally [05:59:55.0488] V8 can live with `parsed` [06:00:31.0299] how did you conduct a representative sample poll at 6am [06:00:37.0372] I guess v8 is mostly in munich, nvm [06:01:55.0877] TCQ pretty rough... -> https://github.com/ChristianUlbrich/tcq/tree/contemporary-edition I split into three packages and decided that it is not worthwhile to get the old stuff to working, so I am just porting the client to contemporary Vue... [06:02:29.0253] Hope I have the client ported by the end of the day, what I am seeing is "special" to say the least, bust one step at a time... [06:05:49.0422] sorcery! [06:06:02.0140] > <@bakkot:matrix.org> maybe come back and see if `import parsed` is amenable to everyone? guybedford: Luca Casonato some folks here signaling it may be useful to spend some time tomorrow. thoughts? [06:06:26.0393] If we change to something else from `import source`, should/will the "module source" references in the proposal also be updated? [06:08:04.0832] probably yes [06:08:15.0512] ChatGPT ought to be able to suggest some terms [06:14:13.0652] eemeli: IMO that's not important at all [06:14:22.0106] it's not going to be an uttered name really [06:15:16.0153] when the proposal for JS ModuleSource objects arrives, that part will be [06:15:48.0819] shu: Not sure that I agree. We still need a generic name for the thing you get from this statement. [06:16:25.0675] sure, you need a name, but it's not a thing that developers are going to be typing, so i think any name is fine, really [06:16:43.0041] _once_ the JS module thing itself exists, that might be typed, and we should be more careful about that [06:40:56.0091] https://github.com/tc39/proposal-source-phase-imports/issues/53 [06:41:05.0566] > <@shuyuguo:matrix.org> i understand Yulia's original claim to be "ESM performance story is not viable without this feature" I wouldn't say it isn't viable, a code base can be entirely rewritten just for performance gains, at the cost of developing new features etc. But what we have found is that the rewriting of applications is unrealistic, and this stops people from moving to modules all together. [06:42:01.0747] whoa Yulia is here! I just want to take this opportunity to thank you for organizing the meeting here in Bergen. It's a beautiful city and great to meet this very relevant and insightful academic research group. [06:42:22.0962] oh that is lovely to hear! i hope we can work more with the community there, they are very excited about tc39 [06:43:11.0923] > <@yulia:mozilla.org> oh that is lovely to hear! i hope we can work more with the community there, they are very excited about tc39 Yes, I hope so too. Talking to them, I think they didn't realize that they were actual TC39 members and can participate as delegates if they want, not just observe. I think there's a big opportunity for collaboration [06:43:31.0668] I talked about some folks from the uni about this earlier [06:44:02.0837] Mikhail Barash is really great to work with, I've really enjoyed collaborating with the students at Bergen. Would love to join myself next year if we can do a plenary there again. [06:44:15.0500] my overlord is calling, i have to run. [06:44:16.0985] Hoping we can improve our relationships with all of our researcher colleagues and utilize academic techniques to analyze proposals in addition to everything we do now [06:44:48.0986] enjoy the plenary everyone! [06:48:07.0455] > <@shuyuguo:matrix.org> i understand Yulia's original claim to be "ESM performance story is not viable without this feature" * \ I wouldn't say it isn't viable, thats maybe too broad. a web code base can be entirely rewritten just for performance gains, at the cost of developing new features etc. But what we have found is that the rewriting of applications is unrealistic, and this stops people from moving to modules all together. In addition, this doesn't work so well when we consider non-web js applications, such as a good portion of the FX codebase, where we cannot use loading techniques such as module-preload [06:49:03.0157] * \ I wouldn't say it isn't viable, thats maybe too broad. a web code base can be entirely rewritten just for performance gains, at the cost of developing new features etc. But what we have found is that the rewriting of applications is unrealistic, and this stops people from moving to modules all together. In addition, this doesn't work so well when we consider non-web js applications that share modules with web applications, such as a good portion of the FX codebase, where we cannot use loading techniques such as module-preload [06:50:28.0689] apparently NTSC framerate is defined as a ratio as well [06:51:22.0523] We should push for a version of BigDecimal where 0.99999... != 1 [06:58:03.0501] ugh the web zoom client like pauses the video if i background the tab i think [06:58:05.0411] and it can't recover [06:58:36.0399] the web zoom client is terrible [06:58:38.0038] this wasn't happening as much yesterday [06:58:45.0145] but the app doesn't work on my computer ๐Ÿ˜… [06:58:50.0448] * but the app doesn't work on my computer either ๐Ÿ˜… [06:59:50.0889] well i can't install it per corp policy... [07:00:04.0408] does corp policy let you use parallels? [07:00:19.0992] * does corp policy let you use parallels? you could have a mac in your mac and install zoom on the guest mac [07:00:23.0102] do i want to install parallels [07:01:40.0115] (I know this is an unproductive discussion, sorry) [07:06:57.0498] dminor: they are talking about our proposed normalisation and omission if Infinity/NaN [07:07:14.0265] * dminor: they are talking about our proposed normalisation and omission of Infinity/NaN [07:07:21.0248] but it's Waldemar who wants normalization... [07:07:26.0954] I think the coercion with numbers is just an error [07:07:29.0790] IEEE standards are paywalled? [07:07:45.0708] I am skeptical about the perf claims, there mostly isn't hardware acceleration for Decimal128 yet [07:07:58.0391] Ok, so is this IEEE 754 decimal128 or not? [07:07:58.0526] so no matter what, you're implementing it using integer maths [07:08:36.0216] *mostly* [07:09:25.0756] but these implementations could improve perf over time as hardware acceleration crops up [07:10:03.0881] dminor: Yes, the idea is that we'd use IEEE Decimal128 [07:10:57.0460] > <@usharma:igalia.com> IEEE standards are paywalled? yes... are you looking for something? `