mikeb@ee.ubc.ca (Mike Bolotski) (05/28/89)
Machine: Sun 3/260 SunOs 4.0.1 g++ version 1.35.1- (1.35.0 patched with May19 and May23 patches posted by Michael Tiemann). Libg++ 1.35.0. make tests . . . g++ -g -O -fchar-charconst -I../g++-include -I. -fstrength-reduce -c tInteger. cc g++ tInteger.o -o tInteger -lg++ -lm g++ -g -O -fchar-charconst -I../g++-include -I. -fstrength-reduce -c twrapper. cc twrapper.cc:14: warning: lazy prototyping frowned upon twrapper.cc:42: warning: lazy prototyping frowned upon twrapper.cc:45: warning: lazy prototyping frowned upon twrapper.cc:76: warning: lazy prototyping frowned upon twrapper.cc:84: warning: lazy prototyping frowned upon In function int main (int, char **): twrapper.cc:295: type `MemoizedInteger' is derived from private `MemoizedInteger Base' *** Error code 1 make: Fatal error: Command failed for target `twrapper.o' I think this occurs because MemoizedInteger does not have a constructor of its own, and it is derived as private from MemoizedIntegerBase. Somehow, the constructor is hidden. Note: the problem did not occur before the May 23 patches. Mike Bolotski, Department of Electrical Engineering, University of British Columbia, Vancouver, Canada mikeb@ee.ubc.ca | mikeb%ee.ubc.ca@relay.ubc.ca ee.ubc.ca!mikeb@uunet.uu.net | ...!ubc-vision!ee.ubc.ca!mikeb
dl@ROCKY.OSWEGO.EDU (Doug Lea) (05/28/89)
Thanks. The following changes are needed to compile under g++-1.35.0+: R>diff -rc2N twrapper.cc~ twrapper.cc *** twrapper.cc~ Thu Mar 30 05:59:46 1989 --- twrapper.cc Sun May 28 08:23:15 1989 *************** *** 195,199 **** } ! class MemoizedInteger : MemoizedIntegerBase { public: --- 195,199 ---- } ! class MemoizedInteger : public MemoizedIntegerBase { public: R>diff -rc2N tgwrapper.cc~ tgwrapper.cc *** tgwrapper.cc~ Sun May 7 06:49:16 1989 --- tgwrapper.cc Sun May 28 08:23:13 1989 *************** *** 127,131 **** #define DEFINE_MEMOIZED_CLASS(TYPE, CLASS_BODY) \ ! class Memoized ## TYPE : Memoized ## TYPE ## Base CLASS_BODY #define DEFINE_WRAPPER_1(TYPE) \ --- 127,131 ---- #define DEFINE_MEMOIZED_CLASS(TYPE, CLASS_BODY) \ ! class Memoized ## TYPE : public Memoized ## TYPE ## Base CLASS_BODY #define DEFINE_WRAPPER_1(TYPE) \