aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/InitPreprocessor.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dimitry@andric.com>2017-01-09 20:29:35 +0000
committerDimitry Andric <dimitry@andric.com>2017-01-09 20:29:35 +0000
commit082fa545cc8de9a299686a383b181fa02fd98dc6 (patch)
tree67ca0b27936423c5027364fad70778e6bbe0e261 /clang/lib/Frontend/InitPreprocessor.cpp
parent6f8e7e0853b2d5976bc53ca8ff7ac9456ac5740f (diff)
downloadllvm-082fa545cc8de9a299686a383b181fa02fd98dc6.zip
llvm-082fa545cc8de9a299686a383b181fa02fd98dc6.tar.gz
llvm-082fa545cc8de9a299686a383b181fa02fd98dc6.tar.bz2
Move _PairT declaration out of __hash_combine to avoid warning under C++98
Summary: Some parts of the FreeBSD tree are still compiled with C++98, and until rL288554 this has always worked fine. After that, a complaint about the newly introduced local _PairT is produced: /usr/include/c++/v1/memory:3354:27: error: template argument uses local type '_PairT' [-Werror,-Wlocal-type-template-args] typedef __scalar_hash<_PairT> _HashT; ^~~~~~ /usr/include/c++/v1/memory:3284:29: error: template argument uses local type '_PairT' [-Werror,-Wlocal-type-template-args] : public unary_function<_Tp, size_t> ^~~ /usr/include/c++/v1/memory:3356:12: note: in instantiation of template class 'std::__1::__scalar_hash<_PairT, 2>' requested here return _HashT()(__p); ^ As far as I can see, there should be no problem moving the _PairT struct to just before the __hash_combine() function, which fixes this particular warning. Reviewers: mclow.lists, EricWF Subscribers: cfe-commits, emaste Differential Revision: https://reviews.llvm.org/D28472 llvm-svn: 291476
Diffstat (limited to 'clang/lib/Frontend/InitPreprocessor.cpp')
0 files changed, 0 insertions, 0 deletions