r339304 - Delete some unreachable AST printing code.

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 8 17:44:49 PDT 2018


Author: rsmith
Date: Wed Aug  8 17:44:49 2018
New Revision: 339304

URL: http://llvm.org/viewvc/llvm-project?rev=339304&view=rev
Log:
Delete some unreachable AST printing code.

Modified:
    cfe/trunk/lib/AST/TypePrinter.cpp

Modified: cfe/trunk/lib/AST/TypePrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/TypePrinter.cpp?rev=339304&r1=339303&r2=339304&view=diff
==============================================================================
--- cfe/trunk/lib/AST/TypePrinter.cpp (original)
+++ cfe/trunk/lib/AST/TypePrinter.cpp Wed Aug  8 17:44:49 2018
@@ -1427,22 +1427,6 @@ void TypePrinter::printAttributedAfter(c
                              ->getExtInfo().getProducesResult())
     return;
 
-  // Print nullability type specifiers that occur after
-  if (T->getAttrKind() == AttributedType::attr_nonnull ||
-      T->getAttrKind() == AttributedType::attr_nullable ||
-      T->getAttrKind() == AttributedType::attr_null_unspecified) {
-    if (T->getAttrKind() == AttributedType::attr_nonnull)
-      OS << " _Nonnull";
-    else if (T->getAttrKind() == AttributedType::attr_nullable)
-      OS << " _Nullable";
-    else if (T->getAttrKind() == AttributedType::attr_null_unspecified)
-      OS << " _Null_unspecified";
-    else
-      llvm_unreachable("unhandled nullability");
-
-    return;
-  }
-
   if (T->getAttrKind() == AttributedType::attr_lifetimebound) {
     OS << " [[clang::lifetimebound]]";
     return;




More information about the cfe-commits mailing list