r252470 - Fixing SPHINX warnings with incorrect indentations.

Aaron Ballman via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 9 07:24:10 PST 2015


Author: aaronballman
Date: Mon Nov  9 09:24:09 2015
New Revision: 252470

URL: http://llvm.org/viewvc/llvm-project?rev=252470&view=rev
Log:
Fixing SPHINX warnings with incorrect indentations.

Modified:
    cfe/trunk/include/clang/Basic/AttrDocs.td

Modified: cfe/trunk/include/clang/Basic/AttrDocs.td
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/AttrDocs.td?rev=252470&r1=252469&r2=252470&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/AttrDocs.td (original)
+++ cfe/trunk/include/clang/Basic/AttrDocs.td Mon Nov  9 09:24:09 2015
@@ -1628,44 +1628,44 @@ The ``not_tail_called`` attribute preven
 
 For example, it prevents tail-call optimization in the following case:
   .. code-block: c
-  int __attribute__((not_tail_called)) foo1(int);
+    int __attribute__((not_tail_called)) foo1(int);
 
-  int foo2(int a) {
-    return foo1(a); // No tail-call optimization on direct calls.
-  }
+    int foo2(int a) {
+      return foo1(a); // No tail-call optimization on direct calls.
+    }
 
 However, it doesn't prevent tail-call optimization in this case:
   .. code-block: c
-  int __attribute__((not_tail_called)) foo1(int);
+    int __attribute__((not_tail_called)) foo1(int);
 
-  int foo2(int a) {
-    int (*fn)(int) = &foo1;
+    int foo2(int a) {
+      int (*fn)(int) = &foo1;
 
-    // not_tail_called has no effect on an indirect call even if the call can be
-    // resolved at compile time.
-    return (*fn)(a);
-  }
+      // not_tail_called has no effect on an indirect call even if the call can be
+      // resolved at compile time.
+      return (*fn)(a);
+    }
 
 Marking virtual functions as ``not_tail_called`` is an error:
   .. code-block: c++
-  class Base {
-  public:
-    // not_tail_called on a virtual function is an error.
-    [[clang::not_tail_called]] virtual int foo1();
-
-    virtual int foo2();
-
-    // Non-virtual functions can be marked ``not_tail_called``.
-    [[clang::not_tail_called]] int foo3();
-  };
-
-  class Derived1 : public Base {
-  public:
-    int foo1() override;
-
-    // not_tail_called on a virtual function is an error.
-    [[clang::not_tail_called]] int foo2() override;
-  };
+    class Base {
+    public:
+      // not_tail_called on a virtual function is an error.
+      [[clang::not_tail_called]] virtual int foo1();
+
+      virtual int foo2();
+
+      // Non-virtual functions can be marked ``not_tail_called``.
+      [[clang::not_tail_called]] int foo3();
+    };
+
+    class Derived1 : public Base {
+    public:
+      int foo1() override;
+
+      // not_tail_called on a virtual function is an error.
+      [[clang::not_tail_called]] int foo2() override;
+    };
 
   }];
 }




More information about the cfe-commits mailing list