The following small test drove me crazy and had me convinced that gcc 4.4 had regressed. I had the C++ spec out too trying to understand exactly how string is declared until I eventually saw the actual problem, which is that the first parameter is named 'string'.
I'm not sure exactly how to improve the error message here. 4.3 and earlier accept this code. #include <string> using std::string; int fn(string& string, string& head); g++-4.4 -c junk.C junk.C:3: error: string is not a type -- Summary: Misleading error message for misusing a type Product: gcc Version: 4.4.2 Status: UNCONFIRMED Severity: enhancement Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: jlquinn at optonline dot net http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42067