-
Notifications
You must be signed in to change notification settings - Fork 699
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
Support sorting items by name #2949
Comments
Maybe |
I'm using the bindgen cli, so a callback won't work. I don't really care about the exact order in which items are sorted for as long as the output doesn't depend on the order of items in the C source and is robust against additions and removals of items in the C source. |
This issue makes me think that we need some standard way to turn The easiest thing that comes to mind is probably being able to specify a command that can communicate with bindgen via stdio, but that means that we need to agree on the input and output format and maintain it under our stability guarantees. Another option would be to allow bindgen to dynamically load a library that does this for us. The advantage there is that we can "just" use the C ABI for everything but at the same time it means that you cannot just write a bash script for it. |
Currently there is only
--sort-semantically
to sort by item type. Sorting by name would make it easier to diff bindings generated for different platforms that have different order of items in their headers.The text was updated successfully, but these errors were encountered: