Topic: Overloading new[]
Author: temple@actcom.co.il (Berkowitz)
Date: Mon, 19 Dec 1994 07:36:41 GMT Raw View
Subject: How to override new[] in ANSI C++
In Stroustrop's C++ second Edition, he describes the introduction
of the capability to override the new[] operator. In the ANSI C++
description this doesn't exist, so I assume that is why I can't
seem
to do
static void * new[](size_t Size);
with my compiler (Sparkworks on SUNOS and on SOLARIS).
Is there any way with ANSI C++ to effectively override the new
operator
for arrays. (We are doing some home-grown persistent
storage, and need
to trap all calls to new and new[], but we
don't think it advisable to
override the global new operator).
Thanks,
Larry
Author: temple@actcom.co.il (Berkowitz)
Date: Mon, 19 Dec 1994 07:32:05 GMT Raw View