boot.janet docstring improvements#1764
Conversation
Janet for Mortals chapter 8 discusses this behavior for some built-in functions.
|
Regarding the text:
Please note that on the same linked page, the disclaimer from the author:
Also please note that the author of the text says:
via: https://janet.guide/ On a side note, the term "dictionary" is used on at least one page in the website docs to refer to both tables and structs. There is also a function named It is true that the existing docstrings for |
5de69ee to
54feba2
Compare
Ah I did miss that note, good catch, thanks.
I should mention I'm a bit fan of the book - the author did a fantastic job (despite their claims that nothing there should be considered "educational" xD)
Thanks for the link, interesting. It would seem best to confirm whether or not that's intended behavior for those symbols before changing their documentation.
This is also something I was looking into - but figured I'd start small and leave it for future discussion. In general (personal opinion) I find these qualities really help when using reference documentation:
Another thing on indicative mood:
|
|
Other here, I prefer imperative mood as the docs can then be used in place of the calls or function signatures. |
|
I can appreciate wanting consistency for certain aspects of the docstrings, but practically speaking I'm not sure how well that can be made to hold up over time. FWIW, my sense regarding what seems to have been valued for docstrings in janet itself include (not necessarily in this order):
This is just what comes to mind when I think back over the PRs I've seen. Ultimately it's not my call though :) |
Hi! First contribution to Janet. It has been a very nice language to use.
Please let me know if you have any thoughts on these proposed changes or if changes like this are welcome / unwelcome.
For third person indicative mood...
This style is used by both Ruby and Lua and to me reads clearer:
For polymorphic compare...
Janet for Mortals chapter 8 discusses this behavior for some built-in functions.
https://janet.guide/tables-and-polymorphism/
Later in that chapter...
However, tested working for structs:
Thanks!