Fix FormatVariadicTest with GCC

Looks like GCC didn't like the original specialization, try within namespace.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@316361 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jonas Hahnfeld 2017-10-23 18:41:22 +00:00
parent 6affa236cf
commit 2c4e91e1aa

View File

@ -593,11 +593,13 @@ struct Recorder {
: Copied(Move.Copied), Moved(1 + Move.Moved) {}
};
} // namespace
template <> struct llvm::format_provider<Recorder> {
namespace llvm {
template <> struct format_provider<Recorder> {
static void format(const Recorder &R, raw_ostream &OS, StringRef style) {
OS << R.Copied << "C " << R.Moved << "M";
}
};
} // namespace
TEST(FormatVariadicTest, CopiesAndMoves) {
Recorder R;