pycapnp icon indicating copy to clipboard operation
pycapnp copied to clipboard

lower_case_with_underscores vs mixedCase/camelCase

Open chaoflow opened this issue 9 years ago • 2 comments

For struct field names capnproto does not allow lower_case_with_underscores but recommends camelCase (mixedCase in pep8:

"Cap'n Proto declaration names should use camelCase and must not contain underscores. (Code generators may convert names to the appropriate style for the target language.)"

Did you consider a translation of lower_case_with_underscores to mixedCase? For me this seems desirable to be in line with pep8.

chaoflow avatar Nov 16 '16 12:11 chaoflow

We are experimenting with name translation: https://github.com/ternaris/pycapnp/commit/dd6fc2c30e90af8d91ece504233222cbdd8f97e0

That branch is most likely going to be rebased frequently. There might be a pull request at some point.

chaoflow avatar Feb 09 '17 02:02 chaoflow

Anything new with this (I assume not since this is five years old). This forces the writer to not write in PEP8 in Python :(

KimiNewt avatar Jul 28 '22 12:07 KimiNewt