Topic: Order of destruction for local objects?


Author: carl@ozemail.com.au
Date: Wed, 23 Nov 1994 09:50:08 GMT
Raw View
Does ANSI C++ specify a guaranteed order of destruction for objects with local scope?
I have looked in the ARM and C++ report, but cannot find any discussion of it.

Example:

void fn()
{
   CObject A1, A2, A3;
} // Which is destructed first - A1, A3, or undefined?

Carl Hyslop - C/C++, Asm, OS/2, Win