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

Swift Package Manager Support #165

Merged
merged 11 commits into from
Jul 10, 2023
Merged

Conversation

lukepistrol
Copy link
Contributor

@lukepistrol lukepistrol commented May 30, 2022

Swift Package Manager

Swift's package manager can build C/C++ sources and use headers to expose functions to Swift. The standard tree-sitter parser project layout just requires a little extra configuration to make it happy.

Grammars with SPM support to this date:

This comes from discussion in the main tree-sitter repo tree-sitter/tree-sitter#1488.

@mattmassicotte
Copy link

@maxbrunsfeld Sorry to be a bother, but how's this one looking?

@lukepistrol
Copy link
Contributor Author

Is there anything that's holding this up?

@bombardier200
Copy link

@tausbn Is this something that you all are looking at doing? I would love to help get this merged or answer any questions as adding SPM supports allows the swift community to also use it.

@bombardier200
Copy link

hey @aryx can you look at this one for python?

@amaanq
Copy link
Member

amaanq commented Jun 29, 2023

imo the swift bindings are fine but the Makefile is a bit unnecessary

Package.swift Outdated Show resolved Hide resolved
Package.swift Show resolved Hide resolved
@mattmassicotte
Copy link

mattmassicotte commented Jun 29, 2023

I have no objections to removing the Makefile. It does make it much easier to use the parser from C, but most C clients have long-since come up with their own non-standardized solutions. Should anyone ever take up this task again, it could be done in a separate PR.

@bombardier200
Copy link

@amaanq Luke should have fixed everything that you requested, could you review this and make sure everything looks good to you?

.gitignore Outdated Show resolved Hide resolved
@amaanq
Copy link
Member

amaanq commented Jul 10, 2023

@amaanq Luke should have fixed everything that you requested, could you review this and make sure everything looks good to you?

One more thing, just the changes to the gitignore aren't needed now

@lukepistrol lukepistrol changed the title Swift Package Manager & C Bindings including Makefile Swift Package Manager Support Jul 10, 2023
@lukepistrol lukepistrol requested a review from amaanq July 10, 2023 21:46
@amaanq amaanq merged commit 53dcc79 into tree-sitter:master Jul 10, 2023
3 checks passed
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

Successfully merging this pull request may close these issues.

4 participants