Buesching, Logan J wrote: > 1.) I had a couple questions on what the standard or “best practice” for > documenting a few things.
> When I see something in the source code that is: > > RETURN LONG(val); Yes, there's no "long" in the PHP manual, at least it's not supposed to be. Internally we've "long", but to the user we only use the term "integer". > 2.) At the bottom of all the XML sheets, it says > “sgml-default-dtd-file:../../../../manual.ced”… where is that file, or > if it has moved, where to? If it has moved, should I also update all of > my files to reflect those changes? No idea, something for dinosaurs which a "dinosaur" must answer. *hide* > 3.) There are a few things that are compiled conditionally and I was > wondering about how to document them. In the function with > posix_getpgid it says that it always returns false if the system doesn’t > support it. Is that true? Because it looks as though it doesn’t even > create a PHP function for it if it even exists: > > > > *#ifdef* HAVE_GETPGID Yep, this usually means if there's a funcion getpgid() #ifdef HAVE_FOO_H would mean if there's foo.h etc. What you're looking at is just an error condition (man getpgid): On success, setpgid() and setpgrp() return zero. On error, -1 is returned, and errno is set appropriately. > > PHP_FUNCTION(posix_getpgid) > { > *long* val; > > *if* (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &val) > == FAILURE) { > RETURN_FALSE; > } > > *if* ((val = getpgid(val)) < 0) { > POSIX_G(last_error) = errno; > RETURN_FALSE; > } > RETURN_LONG(val); > } > > *#endif* Regards, -- Michael