Work around GCC's dislike of attributes on function definitions.
authorJeff Cohen <jeffc@jolt-lang.org>
Sun, 23 Oct 2005 15:22:50 +0000 (15:22 +0000)
committerJeff Cohen <jeffc@jolt-lang.org>
Sun, 23 Oct 2005 15:22:50 +0000 (15:22 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23896 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/Support/CommandLine.h

index 1d499de9a9d47c9c6ae960736e5f82ab16190b77..73a16c4af9600f7ba408524fef33b0ffb3d8ff1d 100644 (file)
@@ -334,9 +334,14 @@ public:
   }
 };
 
+// Silly GCC doesn't allow attributes on a function definition.
 template<class DataType>
 ValuesClass<DataType> values(const char *Arg, DataType Val, const char *Desc,
-                             ...) END_WITH_NULL {
+                             ...) END_WITH_NULL;
+
+template<class DataType>
+ValuesClass<DataType> values(const char *Arg, DataType Val, const char *Desc,
+                             ...) {
     va_list ValueArgs;
     va_start(ValueArgs, Desc);
     ValuesClass<DataType> Vals(Arg, Val, Desc, ValueArgs);