what is reentrant function?
You list requirements of a reentrant function, not a definition. A reentrant function must be able to be re-entered at any time while executing. Thus it may not use static data. You either pass in the context upon which to operate or use stack based variables. The use of stack based variables causes some performance issues with C on the 8051 since a reentrant stack must be created and used. - Mark
Nice definition. I'll add one more thing. Reentrant functions are not necessarily recursive. A recursive function is one that calls itself (directly or indirectly). Jon