Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!van-bc!mdivax1!mclaren Newsgroups: comp.sys.amiga.tech Subject: Re: The Pure Bit... Summary: Not just reexcutable Keywords: multitask, reentrant, reexcutable Message-ID: <1990Nov27.033718.288@mdivax1.uucp> Date: 27 Nov 90 03:37:18 GMT References: <1990Nov22.142858.9900@canterbury.ac.nz> <1043@troi.dbaccess.com> Reply-To: mdivax1!mclaren (Gavin McLaren) Organization: Mobile Data International, Richmond, B.C., Canada Lines: 17 Return-Path: Apparently-To: van-bc!rnews In article <1043@troi.dbaccess.com> peter@dbaccess.com (Peter A. Castro) writes: >in article <1990Nov22.142858.9900@canterbury.ac.nz>, cctr120@canterbury.ac.nz (Brendon Wyber, C.S.C.) says: >> If I was writing a program, what would I have to do so that I can say that it >> is `legally' pure? > It must be "re-entrant" code, with no static data. The manual says it must be reexecutable an reentrant. I concede, however, that reexecutable implies rentrant. Some programs cannot run twice in a row without reloading, because they contain initialized data that does not get reloaded. The uninitialized data can be allocated to each copy of the program, but they share the initialized stuff... Thus I think the requirement is a little less restrictive than no static variables. After all, all globals are allocated statically. However, there are no initialized static variables allowed.