diff --git a/annotations/yo/classtemplates/explicit.yo b/annotations/yo/classtemplates/explicit.yo index 33b38ddb..51ee2b2b 100644 --- a/annotations/yo/classtemplates/explicit.yo +++ b/annotations/yo/classtemplates/explicit.yo @@ -47,8 +47,9 @@ tt(int) template argument. This fails: ) When attempting to instantiate a tt(Class) object by passing it tt(Class::Iterators) the compiler cannot directly deduce from the provided -arguments that a tt(Class is to be used: tt(type) isn't -directly available. Compare this to tt(Class's) second constructor, where +arguments that a tt(Class) is to be used: tt(type) +isn't directly available. Compare this to tt(Class's) second constructor, +where verb( Class intObject{12}; ) @@ -78,8 +79,8 @@ which are defined as em(explicitly specified) emi(deduction rules) that are added to (beyond) the class's interface. An explicitly specified deduction rule relates a class template constructor -signature to a class template type (providing the template arguments for the -class template object that is constructed using the constructor whose +signature to a class template type. It specifies the template arguments for +the class template object that is constructed using the constructor whose signature is specified. The generic syntactical form of an explicitly specified deduction rule looks like this: verb( @@ -97,7 +98,7 @@ a resulting class type: Class ) Now combine both in an explicitly specified deduction rule (which is added -as a separately line following tt(Class's) interface: +as a separately line following tt(Class's) interface): verb( template Class(Iter begin, Iter end) -> Class diff --git a/annotations/yo/concrete/examples/binopclasses.cc b/annotations/yo/concrete/examples/binopclasses.cc index eacffa29..a620d6dd 100644 --- a/annotations/yo/concrete/examples/binopclasses.cc +++ b/annotations/yo/concrete/examples/binopclasses.cc @@ -3,7 +3,7 @@ // operator@= (for demonstration purposes) // // Binops is the class befriending the arithmetic operation classes -// Derived is the class that's derived from Binops. Derived wants to offer + +// Derived is the class that's derived from Binops. Derived wants to offer + // and - operators. It does so by deriving from Binops // // The design is based on the CRTP, stepping over several classes diff --git a/annotations/yo/first/selectinit.yo b/annotations/yo/first/selectinit.yo index 17e68764..528b1fac 100644 --- a/annotations/yo/first/selectinit.yo +++ b/annotations/yo/first/selectinit.yo @@ -66,7 +66,7 @@ commands may then be processed like this: ) Note that a variable may still be defined in the actual condition clauses. This is true for both the extended tt(if) and tt(switch) statement. But before -the condition clauses an initialization clause may be used to define +using the condition clauses an initialization clause may be used to define additional variables (plural, as it may contain a comma-separated list of variables, similar to the syntax that's available for -tt(for)-statements. +tt(for)-statements). diff --git a/annotations/yo/generic/examples/exchange.cc b/annotations/yo/generic/examples/exchange.cc index b779955c..d538c1ae 100644 --- a/annotations/yo/generic/examples/exchange.cc +++ b/annotations/yo/generic/examples/exchange.cc @@ -5,8 +5,8 @@ int main(int argc, char **argv) { bool more = argc > 5; - - cout << "more than 5: " << exchange(more, argc > 2) << + + cout << "more than 5: " << exchange(more, argc > 2) << ", more than 2: " << more << '\n'; } /* diff --git a/annotations/yo/stl/examples/lambdaconstexpr.cc b/annotations/yo/stl/examples/lambdaconstexpr.cc index 650b738d..8d893e46 100644 --- a/annotations/yo/stl/examples/lambdaconstexpr.cc +++ b/annotations/yo/stl/examples/lambdaconstexpr.cc @@ -16,10 +16,10 @@ int constexpr (*fp)(int) = add2; static_assert(fp(3) == add2(3), ""); -auto monoid = [](auto v) +auto monoid = [](auto v) { - return [=] - { return v; + return [=] + { return v; }; }; @@ -56,4 +56,3 @@ int main() fun<4>(); } //= -