------- Comment #2 from redi at gcc dot gnu dot org  2010-05-15 00:47 -------
(In reply to comment #1)
> Have you tried with Clang?
> 
> I think Clang prints typedefs using 'aka', which is not very clear.
> 
> error: incompatible type assigning 'vector<Real>', expected 'std::string' (aka
> 'class std::basic_string<char>')
> 
> I would suggest:
> 
> t.cc:8: error: cannot convert 'bar::Py_ssize_t*' ('int*') to 'Py_ssize_t*'
> ('long*') for 1st argument to 'int foo(Py_ssize_t*)'

1) bar:: looks like valid C++ syntax but it is not a valid
nested-name-specifier, so it should be something that is not valid C++ syntax,
such as {bar}::Py_ssize_t

2) Although the quotes _should_ make it clear, I think that could get confusing
when the type involves parentheses, e.g.

cannot convert 'my_fun_type' ('int* (Foo::*)(char*)') to 'int* const
(Foo::*)(char*)'

How about adding "typedef for" in there? e.g.

cannot convert 'bar::Py_ssize_t*' (typedef for 'int*')


> Do we have typedef unwrapping?

We used to only have unwrapped typedefs, so hopefully we can still get it when
wanted!


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44122

Reply via email to