[cfe-dev] template issue with clang::RedeclarableTemplateDecl::SpecIterator

Laszlo Nagy rizsotto.mailinglist at gmail.com
Wed Feb 20 15:25:05 PST 2013


run into a weird error message when tried to compile a project...

tools/clang/include/clang/AST/DeclTemplate.h:560:22: error:
      no matching constructor for initialization of 'SetIteratorType' (aka
      typename SmallVector<FunctionTemplateSpecializationInfo *,
    SpecIterator() : SetIter() {}
Actually the user of the code is wrong to default construct for the
iterator. But I think it would be more elegant to not declare default
construtor, if the parent class does not have it. Namely the
llvm::FoldingSetVectorIterator class does not have, therefore
the clang::RedeclarableTemplateDecl::SpecIterator should not have either.

What do you think?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20130221/85ec22cf/attachment.html>

More information about the cfe-dev mailing list