This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
History behind catgets (POSIX spec), and propagating "const" qualifiers.
- From: Carlos O'Donell <carlos at systemhalted dot org>
- To: libc-alpha <libc-alpha at sources dot redhat dot com>
- Date: Thu, 28 Jul 2005 12:41:23 -0400
- Subject: History behind catgets (POSIX spec), and propagating "const" qualifiers.
libc-alpha,
WRT POSIX:
Does anyone know any history behind catgets, and why it returns a "char
*" as opposed to returning say "const char *". It it usefull to make
the internal buffer accessible for user programs to modify?
While I'm building and working on NPTL stuff for hppa, I'm also
reviewing a handful of the "cast discards qualifiers from pointer target
type." As the compiler gets smarter I'm sure it's going to do a better
job of propagating optimizations knowing that things are truly "const."
Cheers,
Carlos.