]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/ClassHandler: no need to add `struct` before struct type
authorKefu Chai <kchai@redhat.com>
Mon, 3 Jun 2019 07:40:43 +0000 (15:40 +0800)
committerKefu Chai <kchai@redhat.com>
Mon, 3 Jun 2019 08:03:02 +0000 (16:03 +0800)
unlike C language, C++ is put struct names and other names in a single
namespace. so we don't need to add `strcut` before struct identifiers.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/osd/ClassHandler.h

index 9b8580f02fafaead3b45f61558ceba563ec27e27..deace6011991b59144ccc9257c3d1bd3c2a03243 100644 (file)
@@ -18,7 +18,7 @@ public:
   struct ClassData;
 
   struct ClassMethod {
-    struct ClassHandler::ClassData *cls;
+    ClassData *cls = nullptr;
     std::string name;
     int flags;
     cls_method_call_t func;
@@ -34,11 +34,11 @@ public:
       return flags;
     }
 
-    ClassMethod() : cls(0), flags(0), func(0), cxx_func(0) {}
+    ClassMethod() : flags(0), func(0), cxx_func(0) {}
   };
 
   struct ClassFilter {
-    struct ClassHandler::ClassData *cls = nullptr;
+    ClassData *cls = nullptr;
     std::string name;
     cls_cxx_filter_factory_t fn;