00:32:59  * aki_joined
00:34:09  * akirosequit (Ping timeout: 244 seconds)
00:34:09  * aki_changed nick to akirose
01:29:19  * bttfquit (Quit: ZNC 1.6.3 - http://znc.in)
01:30:08  * Bakkotjoined
01:30:36  * bttfjoined
01:31:07  * AtumTquit (Quit: AtumT)
02:41:18  * akirosequit (Ping timeout: 272 seconds)
02:41:45  * akirosejoined
03:40:34  * gibson042quit (Quit: Leaving.)
03:59:23  * jmdyckquit (Remote host closed the connection)
04:47:58  * aki_joined
04:48:21  * akirosequit (Ping timeout: 244 seconds)
04:48:21  * aki_changed nick to akirose
05:33:27  * IvanSanchez[m]quit (Ping timeout: 260 seconds)
05:33:44  * saulh[m]quit (Ping timeout: 256 seconds)
05:34:09  * emilianobovetti[quit (Ping timeout: 276 seconds)
05:47:21  * emilianobovetti[joined
05:47:42  * saulh[m]joined
05:49:23  * IvanSanchez[m]joined
05:59:05  <ryzokuken>Had been wondering one thing.
05:59:30  <ryzokuken>There's so many "bound functions" in the spec.
06:00:06  <ryzokuken>I can say for sure about ECMA402, but maybe the same applies for 262?
06:00:54  <ryzokuken>There's DateTimeFormat and NumberFormat's [[BoundFormat]], Collator's [[BoundCompare]] and others.
06:01:40  <ryzokuken>and the spec has the (almost) exact same set of guidelines regarding how each of these work.
06:02:02  <ryzokuken>Why not move it all into, say, something like `AddBoundMethod(...)`?
06:06:11  <ryzokuken>See: https://www.ecma-international.org/ecma-402/#sec-intl.collator.prototype.compare, https://www.ecma-international.org/ecma-402/#sec-intl.numberformat.prototype.format and https://www.ecma-international.org/ecma-402/#sec-intl.datetimeformat.prototype.format for example.
06:29:06  * akirosequit (Quit: 👋🏻)
06:29:49  * akirosejoined
08:36:01  * aki_joined
08:37:14  * akirosequit (Ping timeout: 244 seconds)
08:37:14  * aki_changed nick to akirose
10:42:44  * aki_joined
10:43:42  * akirosequit (Ping timeout: 264 seconds)
10:43:43  * aki_changed nick to akirose
10:58:39  * AtumTjoined
11:20:23  * jmdyckjoined
11:33:23  <jmdyck>ryzokuken: What would an invocation of AddBoundMethod look like?
11:34:56  <ryzokuken>jmdyck: you mean the instructions?
11:35:44  <ryzokuken>The call should look like `AddBoundMethod(collator, compare)` or sth.
11:35:59  <ryzokuken>Which does the common set of things:
11:37:17  <ryzokuken>Check if [[BoundXyz]] exists on object x, if it doesn't, make a new one, set the slot, return the method.
11:37:25  <ryzokuken>If it does exist, just return it.
11:38:50  <jmdyck>How would AddBoundMethod know which slot to check and how to 'make a new one'?
11:57:38  <ryzokuken>jmdyck: sorry I didn't get you.
11:58:54  <ryzokuken>The xyz method is supposed to be stored on object x as an internal slot named [[BoundXyz]].
12:01:40  <ryzokuken>The new method is described in an entirely new section in the spec.
12:02:06  <ryzokuken>For instance, I just came back from implementing those in V8 😅
12:02:17  <ryzokuken>(adding a few more in the next few days)
12:03:22  <ryzokuken>It's always two methods, one of which is always the exact same thing. (Thus, refactor that common logic into AddBoundMethod)
12:49:29  * aki_joined
12:51:12  * akirosequit (Ping timeout: 272 seconds)
12:51:13  * aki_changed nick to akirose
12:56:50  <jmdyck>Well, what does the definition of AddBoundMethod look like then?
13:05:43  <ryzokuken>jmdyck: did you check out the three links?
13:06:33  <ryzokuken>They're all more or less the same.
13:06:47  <ryzokuken>> 5:28 PM <ryzokuken> The xyz method is supposed to be stored on object x as an internal slot named [[BoundXyz]].
13:07:14  <ryzokuken>> 5:07 PM <ryzokuken> Check if [[BoundXyz]] exists on object x, if it doesn't, make a new one, set the slot, return the method.
13:12:11  <jmdyck>Yup, I checked out the links.
13:16:32  <ryzokuken>Weren't they super similar?
13:17:13  <ryzokuken>jmdyck: I picked this up because while actually writing the code for all these, it felt very redundant.
13:18:17  <jmdyck>They're similar in structure, but different in particulars. It's not clear to me how your proposed op would abstract out the similar structure, and how the different particulars would manifest.
13:20:37  <ryzokuken>jmdyck: hmm, okay.
13:21:05  <ryzokuken>Gimme an hour or so, I'll give a sample.
13:25:37  <jmdyck>no rush
13:52:40  * ephemera_quit (Ping timeout: 268 seconds)
14:00:43  * ephemera_joined
14:00:46  * gibson042joined
14:27:18  * ephemera_quit (Remote host closed the connection)
14:27:54  * ephemera_joined
14:28:28  * ephemera_quit (Remote host closed the connection)
14:29:02  * ephemera_joined
14:37:41  * gibson042quit (Ping timeout: 268 seconds)
14:52:15  * gibson042joined
14:52:58  * cloudshujoined
14:56:18  * akirosequit (Ping timeout: 264 seconds)
14:57:17  * akirosejoined
17:04:45  * aki_joined
17:05:41  * akirosequit (Ping timeout: 268 seconds)
17:05:41  * aki_changed nick to akirose
19:11:45  * aki_joined
19:13:08  * akirosequit (Ping timeout: 276 seconds)
19:13:09  * aki_changed nick to akirose
20:38:07  <ryzokuken>jmdyck: https://gist.github.com/ryzokuken/78ef8786748861727402a359d9d6f039
20:38:30  <ryzokuken>I jotted this down really quick, if there are errors (there will probably be quite a few), let me know.
20:38:36  <ryzokuken>sorry for taking so long.
20:40:40  <ljharb>ryzokuken: i'm pretty sure it'd not be great to have a dynamically named slot, and a slot that could be present on any arbitrary value
20:40:57  <ljharb>at the moment i believe they're all statically named, and also the same kind of thing always has the same slots
20:41:34  <ryzokuken>but some slots might not hold anything, right?
20:42:42  <ljharb>they'd all be explicitly set to something, albeit ~empty~ or undefined or null, sure
20:43:00  <ryzokuken>I guess we could expect the corresponding slot to exist on said class if you're binding a method to it.
20:43:24  <ryzokuken>because before I made a CL for it, v8 had been doing this all JS-style.
20:43:24  <ljharb>then you'd have to check for that
20:43:32  <ljharb>sure, but that's the implementation detail
20:43:40  <ryzokuken>hmm, true.
20:43:43  <ljharb>internal slots are meant to be a spec fiction
20:44:08  <ryzokuken>yeah, learned that the hard way 😅
20:44:59  <ryzokuken>ljharb: interesting. I get you point, but I guess we could make something like this work if all the loopholes were looked into.
20:45:43  <ljharb>lol that's probably true about lots of things :-p
20:46:12  <ryzokuken>That said, I have no idea how big a priority it is to avoid repetition.
20:47:03  <ryzokuken>I've made three CLs for it so far, 4-5 more to go, and it's already tiresome to write code which is "close enough but yet not the same".
20:47:13  <ryzokuken>That's the original motivation for all this.
21:18:15  * aki_joined
21:19:19  * akirosequit (Ping timeout: 244 seconds)
21:19:19  * aki_changed nick to akirose
22:28:32  * mattijs_joined
23:21:30  * mattijs_quit (Ping timeout: 264 seconds)
23:23:54  * dpkquit (Ping timeout: 264 seconds)
23:24:21  * akirosequit (Ping timeout: 244 seconds)
23:25:23  * dpkjoined
23:26:03  * akirosejoined
23:28:29  * mattijs_joined
23:28:42  * mattijs_quit (Client Quit)