Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Swift support #506

Open
skvadrik opened this issue Nov 22, 2024 · 2 comments
Open

Add Swift support #506

skvadrik opened this issue Nov 22, 2024 · 2 comments

Comments

@skvadrik
Copy link
Owner

Requested in https://www.linux.org.ru/news/development/17798640?cid=17800037

@PolarGoose
Copy link
Contributor

By the way, is there a use case for support of such high-level languages? For instance, wouldn't it be better to use ANTLR?
It is amazing that re2c generates a static state machine without any memory allocation. I can use it on a microcontroller. But when it comes to languages like Java, does it matter?

@skvadrik
Copy link
Owner Author

skvadrik commented Dec 1, 2024

Perhaps there is a use case, since people request it. For Swift in particular, let's ask @data-man .

For some high-level languages like OCaml and Haskell re2c may be a performance benefit (e.g. Haskell is famous for its parser combinators, but they are not as fast as a combination of lexer generator and LALR parser). For languages like JS or Python my expectation is that decent performance can only be achieved with C/C++/Rust libraries that have high-level bindings, so re2js/re2py cannot compete there. But some users still want re2c for its syntax, as in case of JavaScript: #420.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants