crazyguitar/pysheeet

Some suggestions

crazyguitar opened this issue · 7 comments

Can i contribute even I'm still novice but i want to learn more

Thank you

Sure! Any contributions are welcome! You can send pull requests in this project if you have any idea.

I stumbled into your project when I was looking for how to correctly doc. my Python C extensions. Nice , that there is even a separate subject Doc String. Too sad, that it lacks how arguments are documented. Actually, I was looking for how to doc. possibly raised exceptions. (I just implemented a vector.normalize() and it may raise a RuntimeError if vector is too short. - I thought it would be worth to tell Python programmers about this.) ;-)

Hi @scheff173

You mean this project can add some info about the detail of document string in C?

For example (from PEP 7)

#ifndef PyDoc_STR
#define PyDoc_VAR(name)         static char name[]
#define PyDoc_STR(str)          (str)
#define PyDoc_STRVAR(name, str) PyDoc_VAR(name) = PyDoc_STR(str)
#endif

I googled a while to find something authoritative concerning how text of doc. strings should be formatted. This is what I found:

@scheff173

oh! I see. You recommend that this project can add some snippets to guide how to document the Python code, right?

Issue #80 will handle this. Sorry, I am so too recently. I will update this issue soon.

By the way, if you want to know how to write a doc in your C extension, you can refer to socket.c. Actually, I learned a lot of thing from CPython source code. 😃