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

所有api的__doc__属性应该被填充,为IDE智能提示准备 #997

Open
kebiao opened this issue Jan 15, 2019 · 0 comments
Open

所有api的__doc__属性应该被填充,为IDE智能提示准备 #997

kebiao opened this issue Jan 15, 2019 · 0 comments
Assignees
Milestone

Comments

@kebiao
Copy link
Collaborator

@kebiao kebiao commented Jan 15, 2019

pyscript文件夹下建立一个头文件, 命名为
py_docs.h:

PyDoc_STRVAR(createCellEntity_docs,
"sha3_512([data]) -> SHA3 object\n\
\n\
Return a new SHA3 hash object with a hashbit length of 64 bytes.");

PyDoc_STRVAR(createCellEntityInNewSpace_docs,
"sha3_512([data]) -> SHA3 object\n\
\n\
Return a new SHA3 hash object with a hashbit length of 64 bytes.");

然后将所有api的英文描述写入,PyDoc_STRVAR。
未来如果有其他文档资源, 当前可以通过api文档生成这个py_docs.h

ENTITY_METHOD_DECLARE_BEGIN(Baseapp, Entity)
SCRIPT_METHOD_DECLARE("createCellEntity", createCellEntity, METH_VARARGS, 0, createCellEntity_docs)
SCRIPT_METHOD_DECLARE("createCellEntityInNewSpace", createCellEntityInNewSpace, METH_VARARGS, 0, createCellEntityInNewSpace_docs)

@kebiao kebiao added this to the 2.x milestone Jan 15, 2019
@kebiao kebiao self-assigned this Jan 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.