On 04/28/2016 10:30 AM, Trevor Saunders wrote:
On Thu, Apr 28, 2016 at 10:28:15AM -0400, David Malcolm wrote:
This is a resend of a patch kit I sent in stage 3; the original post
was here:
https://gcc.gnu.org/ml/gcc-patches/2015-12/msg01933.html
I've rebased the patches against yesterday's trunk and retested them.
They add various fix-it hints to existing diagnostics (PR 62314 is a
catch-all for adding fix-its).
The first patch in the kit adds a fix-it insertion hint for missing
"template <> " in explicit specializations, and improves the
reported range of the type name by capturing the full range, rather
than just one token within it.
I note that clang (http://clang.llvm.org/diagnostics.html) suggests
inserting
template<>
whereas our diagnostic talks about
template <>
hence I have the fixit suggest inserting that. Should we change our
wording instead, and lose the space?
Selfishly I'd prefer to lose the space on the grounds all the other
projects I work on don't put one there and gcc is inconsistant about it.
The C++ standard is also inconsistent, sadly.
The C++ patches are all OK.
Jason