Path: utzoo!attcan!uunet!pantor!richard From: richard@pantor.UUCP (Richard Sargent) Newsgroups: comp.lang.c++ Subject: Re: information hiding Message-ID: <14.UUL1.3#5109@pantor.UUCP> Date: 29 Jun 89 15:23:51 GMT References: <7709@spool.cs.wisc.edu> Organization: Pansophic Systems Inc, Graphics Product Company Lines: 23 Regarding the question of C++ header files containing the public and private information both, the information *has* to be there for the compiler. However, you can alleviate the problems caused by extracting only the public portions and publishing those as adjunct to man pages or whatever. This can be fairly automated via judicious use of "#if !defined(EXTRACT)" directives throughout and use 'make' and the preprocessor to fairly automatically extract the public portions. Of course, you can write your own utilities to do whatever you want ... Naturally, this does not solve the 'problem' of someone attempting to learn more about a class than they should, but I doubt anything will, short of a completely closed and regulated programming/development environment (and you thought editor wars were extreme!). It will, however, allow people to easily learn what they do need to know without 'burdening' them with the stuff they shouldn't know. As with everything involving C/C++, it all comes down to discipline in the end. Richard Sargent Internet: richard@pantor.UUCP Systems Analyst UUCP: uunet!pantor!richard