Topic: Initialization syntax for built-in types.
Author: jean@paradim.UUCP (Jean Pierre LeJacq)
Date: 14 Aug 91 20:03:57 GMT Raw View
Section 8.4 of the ARM shows three alternate syntaxes for
initialization. The commentary as well as the reference
then show the "expression-list" syntax used for built-in
types.
int i(1);
int f(int);
int a = 2;
int b = f(a);
int c(b);
None of my compilers (Borland, cfront, g++, Oregon) support the
"expression-list" syntax for built-in types, only the
"assignment-expression" syntax. Are they all incorrect as I
believe they are or am I missing something?
----
Jean Pierre LeJacq
Paradigm Software telephone: 203 295 8185
34 Millstone Drive uucp: uunet!paradim!jean
Marlborough, CT 06447-1524 internet: jean%paradim@uunet.uu.net
Author: dsouza@gwen.cad.mcc.com (Desmond Dsouza)
Date: 15 Aug 91 19:06:12 GMT Raw View
--
-------------------------------------------------------------------------------
Desmond D'Souza, MCC CAD Program | ARPA: dsouza@mcc.com | Phone: [512] 338-3324
Box 200195, Austin, TX 78720 | UUCP: {uunet,harvard,gatech,pyramid}!cs.utexas.edu!milano!cadillac!dsouza
Author: steve@taumet.com (Stephen D. Clamage)
Date: 16 Aug 91 20:39:02 GMT Raw View
jean@paradim.UUCP (Jean Pierre LeJacq) writes:
|Section 8.4 of the ARM shows three alternate syntaxes for
|initialization. The commentary as well as the reference
|then show the "expression-list" syntax used for built-in
|types.
| int i(1);
| ... etc
|None of my compilers (Borland, cfront, g++, Oregon) support the
|"expression-list" syntax for built-in types, only the
|"assignment-expression" syntax. Are they all incorrect as I
|believe they are or am I missing something?
This is a recent addition to the language. I don't know of any
current compiler (including AT&T release 2.1) which yet supports it.
--
Steve Clamage, TauMetric Corp, steve@taumet.com