Path: utzoo!utgpu!jarvis.csri.toronto.edu!clyde.concordia.ca!uunet!cs.utexas.edu!usc!zaphod.mps.ohio-state.edu!mips!apple!fox!portal!cup.portal.com!pkturner From: pkturner@cup.portal.com (Prescott K Turner) Newsgroups: comp.lang.c++ Subject: arg declaration vs. init expression Message-ID: <25246@cup.portal.com> Date: 21 Dec 89 05:42:51 GMT Organization: The Portal System (TM) Lines: 21 I have a question about what may be a syntactic ambiguity in C++. This occurs partly because the Draft Reference Manual no longer prohibits redundant parentheses in declarators. What happens is that something between parentheses following a declarator can be either the expression-list of an initializer or the argument-declaration-list of a function declarator. For example: struct S { S(int); }; void foo() { int y; S x(int(y)); // int(y) can be an argument declaration or an expression } Has a resolution for this been proposed? The 2.0(+?) version of cfront I'm using interprets int(y) as an expression. -- Prescott K. Turner, Jr. 13 Burning Tree Rd., Natick, MA 01760 USA (508) 653-0357 UUCP: ...sun!cup.portal.com!pkturner Internet: pkturner@cup.portal.com