Replies: 1 comment
-
Some Python builtins (e.g. enums) use a single underscore for implementation-specific bits, so having that policy as a default is unfortunately not negotiable. But I would be open to moving it into a separate method like |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Right now, stubgen considers names ending in (single) underscores private;
nanobind/src/stubgen.py
Lines 788 to 799 in 109af19
This seems to go against common practice. For example, PEP8 states:
It's easy enough to override in my own stub generation (override
StubGen.put
), but I do think it's poor default behavior. As a less-preferred option, one could make the private-name predicate customizable.Beta Was this translation helpful? Give feedback.
All reactions