Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!purdue!decwrl!ucbvax!SUN.COM!wmb From: wmb@SUN.COM Newsgroups: comp.lang.forth Subject: Re: Encapsulation and visibility in Forth Message-ID: <8908041409.AA10840@jade.berkeley.edu> Date: 3 Aug 89 22:15:59 GMT Sender: daemon@ucbvax.BERKELEY.EDU Reply-To: Forth Interest Group International List Organization: The Internet Lines: 13 One technique I have used: For each "module", create two vocabularies, one for the visible words in the module, and one for the private words. The private vocabulary is contained within the public vocabulary. That way, you see the private words only if you want to. For example, I wrote a DOS-compatible file system in Forth. The interface words for the file system were contained within a vocabulary "dosfiles" . Within the "dosfiles" vocabulary, there was another vocabulary named "doshidden" , which contained the implementation factors. Mitch