Article View: gnu.g++
Article #135how much of C++ 2.0 does g++ support?
From: Michael Tiemann
Date: Tue, 19 Sep 1989 17:10
Date: Tue, 19 Sep 1989 17:10
58 lines
2272 bytes
2272 bytes
Date: 15 Sep 89 12:00:34 GMT
From: andersnb@nyu.edu (Brian Anderson)
Organization: New York University, Ultracomputer project
Sender: info-g++-request@prep.ai.mit.edu
Can anyone give me a *clear* description of which features of AT&T's C++
2.0 are *not* supported by the current release of g++ (1.35.1-)? My main
concerns are:
a) can new and delete be overloaded?
Yes.
b) does new allow user specified placement?
Yes, but with a different syntax. The AT&T syntax is impossible to do
with an LALR grammar. For GNU C++ you say
char *p = new { London } char[10];
in AT&T C++ you say
char *p = new ( London ) char[10];
You could do this in a header file:
#ifdef __GNUG__
#define NEW(WHERE) new { WHERE }
#else
#define NEW(WHERE) new ( WHERE )
#endif
and then say
char *p = NEW ( London ) char[10];
c) are pure virtual functions allowed?
Yes.
d) can the -> and , operator be overloaded?
Yes and no. You can overload ->, but I have not implemented
overloaded ',' yet.
e) is type safe linkage supported (i.e. is the overload operator
required)?
It is supported. The overload specifier is no longer needed.
Thank you for your help
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Brian G. Anderson |
NYU Ultracomputer Research Project |||
715 Broadway Rm. 1006 |||||
New York, NY 10003 |||||
(212) 998-3346 --- //\ ---
arpa: andersnb@cmcl2 ----/ \----
uucp: {ihnp4,seismo}!cmcl2!andersnb ---- ----
Michael
Technical Details
Message-ID:
<8909191710.AA01547@teacake.sun.com>Path:
arc1-ca.pugleaf.net!utzoo!mnetor!tmsoft!torsqnt!jarvis.csri.toronto.edu!rutgers!apple!gem.mps.ohio-state.edu!tut.cis.ohio-state.edu!SUN.COM!tiemannReferences:
<42061@cmcl2.NYU.EDU>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!tmsoft!torsqnt!jarvis.csri.toronto.edu!rutgers!apple!gem.mps.ohio-state.edu!tut.cis.ohio-state.edu!SUN.COM!tiemann From: tiemann@SUN.COM (Michael Tiemann) Newsgroups: gnu.g++ Subject: how much of C++ 2.0 does g++ support? Message-ID: <8909191710.AA01547@teacake.sun.com> Date: 19 Sep 89 17:10:07 GMT References: <42061@cmcl2.NYU.EDU> Sender: daemon@tut.cis.ohio-state.edu Reply-To: tiemann@sun.com Distribution: gnu Organization: GNUs Not Usenet Lines: 58