community.borland.com

Article #15685: REENTRANT CODE

 Technical Notes Database

TN685D.txt   REENTRANT CODE
Category   :Pascal
Platform    :All
Product    :Turbo Pascal  4.0+

Description:
Q. How do I write reentrant code in Turbo Pascal?
A. If a routine follows these rules, it is reentrant:

      1. All data is allocated on the stack.
      2. The routine doesn't use any global variables.
      3. The routine can be interrupted at any time without
         affecting the execution of the routine.
      4. The routine doesn't call any other routines that are
         not reentrant (e.g., DOS I/O).


Reference:


7/16/98 4:35:34 PM
 

Last Modified: 01-SEP-99