[Bug c++/13736] [3.4/3.5 Regression] Parser confused on compound casts
giovannibajo at libero dot it
gcc-bugzilla@gcc.gnu.org
Mon Jan 19 12:19:00 GMT 2004
------- Additional Comments From giovannibajo at libero dot it 2004-01-19 12:19 -------
Confirmed, a regression on 3.4/3.5 probably caused by the new parser. A self-
contained testcase is obviously:
-------------------------------------------------
struct string
{
string() {};
string(const string& ) {};
string(const char * ) {};
};
int main()
{
string s1(string( (string )(""))); // OK
string s2(string( (const char*)(""))); // Does not compile
typedef const char* charp;
string s3(string( (charp)(""))); // Workaround: intermediate typedef
string s4((string( (const char*)("")))); // Workaround: extra parenthesis
return 0;
}
-------------------------------------------------
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Keywords| |rejects-valid
Last reconfirmed|0000-00-00 00:00:00 |2004-01-19 12:19:25
date| |
Summary|[gcc-3.4 parser regression] |[3.4/3.5 Regression] Parser
|Some compound casts rejected|confused on compound casts
Target Milestone|--- |3.4.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13736
More information about the Gcc-bugs
mailing list