Skip to content

Conversation

@garyb
Copy link
Member

@garyb garyb commented Aug 27, 2022

Can make the initial release after this I think 🙂

Copy link

@sigma-andex sigma-andex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@JordanMartinez
Copy link
Contributor

JordanMartinez commented Aug 27, 2022

In light of the purs-backend-es making it now easier to implement other backends, should we still not use the JS prefix on the namespace? While there may not be languages that use Promise as a name now, will there be in the future?

@garyb
Copy link
Member Author

garyb commented Aug 27, 2022

In light of the purs-backend-es making it now easier to implement other backends

It does? It seems pretty ES/JS specialised to me, it's even in the name 😄... but no, I don't think that would change anything given the points I raised in the other thread. Perhaps the two most compelling:

  1. This library is interop glue, not a library people are going to need otherwise. If they're using it, then they're already going to be depending on other JS-specific libraries like the purescript-web stuff.
  2. The library is called js-promise, so even if other backends wanted to implement a Promise module and can't provide a suitable implementation for the foreign declarations in here, they could just do like a native-promise library or whatever and use the Promise name there still.

@JordanMartinez
Copy link
Contributor

It does? It seems pretty ES/JS specialised to me, it's even in the name

Not quite. The repo is designed to store two projects: the general backend optimizer and the code-generator specific to JavaScript. The idea was that other backends can be implemented if one writes a codegenerator for a target language. After that's done, one just needs to implement the FFI for core libraries and you've got yourself a working backend. I'm not sure how hard that is to do in practice, but I imagine it's much simpler than what backend maintainer had to do previously.

Regardless, your other points still stand AFAICT.

@garyb garyb merged commit 33dbb1e into master Sep 1, 2022
@garyb garyb deleted the prepare branch September 1, 2022 19:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants