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

Doc: add info about litgen binding generator #780

Merged
merged 1 commit into from
Dec 8, 2024

Conversation

pthom
Copy link
Contributor

@pthom pthom commented Nov 7, 2024

Hi,

I am the creator of litgen, an automatic binding generator for pybind11 which generates documented C++ binding code together with python stubs.

Recently it was updated to also support nanobind (with help from @davidlatwe)

This PR proposes to mention litgen in the nanobind documentation, in two parts:

  • 9454073: In the building.rst page, I added a section called "Generating binding code automatically," similar to what’s in the pybind11 documentation, to explain litgen’s role in generating documented, discoverable bindings for both pybind11 and nanobind.
  • 63f3386: In the porting.rst page, I included a link to the litgen documentation, highlighting examples that compare pybind11 and nanobind binding code side by side. This should be helpful for users looking to understand key differences.

Feel free to discard the part in the porting.rst page if you feel it does not bring enough value.

Thanks!

Pascal Thomet

@pthom pthom mentioned this pull request Nov 7, 2024
@pthom
Copy link
Contributor Author

pthom commented Dec 2, 2024

Hello Wenzel ( @wjakob ),

Could you have a look at this PR and tell me your opinion (or close it if you feel it does not fit here).

Cheers,

Pascal

@wjakob
Copy link
Owner

wjakob commented Dec 4, 2024

Hi @pthom,

I think it's useful to mention it somewhere in the documentation, but I would like to do so outside of the main tutorial-style introduction. I prefer people to know how to write bindings themselves and not give the impression that going through an automated tool is the officially recommended way to use nanobind. I think what you are doing is great and that you can understand my viewpoint.

@pthom
Copy link
Contributor Author

pthom commented Dec 5, 2024

Hi Wenzel,

Of course, I get your point!

I think this means that:

  • adding info about it in "building.rst", since it is also part of the tutorial style intro
  • adding info about it in "porting.rst" is not a good place to present it

So, I do not know where it could be added.

I thought about adding a dedicated page in the advanced section, but it would be a bit cumbersome, since this page would be mostly empty (and not really related to the advanced subjects).

I think I'll add an item to the discussions on this repo, and it might be enough.

@pthom
Copy link
Contributor Author

pthom commented Dec 5, 2024

Feel free to close this PR

@wjakob
Copy link
Owner

wjakob commented Dec 8, 2024

What about an FAQ entry? E.g. "Is there a tool to generate nanobind bindings automatically"?

@pthom
Copy link
Contributor Author

pthom commented Dec 8, 2024

What about an FAQ entry? E.g. "Is there a tool to generate nanobind bindings automatically"?

Thanks for the suggestion! I just did this.

@wjakob wjakob merged commit 923e0ad into wjakob:master Dec 8, 2024
31 checks passed
@wjakob
Copy link
Owner

wjakob commented Dec 8, 2024

Thanks!

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.

2 participants