Skip to content

Documenting methods - obj.method or obj.method() #7

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

Closed
enryH opened this issue Feb 8, 2021 · 1 comment
Closed

Documenting methods - obj.method or obj.method() #7

enryH opened this issue Feb 8, 2021 · 1 comment

Comments

@enryH
Copy link
Contributor

enryH commented Feb 8, 2021

Should we document object methods or module functions using obj.method (module.function) or obj.method() (module.function()).

I prefer the former, Rita used the ladder.

notatin arguments
obj.method
module.function
as function are object itself (first-class citizens), they can be assigned. They are callable (or callable()!) which describes them.
obj.method()
module.function()
Suggests directly that they are callable and distinguishes them from other attributes.

I have seen both in the official documentation. I just think it will be good to be consistent.

Any opinion or good reference to elaborate the issue?

@enryH
Copy link
Contributor Author

enryH commented Apr 21, 2021

transfered to new repo: Center-for-Health-Data-Science#3

@enryH enryH closed this as completed Apr 21, 2021
enryH pushed a commit that referenced this issue Jun 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant