diff options
author | Mehdi Amini <mehdi.amini@apple.com> | 2016-10-08 19:41:06 +0000 |
---|---|---|
committer | Mehdi Amini <mehdi.amini@apple.com> | 2016-10-08 19:41:06 +0000 |
commit | 40c049fa77a8b213a3ca0913116e4dcbf6f87936 (patch) | |
tree | 4d6b01097c14ed0603db24ea068e5cab7488ccef /include-fixer | |
parent | 17d94f6b9cd08f5fc5184f5d03af3c1ad24e012f (diff) |
Turn cl::values() (for enum) from a vararg function to using C++ variadic template
The core of the change is supposed to be NFC, however it also fixes
what I believe was an undefined behavior when calling:
va_start(ValueArgs, Desc);
with Desc being a StringRef.
Differential Revision: https://reviews.llvm.org/D25342
git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@283671 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include-fixer')
-rw-r--r-- | include-fixer/tool/ClangIncludeFixer.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/include-fixer/tool/ClangIncludeFixer.cpp b/include-fixer/tool/ClangIncludeFixer.cpp index 6084ff64..ed1ab204 100644 --- a/include-fixer/tool/ClangIncludeFixer.cpp +++ b/include-fixer/tool/ClangIncludeFixer.cpp @@ -90,8 +90,7 @@ enum DatabaseFormatTy { cl::opt<DatabaseFormatTy> DatabaseFormat( "db", cl::desc("Specify input format"), cl::values(clEnumVal(fixed, "Hard-coded mapping"), - clEnumVal(yaml, "Yaml database created by find-all-symbols"), - clEnumValEnd), + clEnumVal(yaml, "Yaml database created by find-all-symbols")), cl::init(yaml), cl::cat(IncludeFixerCategory)); cl::opt<std::string> Input("input", |