Update target attribute support for post-commit feedback.

Use const auto rather than duplicating the type name and fix the
error message when the attribute is applied to an incorrect entity.

llvm-svn: 241526
diff --git a/clang/lib/CodeGen/CGCall.cpp b/clang/lib/CodeGen/CGCall.cpp
index ac014d3..6192244 100644
--- a/clang/lib/CodeGen/CGCall.cpp
+++ b/clang/lib/CodeGen/CGCall.cpp
@@ -1506,7 +1506,7 @@
 
     const FunctionDecl *FD = dyn_cast_or_null<FunctionDecl>(TargetDecl);
     if (FD) {
-      if (const TargetAttr *TD = FD->getAttr<TargetAttr>()) {
+      if (const auto *TD = FD->getAttr<TargetAttr>()) {
         StringRef FeaturesStr = TD->getFeatures();
         SmallVector<StringRef, 1> AttrFeatures;
         FeaturesStr.split(AttrFeatures, ",");