[clang-tools-extra] r351867 - [doc] Replace 'class' with 'struct' for 'public' by default

Zinovy Nis via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 22 12:27:03 PST 2019


Author: zinovy.nis
Date: Tue Jan 22 12:27:02 2019
New Revision: 351867

URL: http://llvm.org/viewvc/llvm-project?rev=351867&view=rev
Log:
[doc] Replace 'class' with 'struct' for 'public' by default

Make sample syntax correct.


Modified:
    clang-tools-extra/trunk/docs/clang-tidy/checks/bugprone-parent-virtual-call.rst

Modified: clang-tools-extra/trunk/docs/clang-tidy/checks/bugprone-parent-virtual-call.rst
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/docs/clang-tidy/checks/bugprone-parent-virtual-call.rst?rev=351867&r1=351866&r2=351867&view=diff
==============================================================================
--- clang-tools-extra/trunk/docs/clang-tidy/checks/bugprone-parent-virtual-call.rst (original)
+++ clang-tools-extra/trunk/docs/clang-tidy/checks/bugprone-parent-virtual-call.rst Tue Jan 22 12:27:02 2019
@@ -8,15 +8,15 @@ to overridden parent's virtual methods.
 
 .. code-block:: c++
 
-  class A {
+  struct A {
     int virtual foo() {...}
   };
 
-  class B: public A {
+  struct B: public A {
     int foo() override {...}
   };
 
-  class C: public B {
+  struct C: public B {
     int foo() override { A::foo(); }
   //                     ^^^^^^^^
   // warning: qualified name A::foo refers to a member overridden in subclass; did you mean 'B'?  [bugprone-parent-virtual-call]




More information about the cfe-commits mailing list