Keywan: But chrome.extensions.getUrl for example is NOT asynchronous
Sohr: To sum up, the chrome API calls are implemented as a shim in JS
Obermuller: Which posts messages to the UI to process it
Figuroa: And hopefully give back results
Meddock: Anything not clear yet
Sheehy: Is there a url for channel logs?
Schleig: Have you ever used Symbol data type in ES6?
Locy: I’m not sure why Symbol exists.
Longley: What would be a safe split character to use ?
Falasco: Trucchi: the limitation on the js side is I can’t control the flow of code and/or pause/sleep
Okie: I saw Symbol the other day. I didn’t get it at all.
Okie: There’s a lot of stuff I don’t get though, and I’m a noob, so that doesn’t mean much
Siskind: The do***ent says it can be used as an identifier. But what’s the benefit of using that instead of String?
Trucchi: Dadada: and that implementation has no generators? what about regenerator? or does the nature of what you’re doing prevent from using something like that?
Trucchi: Dadada: ’cause it actually sounds like a great use-case for CSP channels, but that also relies on generators
Jeffress: Trucchi: he’s implementing a synchronous IO call
Jeffress: Trucchi: generators won’t help
Jeffress: Dadada: you’ll have to provide a synchronous getUrl call from the webkit2gtk side
Delagado: Trucchi: well I tried the concept for a generator controlling the main flow of the js code in node –harmony, but it fails for subfunctions/subcalls
Trucchi: Dash: well if the whole thing were wrapped. though that’s ugly
Jeffress: Trucchi: nope, wouldn’t do
Galaz: Trucchi: I can’t inline every function
Jeffress: Kkiro: if two different libraries create symbols with the same name, they aren’t equal
Rumschlag: Trucchi: a function can call a function can call a function.
Jeffress: Kkiro: this pevents accidental collisions
Zuniga: Dash: What if libraries use Symbol.forkey?
Jeffress: Kkiro: then that’s global
Jeffress: Kkiro: but still not equal to any string
Goggans: Dadada: why must the function be synchronous in the first place?
Jeffress: Dekok: because that’s how the chrome extensions api works
Campusano: Dadada: can’t you CPS it, and then the ordering doesn’t matter?
Jeffress: Dadada: getURL seems like an odd example though, since it doesn’t do IO
Pepitone: I think nobody will intend to allow arbitrary string to be mixed in ‘type’ property or something
Munet: Dash: I’m not sure if they’re running a bunch of arbitrary JS code, or just generating JS code that interacts with the API. In the latter case, it would be pretty trivial to just CPS everything
Westerhoff: Dekok: because the chrome.* API is JUST like that, I didn’t create it and I can’t change 100000 extensions
Jeffress: Dadada: which calls actually do sync IO?
Basse: Dekok: 98% of chrome.* calls are asynchronous, but 2% are important and not
Schwimmer: Dekok: the goal is to make the average chrome extension run
Jeffress: Dadada: getURL doesn’t do IO, does it.
Welti: Dash: no, it returns a string
Jeffress: Dadada: lots of things that do IO return strings, that’s not the question :
Jeffress: Dadada: what methods do sync IO?
Gruett: Dadada: oh, right, you can’t do that without making message p***ing synchronous.
Trabazo: Dash: I admit I don’t get why your question is relevant
Banco: Dadada: dash probably means that things that don’t have any effect on or query your UI layer shouldn’t be a message to your UI layer. And the things that do are probably asynchronous.
Bakalars: Dekok: yeah, that would require me to extend webkit itself, I would have a tough time getting this patch accepted, and even to write it :- not done C++ in years and not really understood the message p***ing when I looked at it for 20 minutes today