-
Notifications
You must be signed in to change notification settings - Fork 410
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
"integer representing the status" is insufficient documentation #694
Comments
@TELunus thank you for your issue... As you point out,
So I am afraid I do not understand your See the very simple sample program on how this can be used... If you are using Does this answer your question? Thanks... |
Thanks @geoffmcl for your help. I have managed to write a program using it. I don't think I pointed out what you're saying I pointed out. Particularly I hadn't found any universal information about return values, only information specific to the parsing functions. The information I pointed to also said nothing about severe errors or negative numbers. Perhaps, since that documentation does exist elsewhere, saying that it's useless is a little strong. But saying merely that it returns "An integer representing the status", and forcing you to dig for the documentation about the status convention, still seems less than excellent. It would be much more helpful to mention in that location what the values mean. Doing so would also increase consistency in the documentation, since the parsing documentation already says what the values (for the parsing functions) mean. I can imagine that there would be an argument that the extra length or redundancy of information is undesirable, but if that's the case it doesn't make sense that the documentation for the parse functions has that information. In the end I still maintain that there is an issue in the documentation that should be resolved. I hope that helps you understand what my issue is. If not, feel free to ask more questions. |
I should also point out that although this issue has the label "Technical support", what I'm saying is not "I can't figure out how to do this", but instead "The documentation provided does not clearly tell developers how to do this". |
@TELunus I certainly agree the documentation can always be improved... and sorry I misread this a little... and glad you got a program working... As you indicate, in the next section after Diagnostics and Repair, namely Document Parse, which technically should be read before getting to
But still does not mention that they can also return a negative And the next section Document Save Functions returns to the same unhelpful I too guess the creators of the doxygen generated api docs, thus the comments, particularly in Maybe at least the message could be extended to say And I do not know enough about doxygen comments to be able to make that a cross document html link, but maybe that would be possible... What do you think? And would particularly like help from someone understanding more of |
@geoffmcl what you've got there looks to me like it would be good. Alternately perhaps something like this could be put in the diagnostics and repair section:
I would be happy with either of those. |
@TELunus thank you for the feedback, much appreciated, but I do not think we have quite cracked this yet... What do we have now in the documentation? We have six(6) cases of -
Once in section Then we have ten(10) cases of -
This is in 2 sections: Now, as you suggest, we could replace all sixteen cases with a full message -
But somehow, to me that seems far too much repetition - looks ugly... but is fully correct... And remember this is all C comments in the main tidy.h, adding to its size - a file included in every module... and shipped as part of the distribution... Yes I know this is less important today with ever bigger hard-disks, and fast file I/O, file caching... but That is why I chose a shorter sentence, plus a pointing to somewhere else... And since these are separate section pages in the api docs, maybe the full
Then each individual API function, well 15 of the 16 - can have say a simple, short -
Would exclude the one in Testing it all out -
So what do you and others think? Please give some feedback... I am really only 49:51 on this... thanks... |
@geoffmcl I think like you I'm also not very sure which of those two options to take. It sounds like you lean a little toward option 2:
I think I also lean a little toward that option. Should we wait for some more input, or should one of us get started making those changes? |
I see at least two possible solutions:
|
The functions in the category Diagnostics and Repair say they return
This documentation is insufficient to use the result. It seems likely to me that anything other than a 0 is an error. However the parse functions return a 2 for an error, but 1 and 0 are both no error (1 indicates a warning, but that's still not an error). In theory it could even be reversed: 0 is an error, non-zero tells how many good elements there are, for example. Without knowing how the integer represents the status, it's useless.
The text was updated successfully, but these errors were encountered: