]> granicus.if.org Git - clang/commitdiff
Stub out an error so we don't crash.
authorEli Friedman <eli.friedman@gmail.com>
Thu, 27 Aug 2009 05:09:36 +0000 (05:09 +0000)
committerEli Friedman <eli.friedman@gmail.com>
Thu, 27 Aug 2009 05:09:36 +0000 (05:09 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80207 91177308-0d34-0410-b5e6-96231b3b80d8

include/clang/Basic/DiagnosticSemaKinds.td
lib/Sema/SemaDeclCXX.cpp

index d376b9e68dc3dc81662938485a14322eb2370c34..fe7ab08434bfb187b444852cd05a665b10aeb565 100644 (file)
@@ -96,6 +96,8 @@ def err_using_requires_qualname : Error<
   "using declaration requires a qualified name">;
 def err_using_typename_non_type : Error<
   "'typename' keyword used on a non-type">;
+def err_using_dependent_unsupported : Error<
+  "dependent using declaration not supported yet">;
 
 def err_invalid_thread : Error<
   "'__thread' is only allowed on variable declarations">;
index 2f797daea328363ad290fa3b31231580eb634332..a18dc46fe7f6db44be071f7c832f9621034f7525 100644 (file)
@@ -2103,7 +2103,14 @@ Sema::DeclPtrTy Sema::ActOnUsingDeclaration(Scope *S,
     Name = TargetName;
   else
     Name = Context.DeclarationNames.getCXXOperatorName(Op);
-  
+
+  // FIXME: Implement this properly!
+  if (isUnknownSpecialization(SS)) {
+    Diag(IdentLoc, diag::err_using_dependent_unsupported);
+    delete AttrList;
+    return DeclPtrTy::make((UsingDecl*)0);
+  }
+
   // Lookup target name.
   LookupResult R = LookupParsedName(S, &SS, Name, LookupOrdinaryName, false);