Hi

> I would like to know how, in general, people document (in their code
> comments) the return value from a function, when that return value is
> actually based on something that happens in a different function.
>
> For instance, if I have a function named F1(), and its return value is
> the return value from function F2():
>
> bool F1()
> {
>     // do some stuff
>    return F2();
> }
>
> How should that be documented?  Would you say that the return value from
> F1() is the value that F2() returns (most accurate, but not very
> informative), or, would you spell out in words what it is that F2()
> returns? (might become inaccurate when F2() changes, but is more
> informative).

Why do you need to document it unless you're generating something like 
Doxygen docs? A function is usually a good docment for itself if well named.

Regards
Paul

Paul Grenyer
email: [EMAIL PROTECTED]
web: http://www.paulgrenyer.co.uk
Aeryn: http://www.aeryn.co.uk

Metal. Is there anything else? 


_______________________________________________
msvc mailing list
[email protected]
See http://beginthread.com/mailman/listinfo/msvc_beginthread.com for 
subscription changes, and list archive.

Reply via email to