Mercurial > ~dholland > hg > ag > index.cgi
view anagram/support/suppinst.cpp @ 6:607e3be6bad8
Adjust to the moving target called the C++ standard.
Apparently nowadays it's not allowed to define an explicit copy
constructor but not an assignment operator. Consequently, defining the
explicit copy constructor in terms of the implicit/automatic
assignment operator for general convenience no longer works.
Add assignment operators.
Caution: not tested with the IBM compiler, but there's no particular
reason it shouldn't work.
author | David A. Holland |
---|---|
date | Mon, 30 May 2022 23:46:22 -0400 |
parents | 13d2b8934445 |
children |
line wrap: on
line source
/* * AnaGram, A System for Syntax Directed Programming * Copyright 1997-1999 Parsifal Software. All Rights Reserved. * Copyright 2006 David A. Holland. All Rights Reserved. * See the file COPYING for license and usage terms. * * suppinst.cpp - template instantiation */ #include "agarray.h" #include "agbaltree.h" #include "agnotify.h" #include "agstring.h" #include "register.h" //#define INCLUDE_LOGGING #include "log.h" #include "agarray-imp.h" #include "agbaltree-imp.h" #include "agstack-imp.h" #include "register-imp.h" //////////////////////////////////////////////////////////// #ifdef __IBMCPP__ /* last pruned 20061022 */ /* last tested 20061022 */ // balanced tree #pragma define(AgBalancedTree<int>) // stack #pragma define(AgStack<AgNotificationActionBase *>) #pragma define(AgStack<AgNotifierBase*>) #pragma define(AgStack<AgString>) #pragma define(AgStack<char>) #pragma define(AgStack<void *>) #endif /* __IBMCPP__ */ //////////////////////////////////////////////////////////// #ifdef __WATCOM_CPLUSPLUS__ /* last pruned 20061022 */ /* last tested who-knows-when */ // Watcom 10.6 doesn't seem to have any mechanism for forcing template // expansions. // balanced tree typedef AgBalancedTree<int> foo1; #endif /* __WATCOM_CPLUSPLUS__ */ //////////////////////////////////////////////////////////// #ifdef _MSC_VER /* last pruned 20061022 */ /* last tested who-knows-when */ // balanced tree template class AgBalancedTree<int>; // stack template class AgStack<AgString>; template class AgStack<char>; template class AgStack<void *>; #endif /* _MSC_VER */ //////////////////////////////////////////////////////////// #ifdef __GNUC__ /* last pruned 20061022 */ /* last tested 20061022 */ // balanced tree template class AgBalancedTree<int>; // stack template class AgStack<AgNotificationActionBase *>; template class AgStack<AgNotifierBase *>; template class AgStack<AgString>; template class AgStack<char>; template class AgStack<void *>; #endif /* __GNUC__ */ //////////////////////////////////////////////////////////// #ifdef __BCPLUSPLUS__ /* last pruned 20061022 */ /* last tested who-knows-when */ #pragma option -Jgd // balanced tree typedef AgBalancedTree<int> foo11; // stack typedef AgStack<AgString> foo21; typedef AgStack<char> foo22; typedef AgStack<void *> foo23; #endif /* __BCPLUSPLUS__ */