[PATCH] D103933: [clang] NFC: rename SK_CastDerivedToBaseRValue to SK_CastDerivedToBasePRValue

Matheus Izvekov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 8 16:05:43 PDT 2021


mizvekov created this revision.
mizvekov requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

This is a follow up to the "rvalue-to-prvalue" rename at D103720 <https://reviews.llvm.org/D103720>.

Signed-off-by: Matheus Izvekov <mizvekov at gmail.com>

Depends on D103720 <https://reviews.llvm.org/D103720>


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D103933

Files:
  clang/include/clang/Sema/Initialization.h
  clang/lib/Sema/SemaInit.cpp


Index: clang/lib/Sema/SemaInit.cpp
===================================================================
--- clang/lib/Sema/SemaInit.cpp
+++ clang/lib/Sema/SemaInit.cpp
@@ -3457,7 +3457,7 @@
 void InitializationSequence::Step::Destroy() {
   switch (Kind) {
   case SK_ResolveAddressOfOverloadedFunction:
-  case SK_CastDerivedToBaseRValue:
+  case SK_CastDerivedToBasePRValue:
   case SK_CastDerivedToBaseXValue:
   case SK_CastDerivedToBaseLValue:
   case SK_BindReference:
@@ -3585,7 +3585,7 @@
   Step S;
   switch (VK) {
   case VK_PRValue:
-    S.Kind = SK_CastDerivedToBaseRValue;
+    S.Kind = SK_CastDerivedToBasePRValue;
     break;
   case VK_XValue: S.Kind = SK_CastDerivedToBaseXValue; break;
   case VK_LValue: S.Kind = SK_CastDerivedToBaseLValue; break;
@@ -8106,7 +8106,7 @@
   // initializer.
   switch (Steps.front().Kind) {
   case SK_ResolveAddressOfOverloadedFunction:
-  case SK_CastDerivedToBaseRValue:
+  case SK_CastDerivedToBasePRValue:
   case SK_CastDerivedToBaseXValue:
   case SK_CastDerivedToBaseLValue:
   case SK_BindReference:
@@ -8191,7 +8191,7 @@
                                                  Step->Function.Function);
       break;
 
-    case SK_CastDerivedToBaseRValue:
+    case SK_CastDerivedToBasePRValue:
     case SK_CastDerivedToBaseXValue:
     case SK_CastDerivedToBaseLValue: {
       // We have a derived-to-base cast that produces either an rvalue or an
@@ -9617,8 +9617,8 @@
       OS << "resolve address of overloaded function";
       break;
 
-    case SK_CastDerivedToBaseRValue:
-      OS << "derived-to-base (rvalue)";
+    case SK_CastDerivedToBasePRValue:
+      OS << "derived-to-base (prvalue)";
       break;
 
     case SK_CastDerivedToBaseXValue:
Index: clang/include/clang/Sema/Initialization.h
===================================================================
--- clang/include/clang/Sema/Initialization.h
+++ clang/include/clang/Sema/Initialization.h
@@ -804,7 +804,7 @@
     SK_ResolveAddressOfOverloadedFunction,
 
     /// Perform a derived-to-base cast, producing an rvalue.
-    SK_CastDerivedToBaseRValue,
+    SK_CastDerivedToBasePRValue,
 
     /// Perform a derived-to-base cast, producing an xvalue.
     SK_CastDerivedToBaseXValue,


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D103933.350731.patch
Type: text/x-patch
Size: 2214 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210608/dda442ae/attachment.bin>


More information about the cfe-commits mailing list