diff --git a/docs/link_formatting.adoc b/docs/link_formatting.adoc index 4005e70ab1b..faa220e6867 100644 --- a/docs/link_formatting.adoc +++ b/docs/link_formatting.adoc @@ -46,7 +46,7 @@ When web pages have massively long names like "Java™ Platform, Standard Editio * Azure Documentation - https://learn.microsoft.com/en-us/azure/?product=popular * CERT - https://wiki.sei.cmu.edu/confluence/display/seccode * {cpp} reference - https://en.cppreference.com/w/ -* C++ Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md * CVE - https://cve.mitre.org * CWE - https://cwe.mitre.org * Docker Documentation - https://docs.docker.com/ diff --git a/rules/S1003/cfamily/rule.adoc b/rules/S1003/cfamily/rule.adoc index 8fff8267062..623392497fd 100644 --- a/rules/S1003/cfamily/rule.adoc +++ b/rules/S1003/cfamily/rule.adoc @@ -58,7 +58,7 @@ The issue only happens if the using directive is at global scope or at namespace == Resources * MISRA {cpp}:2008, 7-3-6 - using-directives and using-declarations (excluding class scope or function scope using-declarations) shall not be used in header files. -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#sf7-dont-write-using-namespace-at-global-scope-in-a-header-file[{cpp} Core Guidelines SF.7] - Don’t write ``++using namespace++`` at global scope in a header file +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#sf7-dont-write-using-namespace-at-global-scope-in-a-header-file[SF.7: Don't write `using namespace` at global scope in a header file] ifdef::env-github,rspecator-view[] diff --git a/rules/S1032/cfamily/rule.adoc b/rules/S1032/cfamily/rule.adoc index 8051d38152e..24a17f2b59f 100644 --- a/rules/S1032/cfamily/rule.adoc +++ b/rules/S1032/cfamily/rule.adoc @@ -44,7 +44,7 @@ bool isMax(T t){ == Resources * MISRA {cpp}:2008, 14-8-1 -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#t144-dont-specialize-function-templates[{cpp} Core Guidelines T.144] - Don’t specialize function templates +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#t144-dont-specialize-function-templates[T.144: Don't specialize function templates] ifdef::env-github,rspecator-view[] diff --git a/rules/S1044/cfamily/rule.adoc b/rules/S1044/cfamily/rule.adoc index 89fc1511a49..5bd62777161 100644 --- a/rules/S1044/cfamily/rule.adoc +++ b/rules/S1044/cfamily/rule.adoc @@ -47,7 +47,7 @@ try { * CERT - https://wiki.sei.cmu.edu/confluence/x/SXs-BQ[ERR61-CPP. Catch exceptions by lvalue reference] === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#e15-catch-exceptions-from-a-hierarchy-by-reference[E.15 Catch exceptions from a hierarchy by reference] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#e15-throw-by-value-catch-exceptions-from-a-hierarchy-by-reference[E.15: Throw by value, catch exceptions from a hierarchy by reference] * MISRA {cpp}:2008, 15-3-5 - A class type exception shall always be caught by reference === Related rules diff --git a/rules/S107/cfamily/rule.adoc b/rules/S107/cfamily/rule.adoc index 3f12ddad2de..b6538823d05 100644 --- a/rules/S107/cfamily/rule.adoc +++ b/rules/S107/cfamily/rule.adoc @@ -4,7 +4,7 @@ include::../rule.adoc[] == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#i23-keep-the-number-of-function-arguments-low[{cpp} Core Guidelines I.23]: Keep the number of function arguments low +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#i23-keep-the-number-of-function-arguments-low[I.23: Keep the number of function arguments low] ifdef::env-github,rspecator-view[] diff --git a/rules/S112/cfamily/rule.adoc b/rules/S112/cfamily/rule.adoc index aef3dbaa1e2..dedcf9611c7 100644 --- a/rules/S112/cfamily/rule.adoc +++ b/rules/S112/cfamily/rule.adoc @@ -103,7 +103,7 @@ void checkState(S state) { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Re-exception-types[E.14: Use purpose-designed user-defined types as exceptions (not built-in types)] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#e14-use-purpose-designed-user-defined-types-as-exceptions-not-built-in-types[E.14: Use purpose-designed user-defined types as exceptions (not built-in types)] === Related rules diff --git a/rules/S1155/cfamily/rule.adoc b/rules/S1155/cfamily/rule.adoc index 5c77838f743..9f468ff8e02 100644 --- a/rules/S1155/cfamily/rule.adoc +++ b/rules/S1155/cfamily/rule.adoc @@ -28,7 +28,7 @@ void fun(const std::vector &myVector) { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#reason-382[T.143 - Don't write unintentionally nongeneric code] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#t143-dont-write-unintentionally-non-generic-code[T.143: Don't write unintentionally non-generic code] ifdef::env-github,rspecator-view[] diff --git a/rules/S1172/cfamily/rule.adoc b/rules/S1172/cfamily/rule.adoc index 44b99d401b3..c7b704887cd 100644 --- a/rules/S1172/cfamily/rule.adoc +++ b/rules/S1172/cfamily/rule.adoc @@ -44,7 +44,7 @@ void doSomething(int a) { * MISRA {cpp}:2008, 0-1-11 - There shall be no unused parameters (named or unnamed) in nonvirtual functions. * MISRA C:2012, 2.7 - There should be no unused parameters in functions * https://wiki.sei.cmu.edu/confluence/x/5dUxBQ[CERT, MSC12-C.] - Detect and remove code that has no effect or is never executed -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f9-unused-parameters-should-be-unnamed[{cpp} Core Guidelines - F.9] - Unused parameters should be unnamed +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f9-unused-parameters-should-be-unnamed[F.9: Unused parameters should be unnamed] ifdef::env-github,rspecator-view[] diff --git a/rules/S1181/cfamily/rule.adoc b/rules/S1181/cfamily/rule.adoc index 86da35ff78c..9568f34e0f2 100644 --- a/rules/S1181/cfamily/rule.adoc +++ b/rules/S1181/cfamily/rule.adoc @@ -41,7 +41,7 @@ Additionally, if the ``++catch++`` handler is throwing an exception (either the == Resources * https://cwe.mitre.org/data/definitions/396[MITRE, CWE-396] - Declaration of Catch for Generic Exception -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Re-exception-types[{cpp} Core Guidelines E.14] - Use purpose-designed user-defined types as exceptions (not built-in types) +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#e14-use-purpose-designed-user-defined-types-as-exceptions-not-built-in-types[E.14: Use purpose-designed user-defined types as exceptions (not built-in types)] ifdef::env-github,rspecator-view[] diff --git a/rules/S1231/cfamily/rule.adoc b/rules/S1231/cfamily/rule.adoc index f1c7054fed0..9482820f45b 100644 --- a/rules/S1231/cfamily/rule.adoc +++ b/rules/S1231/cfamily/rule.adoc @@ -27,7 +27,7 @@ auto p2 = std::make_unique("Bjarne"); // Compliant == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#r10-avoid-malloc-and-free[{cpp} Core Guidelines R.10] - Avoid malloc() and free() +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r10-avoid-malloc-and-free[R.10: Avoid `malloc()` and `free()`] diff --git a/rules/S1235/cfamily/rule.adoc b/rules/S1235/cfamily/rule.adoc index 1c04360dfe9..87da4f50993 100644 --- a/rules/S1235/cfamily/rule.adoc +++ b/rules/S1235/cfamily/rule.adoc @@ -42,6 +42,6 @@ public: * https://wiki.sei.cmu.edu/confluence/x/5Xs-BQ[CERT, OOP52-CPP.] - Do not delete a polymorphic object without a virtual destructor * http://www.gotw.ca/publications/mill18.htm[Virtuality article] -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c35-a-base-class-destructor-should-be-either-public-and-virtual-or-protected-and-nonvirtual[{cpp} Core Guidelines C.35] - A base class destructor should be either public and virtual, or protected and nonvirtual -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c127-a-class-with-a-virtual-function-should-have-a-virtual-or-protected-destructor[{cpp} Core Guidelines C.127] - A class with a virtual function should have a virtual or protected destructor +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c35-a-base-class-destructor-should-be-either-public-and-virtual-or-protected-and-non-virtual[C.35: A base class destructor should be either public and virtual, or protected and non-virtual] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c127-a-class-with-a-virtual-function-should-have-a-virtual-or-protected-destructor[C.127: A class with a virtual function should have a virtual or protected destructor] diff --git a/rules/S1236/cfamily/rule.adoc b/rules/S1236/cfamily/rule.adoc index f8417d7a378..7e8e7080c2b 100644 --- a/rules/S1236/cfamily/rule.adoc +++ b/rules/S1236/cfamily/rule.adoc @@ -38,6 +38,6 @@ public: == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c60-make-copy-assignment-non-virtual-take-the-parameter-by-const-and-return-by-non-const[{cpp} Core Guidelines C.60] - Make copy assignment non-virtual, take the parameter by const&, and return by non-const& -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c63-make-move-assignment-non-virtual-take-the-parameter-by\--and-return-by-non-const-[{cpp} Core Guidelines C.63] - Make move assignment non-virtual, take the parameter by &&, and return by non-const & +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c60-make-copy-assignment-non-virtual-take-the-parameter-by-const-and-return-by-non-const[C.60: Make copy assignment non-`virtual`, take the parameter by `const&`, and return by non-`const&`] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c63-make-move-assignment-non-virtual-take-the-parameter-by--and-return-by-non-const[C.63: Make move assignment non-`virtual`, take the parameter by `&&`, and return by non-`const&`] diff --git a/rules/S1238/cfamily/rule.adoc b/rules/S1238/cfamily/rule.adoc index ce949b26f70..0360cf0dac7 100644 --- a/rules/S1238/cfamily/rule.adoc +++ b/rules/S1238/cfamily/rule.adoc @@ -46,7 +46,7 @@ because passing arguments by reference to a coroutine often leads to dangling re == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f16-for-in-parameters-pass-cheaply-copied-types-by-value-and-others-by-reference-to-const[{cpp} Core Guidelines F.16] - For “in” parameters, pass cheaply-copied types by value and others by reference to ``++const++`` +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f16-for-in-parameters-pass-cheaply-copied-types-by-value-and-others-by-reference-to-const[F.16: For "in" parameters, pass cheaply-copied types by value and others by reference to `const`] ifdef::env-github,rspecator-view[] diff --git a/rules/S1242/cfamily/rule.adoc b/rules/S1242/cfamily/rule.adoc index db0c0eebd15..2174756b108 100644 --- a/rules/S1242/cfamily/rule.adoc +++ b/rules/S1242/cfamily/rule.adoc @@ -59,7 +59,7 @@ void stopServer(Base *obj) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c138-create-an-overload-set-for-a-derived-class-and-its-bases-with-using[{cpp} Core Guidelines C.138] - Create an overload set for a derived class and its bases with using +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c138-create-an-overload-set-for-a-derived-class-and-its-bases-with-using[C.138: Create an overload set for a derived class and its bases with `using`] ifdef::env-github,rspecator-view[] diff --git a/rules/S1265/cfamily/rule.adoc b/rules/S1265/cfamily/rule.adoc index 50bc5f1c584..3b16344f017 100644 --- a/rules/S1265/cfamily/rule.adoc +++ b/rules/S1265/cfamily/rule.adoc @@ -101,7 +101,7 @@ void f() { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#r15-always-overload-matched-allocationdeallocation-pairs[R.15: Always overload matched allocation/deallocation pairs] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r15-always-overload-matched-allocationdeallocation-pairs[R.15: Always overload matched allocation/deallocation pairs] === Related rules diff --git a/rules/S1270/rule.adoc b/rules/S1270/rule.adoc index 5a449e85d28..2fa28ee0a9a 100644 --- a/rules/S1270/rule.adoc +++ b/rules/S1270/rule.adoc @@ -29,5 +29,5 @@ int fun() { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Rl-void[{cpp} Core Guidelines NL.25] - Don't use void as an argument type +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#nl25-dont-use-void-as-an-argument-type[NL.25: Don't use `void` as an argument type] diff --git a/rules/S1659/cfamily/rule.adoc b/rules/S1659/cfamily/rule.adoc index bff48cf06ef..4609715a39f 100644 --- a/rules/S1659/cfamily/rule.adoc +++ b/rules/S1659/cfamily/rule.adoc @@ -34,7 +34,7 @@ int &j3 = i2; * MISRA {cpp}:2008, 8-0-1 - An init-declarator-list or a member-declarator-list shall consist of a single init-declarator or member-declarator respectively -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es10-declare-one-name-only-per-declaration[{cpp} Core Guidelines - ES.10] - Declare one name (only) per declaration +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es10-declare-one-name-only-per-declaration[ES.10: Declare one name (only) per declaration] ifdef::env-github,rspecator-view[] diff --git a/rules/S1699/cfamily/rule.adoc b/rules/S1699/cfamily/rule.adoc index bbd0f4b182c..52880a84eb8 100644 --- a/rules/S1699/cfamily/rule.adoc +++ b/rules/S1699/cfamily/rule.adoc @@ -122,6 +122,6 @@ class Child : public Parent { == Resources * https://wiki.sei.cmu.edu/confluence/x/6ns-BQ[CERT, OOP50-CPP.] - Do not invoke virtual functions from constructors or destructors -* https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rc-factory[{cpp} Core Guidelines C.50] - Use a factory function if you need “virtual behavior” during initialization +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c50-use-a-factory-function-if-you-need-virtual-behavior-during-initialization[C.50: Use a factory function if you need "virtual behavior" during initialization] include::../rspecator.adoc[] \ No newline at end of file diff --git a/rules/S1709/cfamily/rule.adoc b/rules/S1709/cfamily/rule.adoc index ac456a7e9c7..d3e13b87168 100644 --- a/rules/S1709/cfamily/rule.adoc +++ b/rules/S1709/cfamily/rule.adoc @@ -70,8 +70,8 @@ Additionally, developers can use `explicit(false)` to mark constructors or conve == Resources * MISRA {cpp}:2008, 12-1-3 - All constructors that are callable with a single argument of fundamental type shall be declared ``++explicit++``. -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c46-by-default-declare-single-argument-constructors-explicit[{cpp} Core Guidelines C.46] - By default, declare single-argument constructors explicit -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c164-avoid-implicit-conversion-operators[{cpp} Core Guidelines C.164] - Avoid implicit conversion operators +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c46-by-default-declare-single-argument-constructors-explicit[C.46: By default, declare single-argument constructors explicit] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c164-avoid-implicit-conversion-operators[C.164: Avoid implicit conversion operators] diff --git a/rules/S1749/cfamily/rule.adoc b/rules/S1749/cfamily/rule.adoc index 20bce2f54bc..d3d95213527 100644 --- a/rules/S1749/cfamily/rule.adoc +++ b/rules/S1749/cfamily/rule.adoc @@ -40,7 +40,7 @@ signed long int i; == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Rl-const[{cpp} Core Guidelines NL.26] - Use conventional ``++const++`` notation +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#nl26-use-conventional-const-notation[NL.26: Use conventional `const` notation] ifdef::env-github,rspecator-view[] diff --git a/rules/S2107/cfamily/rule.adoc b/rules/S2107/cfamily/rule.adoc index 3034793168d..c8192e4454b 100644 --- a/rules/S2107/cfamily/rule.adoc +++ b/rules/S2107/cfamily/rule.adoc @@ -270,7 +270,7 @@ struct ContainerPartial { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c41-a-constructor-should-create-a-fully-initialized-object[C.41: A constructor should create a fully initialized object] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c41-a-constructor-should-create-a-fully-initialized-object[C.41: A constructor should create a fully initialized object] === Related rules diff --git a/rules/S2145/cfamily/rule.adoc b/rules/S2145/cfamily/rule.adoc index ccaab5eff90..2369f317742 100644 --- a/rules/S2145/cfamily/rule.adoc +++ b/rules/S2145/cfamily/rule.adoc @@ -54,7 +54,7 @@ public void doSomething(int i) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es70-prefer-a-switch-statement-to-an-if-statement-when-there-is-a-choice[{cpp} Core Guidelines ES.70]: Prefer a switch-statement to an if-statement when there is a choice +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es70-prefer-a-switch-statement-to-an-if-statement-when-there-is-a-choice[ES.70: Prefer a `switch`-statement to an `if`-statement when there is a choice] ifdef::env-github,rspecator-view[] diff --git a/rules/S2259/cfamily/rule.adoc b/rules/S2259/cfamily/rule.adoc index 23bd023b555..5208a0deda1 100644 --- a/rules/S2259/cfamily/rule.adoc +++ b/rules/S2259/cfamily/rule.adoc @@ -119,8 +119,8 @@ include::../../../shared_content/cfamily/reference_over_nonnull_pointer.adoc[] === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md[F.16: For "in" parameters, pass cheaply-copied types by value and others by reference to const] -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md[F.17: For "in-out" parameters, pass by reference to non-const] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f16-for-in-parameters-pass-cheaply-copied-types-by-value-and-others-by-reference-to-const[F.16: For "in" parameters, pass cheaply-copied types by value and others by reference to `const`] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f17-for-in-out-parameters-pass-by-reference-to-non-const[F.17: For "in-out" parameters, pass by reference to non-`const`] === Related rules diff --git a/rules/S2303/cfamily/rule.adoc b/rules/S2303/cfamily/rule.adoc index 78bd8a3e817..468b778c5b3 100644 --- a/rules/S2303/cfamily/rule.adoc +++ b/rules/S2303/cfamily/rule.adoc @@ -28,7 +28,7 @@ If a derived class overrides a function with a dynamic exception specification, == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#e30-dont-use-exception-specifications[{cpp} Core Guidelines E.30] - Don’t use exception specifications +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#e30-dont-use-exception-specifications[E.30: Don't use exception specifications] diff --git a/rules/S2387/cfamily/rule.adoc b/rules/S2387/cfamily/rule.adoc index 94d4e34889a..18eb057dcdc 100644 --- a/rules/S2387/cfamily/rule.adoc +++ b/rules/S2387/cfamily/rule.adoc @@ -84,7 +84,7 @@ class Raspberry : public RedFruit { // RedFruit inherits from Fruit privately == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es12-do-not-reuse-names-in-nested-scopes[{cpp} Core Guidelines - ES.12] - Do not reuse names in nested scopes +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es12-do-not-reuse-names-in-nested-scopes[ES.12: Do not reuse names in nested scopes] ifdef::env-github,rspecator-view[] diff --git a/rules/S2637/cfamily/rule.adoc b/rules/S2637/cfamily/rule.adoc index 6dd1538ea35..13461317c61 100644 --- a/rules/S2637/cfamily/rule.adoc +++ b/rules/S2637/cfamily/rule.adoc @@ -177,8 +177,8 @@ include::../standards.adoc[] === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md[F.16: For "in" parameters, pass cheaply-copied types by value and others by reference to const] -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md[F.17: For "in-out" parameters, pass by reference to non-const] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f16-for-in-parameters-pass-cheaply-copied-types-by-value-and-others-by-reference-to-const[F.16: For "in" parameters, pass cheaply-copied types by value and others by reference to `const`] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f17-for-in-out-parameters-pass-by-reference-to-non-const[F.17: For "in-out" parameters, pass by reference to non-`const`] === Related rules diff --git a/rules/S2807/cfamily/rule.adoc b/rules/S2807/cfamily/rule.adoc index 08fb8607eed..3ba21600792 100644 --- a/rules/S2807/cfamily/rule.adoc +++ b/rules/S2807/cfamily/rule.adoc @@ -27,7 +27,7 @@ friend bool operator==(const MyClass &LHS, const MyClass &RHS); == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c161-use-nonmember-functions-for-symmetric-operators[{cpp} Core Guidelines C.161] - Use nonmember functions for symmetric operators +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c161-use-non-member-functions-for-symmetric-operators[C.161: Use non-member functions for symmetric operators] ifdef::env-github,rspecator-view[] diff --git a/rules/S3229/cfamily/rule.adoc b/rules/S3229/cfamily/rule.adoc index d9091a3b945..272bba7c040 100644 --- a/rules/S3229/cfamily/rule.adoc +++ b/rules/S3229/cfamily/rule.adoc @@ -75,7 +75,7 @@ int main() { == Resources * https://wiki.sei.cmu.edu/confluence/x/dXw-BQ[CERT, OOP53-CPP.] - Write constructor member initializers in the canonical order -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c47-define-and-initialize-member-variables-in-the-order-of-member-declaration[{cpp} Core Guidelines C.47] - Define and initialize member variables in the order of member declaration +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c47-define-and-initialize-member-variables-in-the-order-of-member-declaration[C.47: Define and initialize member variables in the order of member declaration] ifdef::env-github,rspecator-view[] diff --git a/rules/S3230/cfamily/rule.adoc b/rules/S3230/cfamily/rule.adoc index eaafaaf3fbc..671a9bed075 100644 --- a/rules/S3230/cfamily/rule.adoc +++ b/rules/S3230/cfamily/rule.adoc @@ -59,8 +59,8 @@ public: == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c48-prefer-in-class-initializers-to-member-initializers-in-constructors-for-constant-initializers[{cpp} Core Guidelines C.48] - Prefer in-class initializers to member initializers in constructors for constant initializers -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c49-prefer-initialization-to-assignment-in-constructors[{cpp} Core Guidelines C.49] - Prefer initialization to assignment in constructors +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c48-prefer-in-class-initializers-to-member-initializers-in-constructors-for-constant-initializers[C.48: Prefer in-class initializers to member initializers in constructors for constant initializers] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c49-prefer-initialization-to-assignment-in-constructors[C.49: Prefer initialization to assignment in constructors] diff --git a/rules/S3471/cfamily/rule.adoc b/rules/S3471/cfamily/rule.adoc index 3d019e51d35..bd4e5c17884 100644 --- a/rules/S3471/cfamily/rule.adoc +++ b/rules/S3471/cfamily/rule.adoc @@ -51,7 +51,7 @@ public: == Resources -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c128-virtual-functions-should-specify-exactly-one-of-virtual-override-or-final[C.128 - Virtual functions should specify exactly one of virtual, override, or final] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c128-virtual-functions-should-specify-exactly-one-of-virtual-override-or-final[C.128: Virtual functions should specify exactly one of `virtual`, `override`, or `final`] === Related rules diff --git a/rules/S3490/cfamily/rule.adoc b/rules/S3490/cfamily/rule.adoc index d9ba29b6683..fc3c5d3ad08 100644 --- a/rules/S3490/cfamily/rule.adoc +++ b/rules/S3490/cfamily/rule.adoc @@ -69,7 +69,7 @@ struct Book { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c30-define-a-destructor-if-a-class-needs-an-explicit-action-at-object-destruction[{cpp} Core Guidelines C.30] - Define a destructor if a class needs an explicit action at object destruction +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c30-define-a-destructor-if-a-class-needs-an-explicit-action-at-object-destruction[C.30: Define a destructor if a class needs an explicit action at object destruction] ifdef::env-github,rspecator-view[] diff --git a/rules/S3518/cfamily/rule.adoc b/rules/S3518/cfamily/rule.adoc index 650317327e8..ca174f4bdda 100644 --- a/rules/S3518/cfamily/rule.adoc +++ b/rules/S3518/cfamily/rule.adoc @@ -141,7 +141,7 @@ std::optional safe_division(int a, int b) { === External coding guidelines -* {cpp} Core Guidelines https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md[ES.105: Don't divide by integer zero] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es105-dont-divide-by-integer-zero[ES.105: Don't divide by integer zero] ifdef::env-github,rspecator-view[] diff --git a/rules/S3562/cfamily/rule.adoc b/rules/S3562/cfamily/rule.adoc index 929fc82236f..fb5e122978e 100644 --- a/rules/S3562/cfamily/rule.adoc +++ b/rules/S3562/cfamily/rule.adoc @@ -88,7 +88,7 @@ void example(fruit f) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#enum2-use-enumerations-to-represent-sets-of-related-named-constants[{cpp} Core Guidelines - Enum.2] - Use enumerations to represent sets of related named constants +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#enum2-use-enumerations-to-represent-sets-of-related-named-constants[Enum.2: Use enumerations to represent sets of related named constants] === Related rules diff --git a/rules/S3630/see.adoc b/rules/S3630/see.adoc index f52684e69c7..a43789700d5 100644 --- a/rules/S3630/see.adoc +++ b/rules/S3630/see.adoc @@ -1,3 +1,3 @@ == Resources -* CppCoreGuidelines, Type safety profile - Type.1: Don't use reinterpret_cast. +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#prosafety-type-safety-profile[Type.1: Avoid casts] diff --git a/rules/S3642/cfamily/rule.adoc b/rules/S3642/cfamily/rule.adoc index 1aedaefcde3..19be5ad243b 100644 --- a/rules/S3642/cfamily/rule.adoc +++ b/rules/S3642/cfamily/rule.adoc @@ -78,7 +78,7 @@ When the enum is a private class member, the class encapsulates its use, and the === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#enum3-prefer-class-enums-over-plain-enums[Enum.3 - Prefer class enums over “plain” enums] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#enum3-prefer-class-enums-over-plain-enums[Enum.3: Prefer class enums over "plain" enums] ifdef::env-github,rspecator-view[] diff --git a/rules/S3646/cfamily/rule.adoc b/rules/S3646/cfamily/rule.adoc index 0aff07b291e..3997c441fdf 100644 --- a/rules/S3646/cfamily/rule.adoc +++ b/rules/S3646/cfamily/rule.adoc @@ -25,7 +25,7 @@ Container container; == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Rc-standalone[{cpp} Core Guidelines C.7] - Don't define a class or enum and declare a variable of its type in the same statement +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c7-dont-define-a-class-or-enum-and-declare-a-variable-of-its-type-in-the-same-statement[C.7: Don't define a class or enum and declare a variable of its type in the same statement] diff --git a/rules/S3656/cfamily/rule.adoc b/rules/S3656/cfamily/rule.adoc index dcb5adeb919..86bd4eb1b24 100644 --- a/rules/S3656/cfamily/rule.adoc +++ b/rules/S3656/cfamily/rule.adoc @@ -77,7 +77,7 @@ Const member variables and reference member variables are ignored since they don == Resources * MISRA {cpp}:2008, 11-0-1 - Member data in non-POD class types shall be private. -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c133-avoid-protected-data[ C.133 - Avoid protected data] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c133-avoid-protected-data[C.133: Avoid `protected` data] ifdef::env-github,rspecator-view[] diff --git a/rules/S3657/cfamily/rule.adoc b/rules/S3657/cfamily/rule.adoc index 9f2e3e27564..f2c656568ee 100644 --- a/rules/S3657/cfamily/rule.adoc +++ b/rules/S3657/cfamily/rule.adoc @@ -46,8 +46,8 @@ public: == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c60-make-copy-assignment-non-virtual-take-the-parameter-by-const-and-return-by-non-const[{cpp} Core Guidelines C.60] - Make copy assignment non-virtual, take the parameter by const&, and return by non-const& -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c63-make-move-assignment-non-virtual-take-the-parameter-by\--and-return-by-non-const-[{cpp} Core Guidelines C.63] - Make move assignment non-virtual, take the parameter by &&, and return by non-const & +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c60-make-copy-assignment-non-virtual-take-the-parameter-by-const-and-return-by-non-const[C.60: Make copy assignment non-`virtual`, take the parameter by `const&`, and return by non-`const&`] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c63-make-move-assignment-non-virtual-take-the-parameter-by--and-return-by-non-const[C.63: Make move assignment non-`virtual`, take the parameter by `&&`, and return by non-`const&`] ifdef::env-github,rspecator-view[] diff --git a/rules/S3687/cfamily/rule.adoc b/rules/S3687/cfamily/rule.adoc index 9d43dbc792e..85469009fe5 100644 --- a/rules/S3687/cfamily/rule.adoc +++ b/rules/S3687/cfamily/rule.adoc @@ -39,7 +39,7 @@ User volatile * pvUser; == Resources * https://wiki.sei.cmu.edu/confluence/display/c/CON02-C.+Do+not+use+volatile+as+a+synchronization+primitive[CERT CON02-C] - Do not use volatile as a synchronization primitive -* https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#cp200-use-volatile-only-to-talk-to-non-c-memory[{cpp} Core Guidelines CP.200] - Use volatile only to talk to non-{cpp} memory +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp200-use-volatile-only-to-talk-to-non-c-memory[CP.200: Use `volatile` only to talk to non-{cpp} memory] ifdef::env-github,rspecator-view[] diff --git a/rules/S3692/cfamily/rule.adoc b/rules/S3692/cfamily/rule.adoc index 2556010a62a..cb79b761b19 100644 --- a/rules/S3692/cfamily/rule.adoc +++ b/rules/S3692/cfamily/rule.adoc @@ -30,7 +30,7 @@ struct Foo { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c87-beware-of\--on-base-classes[{cpp} Core Guidelines C.87] - Beware of ++==++ on base classes +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c87-beware-of--on-base-classes[C.87: Beware of `==` on base classes] ifdef::env-github,rspecator-view[] diff --git a/rules/S3698/cfamily/rule.adoc b/rules/S3698/cfamily/rule.adoc index 763ce4bb23d..118683c422e 100644 --- a/rules/S3698/cfamily/rule.adoc +++ b/rules/S3698/cfamily/rule.adoc @@ -34,7 +34,7 @@ try { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Re-exception-types[{cpp} Core Guidelines E.14] - Use purpose-designed user-defined types as exceptions (not built-in types) +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#e14-use-purpose-designed-user-defined-types-as-exceptions-not-built-in-types[E.14: Use purpose-designed user-defined types as exceptions (not built-in types)] ifdef::env-github,rspecator-view[] diff --git a/rules/S4962/cfamily/rule.adoc b/rules/S4962/cfamily/rule.adoc index 5f2955485eb..47751021937 100644 --- a/rules/S4962/cfamily/rule.adoc +++ b/rules/S4962/cfamily/rule.adoc @@ -29,7 +29,7 @@ void usage() === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es47-use-nullptr-rather-than-0-or-null[ES.47 - Use nullptr rather than 0 or NULL] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es47-use-nullptr-rather-than-0-or-null[ES.47: Use `nullptr` rather than `0` or `NULL`] ifdef::env-github,rspecator-view[] diff --git a/rules/S4998/cfamily/rule.adoc b/rules/S4998/cfamily/rule.adoc index 3c74d4832bc..2b797267b96 100644 --- a/rules/S4998/cfamily/rule.adoc +++ b/rules/S4998/cfamily/rule.adoc @@ -50,7 +50,7 @@ void drawAll(std::vector> v) === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#r32-take-a-unique_ptrwidget-parameter-to-express-that-a-function-assumes-ownership-of-a-widget[R.32 - Take a unique_ptr parameter to express that a function assumes ownership of a widget] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r32-take-a-unique_ptrwidget-parameter-to-express-that-a-function-assumes-ownership-of-a-widget[R.32: Take a `unique_ptr` parameter to express that a function assumes ownership of a `widget`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5008/cfamily/rule.adoc b/rules/S5008/cfamily/rule.adoc index da922e89647..d8eb199e345 100644 --- a/rules/S5008/cfamily/rule.adoc +++ b/rules/S5008/cfamily/rule.adoc @@ -50,8 +50,8 @@ class Process { == Resources -* https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#i4-make-interfaces-precisely-and-strongly-typed[{cpp} Core Guidelines I.4] - Make interfaces precisely and strongly typed -* https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#t3-use-templates-to-express-containers-and-ranges[{cpp} Core Guidelines T.3] - Use templates to express containers and ranges +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#i4-make-interfaces-precisely-and-strongly-typed[I.4: Make interfaces precisely and strongly typed] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#t3-use-templates-to-express-containers-and-ranges[T.3: Use templates to express containers and ranges] ifdef::env-github,rspecator-view[] diff --git a/rules/S5018/cfamily/rule.adoc b/rules/S5018/cfamily/rule.adoc index 88cc8ef0117..8dbca1d0181 100644 --- a/rules/S5018/cfamily/rule.adoc +++ b/rules/S5018/cfamily/rule.adoc @@ -55,8 +55,8 @@ void swap(A& a1, A& a2) noexcept; == Resources -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c66-make-move-operations-noexcept[C.66 - Make move operations ``++noexcept++``] -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c85-make-swap-noexcept[C.85 - Make swap operations ``++noexcept++``] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c66-make-move-operations-noexcept[C.66: Make move operations `noexcept`] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c85-make-swap-noexcept[C.85: Make `swap` `noexcept`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5019/cfamily/rule.adoc b/rules/S5019/cfamily/rule.adoc index 51a82f2788b..cdb81041a15 100644 --- a/rules/S5019/cfamily/rule.adoc +++ b/rules/S5019/cfamily/rule.adoc @@ -55,7 +55,7 @@ class A { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f54-if-you-capture-this-capture-all-variables-explicitly-no-default-capture[{cpp} Core Guidelines F.54] - If you capture ``++this++``, capture all variables explicitly (no default capture) +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f54-when-writing-a-lambda-that-captures-this-or-any-class-data-member-dont-use--default-capture[F.54: When writing a lambda that captures `this` or any class data member, don't use ``++[=]++`` default capture] ifdef::env-github,rspecator-view[] diff --git a/rules/S5025/cfamily/rule.adoc b/rules/S5025/cfamily/rule.adoc index 989de4d5969..c3f6f05f6b0 100644 --- a/rules/S5025/cfamily/rule.adoc +++ b/rules/S5025/cfamily/rule.adoc @@ -53,8 +53,8 @@ If the result of a new is immediately passed as an argument to a function, we as == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#r11-avoid-calling-new-and-delete-explicitly[{cpp} Core Guidelines R.11] - Avoid calling new and delete explicitly -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c149-use-unique_ptr-or-shared_ptr-to-avoid-forgetting-to-delete-objects-created-using-new[{cpp} Core Guidelines C.149] - Use unique_ptr or shared_ptr to avoid forgetting to delete objects created using new +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r11-avoid-calling-new-and-delete-explicitly[R.11: Avoid calling `new` and `delete` explicitly] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c149-use-unique_ptr-or-shared_ptr-to-avoid-forgetting-to-delete-objects-created-using-new[C.149: Use `unique_ptr` or `shared_ptr` to avoid forgetting to `delete` objects created using `new`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5028/cfamily/rule.adoc b/rules/S5028/cfamily/rule.adoc index b877e77a59d..0f418568079 100644 --- a/rules/S5028/cfamily/rule.adoc +++ b/rules/S5028/cfamily/rule.adoc @@ -33,8 +33,8 @@ enum class Actions {Left, Right, Jump, Shoot}; == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es31-dont-use-macros-for-constants-or-functions[{cpp} Core Guidelines - ES.31] - Don’t use macros for constants or “functions” -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#enum1-prefer-enumerations-over-macros[{cpp} Core Guidelines - Enum.1] - Prefer enumerations over macros +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es31-dont-use-macros-for-constants-or-functions[ES.31: Don't use macros for constants or "functions"] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#enum1-prefer-enumerations-over-macros[Enum.1: Prefer enumerations over macros] ifdef::env-github,rspecator-view[] diff --git a/rules/S5184/cfamily/rule.adoc b/rules/S5184/cfamily/rule.adoc index a2e906e5443..bd97b0e8bbf 100644 --- a/rules/S5184/cfamily/rule.adoc +++ b/rules/S5184/cfamily/rule.adoc @@ -31,7 +31,7 @@ void f() { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es84-dont-try-to-declare-a-local-variable-with-no-name[{cpp} Core Guidelines ES.84] - Don’t (try to) declare a local variable with no name +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es84-dont-try-to-declare-a-local-variable-with-no-name[ES.84: Don't try to declare a local variable with no name] ifdef::env-github,rspecator-view[] diff --git a/rules/S5205/cfamily/rule.adoc b/rules/S5205/cfamily/rule.adoc index eded8845904..2b3d0ddf2a5 100644 --- a/rules/S5205/cfamily/rule.adoc +++ b/rules/S5205/cfamily/rule.adoc @@ -51,7 +51,7 @@ private: == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#t40-use-function-objects-to-pass-operations-to-algorithms[{cpp} Core Guidelines T.40] - Use function objects to pass operations to algorithms +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#t40-use-function-objects-to-pass-operations-to-algorithms[T.40: Use function objects to pass operations to algorithms] ifdef::env-github,rspecator-view[] diff --git a/rules/S5213/cfamily/rule.adoc b/rules/S5213/cfamily/rule.adoc index 3b6840cf7e6..1dbab828b78 100644 --- a/rules/S5213/cfamily/rule.adoc +++ b/rules/S5213/cfamily/rule.adoc @@ -56,7 +56,7 @@ This rule ignores virtual functions, that don't work well with templates. == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#t49-where-possible-avoid-type-erasure[{cpp} Core Guidelines T.49] - Where possible, avoid type-erasure +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#t49-where-possible-avoid-type-erasure[T.49: Where possible, avoid type-erasure] ifdef::env-github,rspecator-view[] diff --git a/rules/S5270/cfamily/rule.adoc b/rules/S5270/cfamily/rule.adoc index 05d7759d3fa..af5a52ed9f1 100644 --- a/rules/S5270/cfamily/rule.adoc +++ b/rules/S5270/cfamily/rule.adoc @@ -73,7 +73,7 @@ std::size_t elementsCount(const std::vector& vec) { * MISRA C:2004, 16.1 - Functions shall not be defined with a variable number of arguments. * https://wiki.sei.cmu.edu/confluence/x/5ns-BQ[CERT, DCL50-CPP.] - Do not define a C-style variadic function -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#-es34-dont-define-a-c-style-variadic-function[{cpp} Core Guidelines ES.34] Don't define a (C-style) variadic function +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#-es34-dont-define-a-c-style-variadic-function[ES.34: Don't define a (C-style) variadic function] === Related rules diff --git a/rules/S5274/cfamily/rule.adoc b/rules/S5274/cfamily/rule.adoc index 8ffc5800fdb..8f62b7e4598 100644 --- a/rules/S5274/cfamily/rule.adoc +++ b/rules/S5274/cfamily/rule.adoc @@ -64,7 +64,7 @@ A f() { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#reason-62[F.48: Don’t return std::move(local)] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f48-dont-return-stdmovelocal[F.48: Don't `return std::move(local)`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5314/cfamily/rule.adoc b/rules/S5314/cfamily/rule.adoc index f55cff49940..926a860c932 100644 --- a/rules/S5314/cfamily/rule.adoc +++ b/rules/S5314/cfamily/rule.adoc @@ -200,7 +200,7 @@ the ABA problem, where `A` and `B` refers to the values of the resource. === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#cp43-minimize-time-spent-in-a-critical-section[CP.43: Minimize time spent in a critical section] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp43-minimize-time-spent-in-a-critical-section[CP.43: Minimize time spent in a critical section] === Related rules diff --git a/rules/S5402/cfamily/rule.adoc b/rules/S5402/cfamily/rule.adoc index 88328353399..eeb2480e929 100644 --- a/rules/S5402/cfamily/rule.adoc +++ b/rules/S5402/cfamily/rule.adoc @@ -102,7 +102,7 @@ Exceptions classes must be copyable. Hence, this rule does not apply to exceptio == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c67-a-polymorphic-class-should-suppress-copying[{cpp} Core Guidelines C.67] - A polymorphic class should suppress copying +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c67-a-polymorphic-class-should-suppress-public-copymove[C.67: A polymorphic class should suppress public copy/move] ifdef::env-github,rspecator-view[] diff --git a/rules/S5404/cfamily/rule.adoc b/rules/S5404/cfamily/rule.adoc index e05e0f2bd55..09e4a8bd64f 100644 --- a/rules/S5404/cfamily/rule.adoc +++ b/rules/S5404/cfamily/rule.adoc @@ -80,7 +80,7 @@ int main(){ == Resources * https://www.modernescpp.com/index.php/c-core-guidelines-be-aware-of-the-traps-of-condition-variables[The traps of condition variables] -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#cp42-dont-wait-without-a-condition[{cpp} Core Guidelines - CP.42] - Don't wait without a condition +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp42-dont-wait-without-a-condition[CP.42: Don't `wait` without a condition] ifdef::env-github,rspecator-view[] diff --git a/rules/S5405/cfamily/rule.adoc b/rules/S5405/cfamily/rule.adoc index ba5956c818d..447615f3b7d 100644 --- a/rules/S5405/cfamily/rule.adoc +++ b/rules/S5405/cfamily/rule.adoc @@ -57,7 +57,7 @@ int main() { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c152-never-assign-a-pointer-to-an-array-of-derived-class-objects-to-a-pointer-to-its-base[{cpp} Core Guidelines C.152] - Never assign a pointer to an array of derived class objects to a pointer to its base +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c152-never-assign-a-pointer-to-an-array-of-derived-class-objects-to-a-pointer-to-its-base[C.152: Never assign a pointer to an array of derived class objects to a pointer to its base] ifdef::env-github,rspecator-view[] diff --git a/rules/S5409/cfamily/rule.adoc b/rules/S5409/cfamily/rule.adoc index 7d7c371b9b9..cb802ecf17e 100644 --- a/rules/S5409/cfamily/rule.adoc +++ b/rules/S5409/cfamily/rule.adoc @@ -40,7 +40,7 @@ std::unordered_set mySet; == Resources -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c89-make-a-hash-noexcept[C.89 - Make a hash noexcept] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c89-make-a-hash-noexcept[C.89: Make a `hash` `noexcept`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5414/cfamily/rule.adoc b/rules/S5414/cfamily/rule.adoc index e568522e06d..11f3e9e3ef0 100644 --- a/rules/S5414/cfamily/rule.adoc +++ b/rules/S5414/cfamily/rule.adoc @@ -58,8 +58,8 @@ private: === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c134-ensure-all-non-const-data-members-have-the-same-access-level[C.134: Ensure all non-const data members have the same access level] -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c9-minimize-exposure-of-members[C.9: Minimize exposure of members] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c134-ensure-all-non-const-data-members-have-the-same-access-level[C.134: Ensure all non-`const` data members have the same access level] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c9-minimize-exposure-of-members[C.9: Minimize exposure of members] ifdef::env-github,rspecator-view[] diff --git a/rules/S5415/cfamily/rule.adoc b/rules/S5415/cfamily/rule.adoc index ef4e6f9b595..911313d8964 100644 --- a/rules/S5415/cfamily/rule.adoc +++ b/rules/S5415/cfamily/rule.adoc @@ -67,7 +67,7 @@ void test() { == Resources -* https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es56-write-stdmove-only-when-you-need-to-explicitly-move-an-object-to-another-scope[{cpp} Core Guidelines ES.56] - Write "std::move()" only when you need to explicitly move an object to another scope +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es56-write-stdmove-only-when-you-need-to-explicitly-move-an-object-to-another-scope[ES.56: Write `std::move()` only when you need to explicitly move an object to another scope] ifdef::env-github,rspecator-view[] diff --git a/rules/S5416/cfamily/rule.adoc b/rules/S5416/cfamily/rule.adoc index 0ae98b7f916..1d8cdfa131b 100644 --- a/rules/S5416/cfamily/rule.adoc +++ b/rules/S5416/cfamily/rule.adoc @@ -23,7 +23,7 @@ using FunctionPointerType = void (*)(int); == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#t43-prefer-using-over-typedef-for-defining-aliases[{cpp} Core Guidelines - T.43] - Prefer using over typedef for defining aliases +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#t43-prefer-using-over-typedef-for-defining-aliases[T.43: Prefer `using` over `typedef` for defining aliases] ifdef::env-github,rspecator-view[] diff --git a/rules/S5417/cfamily/rule.adoc b/rules/S5417/cfamily/rule.adoc index 4709638c9e2..fed4e1b7ed9 100644 --- a/rules/S5417/cfamily/rule.adoc +++ b/rules/S5417/cfamily/rule.adoc @@ -87,8 +87,8 @@ struct C { * {cpp} reference - https://en.cppreference.com/w/cpp/utility/move[std::move] * {cpp} reference - https://en.cppreference.com/w/cpp/utility/forward[std::forward] * {cpp} reference - https://en.cppreference.com/w/cpp/language/reference#Forwarding_references[Forwarding references] -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f18-for-will-move-from-parameters-pass-by-x-and-stdmove-the-parameter[{cpp} Core Guidelines F.18] - For “will-move-from” parameters, pass by ``++X&&++`` and ``++std::move++`` the parameter -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f19-for-forward-parameters-pass-by-tp-and-only-stdforward-the-parameter[{cpp} Core Guidelines F.19] - For “forward” parameters, pass by ``++TP&&++`` and only ``++std::forward++`` the parameter +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f18-for-will-move-from-parameters-pass-by-x-and-stdmove-the-parameter[F.18: For "will-move-from" parameters, pass by `X&&` and `std::move` the parameter] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f19-for-forward-parameters-pass-by-tp-and-only-stdforward-the-parameter[F.19: For "forward" parameters, pass by `TP&&` and only `std::forward` the parameter] ifdef::env-github,rspecator-view[] diff --git a/rules/S5419/cfamily/rule.adoc b/rules/S5419/cfamily/rule.adoc index c8bb6b93fc6..17dcf8ca536 100644 --- a/rules/S5419/cfamily/rule.adoc +++ b/rules/S5419/cfamily/rule.adoc @@ -54,7 +54,7 @@ double f() { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#i4-make-interfaces-precisely-and-strongly-typed[{cpp} Core Guidelines I.4] - Make interfaces precisely and strongly typed +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#i4-make-interfaces-precisely-and-strongly-typed[I.4: Make interfaces precisely and strongly typed] ifdef::env-github,rspecator-view[] diff --git a/rules/S5421/cfamily/rule.adoc b/rules/S5421/cfamily/rule.adoc index 44bfaebc682..252336c6857 100644 --- a/rules/S5421/cfamily/rule.adoc +++ b/rules/S5421/cfamily/rule.adoc @@ -46,7 +46,7 @@ int main() { == Resources -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#i2-avoid-non-const-global-variables[I.2 - Avoid non-const global variables] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#i2-avoid-non-const-global-variables[I.2: Avoid non-`const` global variables] ifdef::env-github,rspecator-view[] diff --git a/rules/S5424/cfamily/rule.adoc b/rules/S5424/cfamily/rule.adoc index 612853b7a40..2e85f304bdf 100644 --- a/rules/S5424/cfamily/rule.adoc +++ b/rules/S5424/cfamily/rule.adoc @@ -58,8 +58,8 @@ public: == Resources -* http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#c48-prefer-in-class-initializers-to-member-initializers-in-constructors-for-constant-initializers[{cpp} core guidelines C.48]: Prefer in-class initializers to member initializers in constructors for constant initializers -* http://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#c49-prefer-initialization-to-assignment-in-constructors[{cpp} core guidelines C.49]: Prefer initialization to assignment in constructors +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c48-prefer-in-class-initializers-to-member-initializers-in-constructors-for-constant-initializers[C.48: Prefer in-class initializers to member initializers in constructors for constant initializers] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c49-prefer-initialization-to-assignment-in-constructors[C.49: Prefer initialization to assignment in constructors] diff --git a/rules/S5425/cfamily/rule.adoc b/rules/S5425/cfamily/rule.adoc index 13c88c27569..23ed8b0bd02 100644 --- a/rules/S5425/cfamily/rule.adoc +++ b/rules/S5425/cfamily/rule.adoc @@ -51,7 +51,7 @@ int main() { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f19-for-forward-parameters-pass-by-tp-and-only-stdforward-the-parameter[{cpp} Core Guidelines F.19] - For “forward” parameters, pass by TP&& and only std::forward the parameter +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f19-for-forward-parameters-pass-by-tp-and-only-stdforward-the-parameter[F.19: For "forward" parameters, pass by `TP&&` and only `std::forward` the parameter] ifdef::env-github,rspecator-view[] diff --git a/rules/S5495/cfamily/rule.adoc b/rules/S5495/cfamily/rule.adoc index a61ef799998..a59bc89ddc1 100644 --- a/rules/S5495/cfamily/rule.adoc +++ b/rules/S5495/cfamily/rule.adoc @@ -52,6 +52,6 @@ Vec applyPermutation(const Vec& v, const Vec& permutation) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f52-prefer-capturing-by-reference-in-lambdas-that-will-be-used-locally-including-passed-to-algorithms[{cpp} Core Guidelines F.52] - Prefer capturing by reference in lambdas that will be used locally, including passed to algorithms +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f52-prefer-capturing-by-reference-in-lambdas-that-will-be-used-locally-including-passed-to-algorithms[F.52: Prefer capturing by reference in lambdas that will be used locally, including passed to algorithms] diff --git a/rules/S5500/cfamily/rule.adoc b/rules/S5500/cfamily/rule.adoc index 174ed1969e9..c9a713379f7 100644 --- a/rules/S5500/cfamily/rule.adoc +++ b/rules/S5500/cfamily/rule.adoc @@ -60,7 +60,7 @@ public: == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f18-for-will-move-from-parameters-pass-by-x-and-stdmove-the-parameter[{cpp} Core Guidelines F.18] - For “will-move-from” parameters, pass by X&& and std::move the parameter +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f18-for-will-move-from-parameters-pass-by-x-and-stdmove-the-parameter[F.18: For "will-move-from" parameters, pass by `X&&` and `std::move` the parameter] ifdef::env-github,rspecator-view[] diff --git a/rules/S5502/cfamily/rule.adoc b/rules/S5502/cfamily/rule.adoc index c262f828fdb..bddba5166b2 100644 --- a/rules/S5502/cfamily/rule.adoc +++ b/rules/S5502/cfamily/rule.adoc @@ -73,7 +73,7 @@ void f() { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#r13-perform-at-most-one-explicit-resource-allocation-in-a-single-expression-statement[R.13 - Perform at most one explicit resource allocation in a single expression statement] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r13-perform-at-most-one-explicit-resource-allocation-in-a-single-expression-statement[R.13: Perform at most one explicit resource allocation in a single expression statement] ifdef::env-github,rspecator-view[] diff --git a/rules/S5503/cfamily/rule.adoc b/rules/S5503/cfamily/rule.adoc index a20c6094a7b..f29c10d35d2 100644 --- a/rules/S5503/cfamily/rule.adoc +++ b/rules/S5503/cfamily/rule.adoc @@ -49,7 +49,7 @@ void f(Base *b) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c148-use-dynamic_cast-to-a-pointer-type-when-failure-to-find-the-required-class-is-considered-a-valid-alternative[{cpp} Core Guidelines C.148] - Use dynamic_cast to a pointer type when failure to find the required class is considered a valid alternative +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c148-use-dynamic_cast-to-a-pointer-type-when-failure-to-find-the-required-class-is-considered-a-valid-alternative[C.148: Use `dynamic_cast` to a pointer type when failure to find the required class is considered a valid alternative] ifdef::env-github,rspecator-view[] diff --git a/rules/S5506/cfamily/rule.adoc b/rules/S5506/cfamily/rule.adoc index b46a9fefbff..aebdab622c0 100644 --- a/rules/S5506/cfamily/rule.adoc +++ b/rules/S5506/cfamily/rule.adoc @@ -82,7 +82,7 @@ bool storeIfRelevantInSharedContext(const DataItem &dataItem) { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#cp20-use-raii-never-plain-lockunlock[CP.20 - Use RAII, never plain lock()/unlock()] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp20-use-raii-never-plain-lockunlock[CP.20: Use RAII, never plain `lock()`/`unlock()`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5507/cfamily/rule.adoc b/rules/S5507/cfamily/rule.adoc index 80964315f40..3f281fe1074 100644 --- a/rules/S5507/cfamily/rule.adoc +++ b/rules/S5507/cfamily/rule.adoc @@ -46,7 +46,7 @@ void f1() { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#r37-do-not-pass-a-pointer-or-reference-obtained-from-an-aliased-smart-pointer[{cpp} Core Guidelines R.37] - Do not pass a pointer or reference obtained from an aliased smart pointer +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r37-do-not-pass-a-pointer-or-reference-obtained-from-an-aliased-smart-pointer[R.37: Do not pass a pointer or reference obtained from an aliased smart pointer] ifdef::env-github,rspecator-view[] diff --git a/rules/S5523/cfamily/rule.adoc b/rules/S5523/cfamily/rule.adoc index 402cbff30ff..ef606cc3569 100644 --- a/rules/S5523/cfamily/rule.adoc +++ b/rules/S5523/cfamily/rule.adoc @@ -91,7 +91,7 @@ Buffers can be left uninitialized as long as they are written into immediately a == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es20-always-initialize-an-object[{cpp} Core Guidelines ES.20] - Always initialize an object +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es20-always-initialize-an-object[ES.20: Always initialize an object] ifdef::env-github,rspecator-view[] diff --git a/rules/S5524/cfamily/rule.adoc b/rules/S5524/cfamily/rule.adoc index a94e937cb9a..fb73a73763e 100644 --- a/rules/S5524/cfamily/rule.adoc +++ b/rules/S5524/cfamily/rule.adoc @@ -55,7 +55,7 @@ void f() { // Compliant: C++17 solution == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#cp21-use-stdlock-or-stdscoped_lock-to-acquire-multiple-mutexes[{cpp} Core Guidelines CP.21] - Use std::lock() or std::scoped_lock to acquire multiple mutexes +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp21-use-stdlock-or-stdscoped_lock-to-acquire-multiple-mutexes[CP.21: Use `std::lock()` or `std::scoped_lock` to acquire multiple ``mutex``es] * {cpp} reference - https://en.cppreference.com/w/cpp/thread/scoped_lock[cppreference.com - std::scoped_lock] diff --git a/rules/S5566/cfamily/rule.adoc b/rules/S5566/cfamily/rule.adoc index 1b6ebbf8e7d..008e7de85cd 100644 --- a/rules/S5566/cfamily/rule.adoc +++ b/rules/S5566/cfamily/rule.adoc @@ -112,8 +112,8 @@ void f(vector &v) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es71-prefer-a-range-for-statement-to-a-for-statement-when-there-is-a-choice[{cpp} Core Guidelines ES.71] - Prefer a range-for-statement to a for-statement when there is a choice -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#p3-express-intent[{cpp} Core Guidelines P.3] - Express intent +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es71-prefer-a-range-for-statement-to-a-for-statement-when-there-is-a-choice[ES.71: Prefer a range-`for`-statement to a `for`-statement when there is a choice] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#p3-express-intent[P.3: Express intent] ifdef::env-github,rspecator-view[] diff --git a/rules/S5570/cfamily/rule.adoc b/rules/S5570/cfamily/rule.adoc index 8c92fe9436e..ba1ae3843e6 100644 --- a/rules/S5570/cfamily/rule.adoc +++ b/rules/S5570/cfamily/rule.adoc @@ -28,7 +28,7 @@ This rule does not apply to overloaded operators because they respect the sequen == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es44-dont-depend-on-order-of-evaluation-of-function-arguments[{cpp} Core Guidelines ES.44] - Don't depend on order of evaluation of function arguments +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es44-dont-depend-on-order-of-evaluation-of-function-arguments[ES.44: Don't depend on order of evaluation of function arguments] * {cpp} reference - https://en.cppreference.com/w/cpp/language/eval_order[cppreference.com - order of evaluation] diff --git a/rules/S5658/cfamily/rule.adoc b/rules/S5658/cfamily/rule.adoc index 504b2b54f68..f62b0121c84 100644 --- a/rules/S5658/cfamily/rule.adoc +++ b/rules/S5658/cfamily/rule.adoc @@ -54,7 +54,7 @@ void f1 ( ) * MISRA C:2004, 17.3 - >, >=, <, +<=+ shall not be applied to pointer types except where they point to the same array. * MISRA {cpp}:2008, 5-0-18 - >, >=, <, +<=+ shall not be applied to objects of pointer type, except where they point to the same array. -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es62-dont-compare-pointers-into-different-arrays[{cpp} Core Guidelines ES.62] - Don't compare pointers into different arrays +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es62-dont-compare-pointers-into-different-arrays[ES.62: Don't compare pointers into different arrays] ifdef::env-github,rspecator-view[] diff --git a/rules/S5827/cfamily/rule.adoc b/rules/S5827/cfamily/rule.adoc index 014b3fdce14..1c5d6d25260 100644 --- a/rules/S5827/cfamily/rule.adoc +++ b/rules/S5827/cfamily/rule.adoc @@ -45,7 +45,7 @@ The rule S6234 detects other situations where `auto` can improve readability. === External coding guidelines -* https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#es11-use-auto-to-avoid-redundant-repetition-of-type-names[{cpp} Core Guidelines ES.11] - Use auto to avoid redundant repetition of type names +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es11-use-auto-to-avoid-redundant-repetition-of-type-names[ES.11: Use `auto` to avoid redundant repetition of type names] === Related rules diff --git a/rules/S5829/cfamily/rule.adoc b/rules/S5829/cfamily/rule.adoc index 3e7c32734f3..fc18cb9e878 100644 --- a/rules/S5829/cfamily/rule.adoc +++ b/rules/S5829/cfamily/rule.adoc @@ -112,7 +112,7 @@ vector v = { 1, 2, 4 }; == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/8e82f0a0d9ba3992af2d61480250e1c577df4a28/CppCoreGuidelines.md#es23-prefer-the\--initializer-syntax[{cpp} Core Guidelines ES.23] - Prefer the {} initializer syntax +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es23-prefer-the--initializer-syntax[ES.23: Prefer the `{}`-initializer syntax] ifdef::env-github,rspecator-view[] diff --git a/rules/S5912/cfamily/rule.adoc b/rules/S5912/cfamily/rule.adoc index c9a1dfb55c5..4c9b751e38b 100644 --- a/rules/S5912/cfamily/rule.adoc +++ b/rules/S5912/cfamily/rule.adoc @@ -130,6 +130,5 @@ This goes well in hand with non-copyable classes. === External coding guidelines -* {cpp} Core Guidelines - -https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es63-dont-slice[ES.63 Don't slice] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es63-dont-slice[ES.63: Don't slice] diff --git a/rules/S5945/cfamily/rule.adoc b/rules/S5945/cfamily/rule.adoc index 62ac15abf62..a1362f93f66 100644 --- a/rules/S5945/cfamily/rule.adoc +++ b/rules/S5945/cfamily/rule.adoc @@ -47,7 +47,7 @@ This rule will not report the use of C-style arrays in ``++extern "C"++`` code ( == Resources -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/46dadd0b16b904fe0ff88c1fef9b0702dfd139e2/CppCoreGuidelines.md#slcon1-prefer-using-stl-array-or-vector-instead-of-a-c-array[SL.con.1 - Prefer using STL array or vector instead of a C array] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#slcon1-prefer-using-stl-array-or-vector-instead-of-a-c-array[SL.con.1: Prefer using STL `array` or `vector` instead of a C array] ifdef::env-github,rspecator-view[] diff --git a/rules/S5946/cfamily/rule.adoc b/rules/S5946/cfamily/rule.adoc index 33d10235bf7..79170c1d342 100644 --- a/rules/S5946/cfamily/rule.adoc +++ b/rules/S5946/cfamily/rule.adoc @@ -51,7 +51,7 @@ How are you? == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/c553535fb8dda2839d13ab5f807ffbc66b63d67b/CppCoreGuidelines.md#sl50-avoid-endl[{cpp} Core Guidelines SL.50] - Avoid endl +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#slio50-avoid-endl[SL.io.50: Avoid `endl`] ifdef::env-github,rspecator-view[] diff --git a/rules/S5950/cfamily/rule.adoc b/rules/S5950/cfamily/rule.adoc index a8e0f7b7241..6a3f3552242 100644 --- a/rules/S5950/cfamily/rule.adoc +++ b/rules/S5950/cfamily/rule.adoc @@ -71,8 +71,8 @@ In addition, `make_shared` does not support the following: == Resources -* {cpp] Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c150-use-make_unique-to-construct-objects-owned-by-unique_ptrs[C.150 - Use make_unique() to construct objects owned by unique_ptrs] -* {cpp] Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c151-use-make_shared-to-construct-objects-owned-by-shared_ptrs[C.151 - Use make_shared() to construct objects owned by shared_ptrs] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c150-use-make_unique-to-construct-objects-owned-by-unique_ptrs[C.150: Use `make_unique()` to construct objects owned by ``unique_ptr``s] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c151-use-make_shared-to-construct-objects-owned-by-shared_ptrs[C.151: Use `make_shared()` to construct objects owned by ``shared_ptr``s] ifdef::env-github,rspecator-view[] diff --git a/rules/S5951/cfamily/rule.adoc b/rules/S5951/cfamily/rule.adoc index d4eb8da95f3..7519b1ba2b0 100644 --- a/rules/S5951/cfamily/rule.adoc +++ b/rules/S5951/cfamily/rule.adoc @@ -47,5 +47,5 @@ A f(); == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/c553535fb8dda2839d13ab5f807ffbc66b63d67b/CppCoreGuidelines.md#enforcement-40[{cpp} Core Guidelines F.20] - Flag returning a const value. +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f20-for-out-output-values-prefer-return-values-to-output-parameters[F.20: For "out" output values, prefer return values to output parameters] diff --git a/rules/S5952/cfamily/rule.adoc b/rules/S5952/cfamily/rule.adoc index 663022b34a3..bc81ac47797 100644 --- a/rules/S5952/cfamily/rule.adoc +++ b/rules/S5952/cfamily/rule.adoc @@ -63,7 +63,7 @@ class Derived : public Base { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/9efcaf07f7013fb6d07ee004f936540164535c63/CppCoreGuidelines.md#c52-use-inheriting-constructors-to-import-constructors-into-a-derived-class-that-does-not-need-further-explicit-initialization[{cpp} Core Guidelines C.52] - Use inheriting constructors to import constructors into a derived class that does not need further explicit initialization +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c52-use-inheriting-constructors-to-import-constructors-into-a-derived-class-that-does-not-need-further-explicit-initialization[C.52: Use inheriting constructors to import constructors into a derived class that does not need further explicit initialization] ifdef::env-github,rspecator-view[] diff --git a/rules/S5954/cfamily/rule.adoc b/rules/S5954/cfamily/rule.adoc index e60399e2a3b..e2421730642 100644 --- a/rules/S5954/cfamily/rule.adoc +++ b/rules/S5954/cfamily/rule.adoc @@ -38,5 +38,5 @@ The move constructor of the ``++shared_ptr++`` itself. == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/c553535fb8dda2839d13ab5f807ffbc66b63d67b/CppCoreGuidelines.md#r34-take-a-shared_ptrwidget-parameter-to-express-that-a-function-is-part-owner[{cpp} Core Guidelines R.34] - Warn if a function takes a Shared_ptr by rvalue reference. Suggesting taking it by value instead. +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#r34-take-a-shared_ptrwidget-parameter-to-express-shared-ownership[R.34: Take a `shared_ptr` parameter to express shared ownership] diff --git a/rules/S5955/cfamily/rule.adoc b/rules/S5955/cfamily/rule.adoc index 0bb5e0ea5b6..ac57d2c41c3 100644 --- a/rules/S5955/cfamily/rule.adoc +++ b/rules/S5955/cfamily/rule.adoc @@ -34,7 +34,7 @@ void f() { == Resources -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es5-keep-scopes-small[ES.5 - Keep scopes small] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es5-keep-scopes-small[ES.5: Keep scopes small] ifdef::env-github,rspecator-view[] diff --git a/rules/S5962/cfamily/rule.adoc b/rules/S5962/cfamily/rule.adoc index 16b75230187..0259337f2b1 100644 --- a/rules/S5962/cfamily/rule.adoc +++ b/rules/S5962/cfamily/rule.adoc @@ -35,5 +35,5 @@ void startBackgroundTask(){ == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#cp26-dont-detach-a-thread[{cpp} Core Guidelines CP.26] - Don't detach() a thread +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp26-dont-detach-a-thread[CP.26: Don't `detach()` a thread] diff --git a/rules/S5981/cfamily/rule.adoc b/rules/S5981/cfamily/rule.adoc index 49f05f9bb11..6c895cc3399 100644 --- a/rules/S5981/cfamily/rule.adoc +++ b/rules/S5981/cfamily/rule.adoc @@ -67,7 +67,7 @@ double computeArea(const Shape* shape) { == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/c553535fb8dda2839d13ab5f807ffbc66b63d67b/CppCoreGuidelines.md#type2-dont-use-static_cast-downcasts-use-dynamic_cast-instead[{cpp} Core Guidelines - Type safety profile - Type.2]: Don’t use static_cast to downcast. Use dynamic_cast instead. +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#prosafety-type-safety-profile[Type.2: Don’t use `static_cast` to downcast] ifdef::env-github,rspecator-view[] diff --git a/rules/S6005/cfamily/rule.adoc b/rules/S6005/cfamily/rule.adoc index d226662f360..6e35cb65e3b 100644 --- a/rules/S6005/cfamily/rule.adoc +++ b/rules/S6005/cfamily/rule.adoc @@ -61,6 +61,6 @@ void printingMap(const std::map& map) { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#reason-48[F.21 - To return multiple “out” values, prefer returning a struct or tuple] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f21-to-return-multiple-out-values-prefer-returning-a-struct-or-tuple[F.21: To return multiple "out" values, prefer returning a struct or tuple] diff --git a/rules/S6168/cfamily/rule.adoc b/rules/S6168/cfamily/rule.adoc index 5a3abde23b2..fd6dde09000 100644 --- a/rules/S6168/cfamily/rule.adoc +++ b/rules/S6168/cfamily/rule.adoc @@ -39,5 +39,5 @@ int main() { === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#cp25-prefer-gsljoining_thread-over-stdthread[CP.25 - Prefer "gsl::joining_thread" over "std::thread"] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#cp25-prefer-gsljoining_thread-over-stdthread[CP.25: Prefer `gsl::joining_thread` over `std::thread`] diff --git a/rules/S6235/cfamily/rule.adoc b/rules/S6235/cfamily/rule.adoc index 4abdb100c00..4c84ad9b6dc 100644 --- a/rules/S6235/cfamily/rule.adoc +++ b/rules/S6235/cfamily/rule.adoc @@ -29,7 +29,7 @@ const long double tau = 6.28L; == Resources -* https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#Rl-const[{cpp} Core Guidelines NL.26] - Use conventional const notation +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#nl26-use-conventional-const-notation[NL.26: Use conventional `const` notation] ifdef::env-github,rspecator-view[] diff --git a/rules/S867/cfamily/rule.adoc b/rules/S867/cfamily/rule.adoc index 6bab61b9c1a..c6a94aef2da 100644 --- a/rules/S867/cfamily/rule.adoc +++ b/rules/S867/cfamily/rule.adoc @@ -59,7 +59,7 @@ Some people use ``++!!++`` as a shortcut to cast an integer to bool. This usage * MISRA C:2004, 12.6 - The operands of logical operators (&&, || and !) should be effectively Boolean. Expressions that are effectively Boolean should not be used as operands to operators other than (&&, || and !). * MISRA {cpp}:2008, 5-3-1 - Each operand of the ! operator, the logical && or the logical || operators shall have type bool. * https://wiki.sei.cmu.edu/confluence/display/c/EXP13-C.+Treat+relational+and+equality+operators+as+if+they+were+nonassociative[CERT, EXP13-C.] - Treat relational and equality operators as if they were nonassociative -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es87-dont-add-redundant\--or\--to-conditions[{cpp} Core Guidelines ES.87] - Don’t add redundant ++==++ or != to conditions +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es87-dont-add-redundant--or--to-conditions[ES.87: Don't add redundant `==` or `!=` to conditions] ifdef::env-github,rspecator-view[] diff --git a/rules/S877/cfamily/rule.adoc b/rules/S877/cfamily/rule.adoc index ff1011f26ca..077f8355a3c 100644 --- a/rules/S877/cfamily/rule.adoc +++ b/rules/S877/cfamily/rule.adoc @@ -33,7 +33,7 @@ void f2 ( A & a ) == Resources * MISRA {cpp} 2008, 5-3-3 - The unary & operator shall not be overloaded. -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#Ro-address-of[{cpp} Core Guidelines C.166] - Overload unary ``++&++`` only as part of a system of smart pointers and references +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c166-overload-unary--only-as-part-of-a-system-of-smart-pointers-and-references[C.166: Overload unary `&` only as part of a system of smart pointers and references] diff --git a/rules/S907/cfamily/rule.adoc b/rules/S907/cfamily/rule.adoc index 7b7963307cd..cbff7982596 100644 --- a/rules/S907/cfamily/rule.adoc +++ b/rules/S907/cfamily/rule.adoc @@ -28,7 +28,7 @@ for (int i = 0; i < 10; i++) { * MISRA C:2004, 14.4 - The goto statement shall not be used. * MISRA C:2012, 15.1 - The goto statement should not be used -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es76-avoid-goto[{cpp} Core Guidelines ES.76]: Avoid goto +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es76-avoid-goto[ES.76: Avoid `goto`] ifdef::env-github,rspecator-view[] diff --git a/rules/S923/cfamily/rule.adoc b/rules/S923/cfamily/rule.adoc index b607cd7a885..8f8cd45c881 100644 --- a/rules/S923/cfamily/rule.adoc +++ b/rules/S923/cfamily/rule.adoc @@ -19,5 +19,5 @@ void MyPrintf ( char_t * pFormat, ... ) // Noncompliant * MISRA C:2004, 16.1 - Functions shall not be defined with a variable number of arguments. * MISRA {cpp}:2008, 8-4-1 - Functions shall not be defined using the ellipsis notation. * https://wiki.sei.cmu.edu/confluence/x/5ns-BQ[CERT, DCL50-CPP.] - Do not define a C-style variadic function -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#-es34-dont-define-a-c-style-variadic-function[{cpp} Core Guidelines ES.34] Don't define a (C-style) variadic function -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#f55-dont-use-va_arg-arguments[{cpp} Core Guidelines F.55] Don't use va_arg arguments +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#-es34-dont-define-a-c-style-variadic-function[ES.34: Don't define a (C-style) variadic function] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#f55-dont-use-va_arg-arguments[F.55: Don't use `va_arg` arguments] diff --git a/rules/S945/cfamily/rule.adoc b/rules/S945/cfamily/rule.adoc index fe32dcaaf37..04e319bee9a 100644 --- a/rules/S945/cfamily/rule.adoc +++ b/rules/S945/cfamily/rule.adoc @@ -44,7 +44,7 @@ void b () == Resources * MISRA {cpp}:2008, 5-2-12 - An identifier with array type passed as a function argument shall not decay to a pointer. -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#i13-do-not-pass-an-array-as-a-single-pointer[{cpp} Core Guidelines I.13] - Do not pass an array as a single pointer +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#i13-do-not-pass-an-array-as-a-single-pointer[I.13: Do not pass an array as a single pointer] diff --git a/rules/S960/cfamily/rule.adoc b/rules/S960/cfamily/rule.adoc index 49a1a319e75..1c21435cfbd 100644 --- a/rules/S960/cfamily/rule.adoc +++ b/rules/S960/cfamily/rule.adoc @@ -39,7 +39,7 @@ void func(void) { * MISRA {cpp}:2008, 16-0-4 - Function-like macros shall not be defined. * MISRA C:2012, Dir. 4.9 - A function should be used in preference to a function-like macro where they are interchangeable * https://wiki.sei.cmu.edu/confluence/x/INcxBQ[CERT, PRE00-C.] - Prefer inline or static functions to function-like macros -* https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#es31-dont-use-macros-for-constants-or-functions[{cpp} Core Guidelines ES.31] - Don't use macros for constants or "functions" +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#es31-dont-use-macros-for-constants-or-functions[ES.31: Don't use macros for constants or "functions"] ifdef::env-github,rspecator-view[] diff --git a/shared_content/cfamily/exception_in_destructor.adoc b/shared_content/cfamily/exception_in_destructor.adoc index e5d6eea6050..b86002f417c 100644 --- a/shared_content/cfamily/exception_in_destructor.adoc +++ b/shared_content/cfamily/exception_in_destructor.adoc @@ -36,8 +36,8 @@ include::{docdir}/documentation.adoc[] === External coding guidelines -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c36-a-destructor-may-not-fail[C.36 A destructor may not fail] -* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/036324/CppCoreGuidelines.md#c37-make-destructors-noexcept[C.37 Make destructors noexcept] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c36-a-destructor-must-not-fail[C.36: A destructor must not fail] +* {cpp} Core Guidelines - https://github.com/isocpp/CppCoreGuidelines/blob/e49158a/CppCoreGuidelines.md#c37-make-destructors-noexcept[C.37: Make destructors `noexcept`] * MISRA {cpp}:2008, 15-5-1 - A class destructor shall not exit with an exception. === Related rules