Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(130)

Unified Diff: styleguide/c++/c++11.html

Issue 1892473003: C++11 doc cleanup (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: styleguide/c++/c++11.html
diff --git a/styleguide/c++/c++11.html b/styleguide/c++/c++11.html
index 1dba165762f1fd284e54ea45e8419e4854960c6f..93df6af49d4b2dda7579bd47f745c3d06f59e945 100644
--- a/styleguide/c++/c++11.html
+++ b/styleguide/c++/c++11.html
@@ -33,7 +33,7 @@ more restrictive if they need to compile on more toolchains than Chromium.</p>
feature by sending an email to <a
href="https://groups.google.com/a/chromium.org/forum/#!forum/cxx">cxx@chromium.org</a>.
Ideally include a short blurb on what the feature is, and why you think it
-should or should not be allowed. Ideally, the list will arrive at some
+should or should not be allowed. Ideally, the list will arrive at some
consensus and the wiki page will be updated to mention that consensus. If
there's no consensus, <code>src/styleguide/c++/OWNERS</code> get to decide --
for divisive features, we expect the decision to be to not use the feature yet
@@ -81,11 +81,9 @@ with the language.</p>
<tr>
<td>Angle Bracket Parsing in Templates</td>
-<td><code>&gt;&gt;</code> for <code>&gt; &gt;</code> and <br />
-<code>&lt;::</code> for <code>&lt; ::</code></td>
+<td><code>&gt;&gt;</code> for <code>&gt; &gt;</code>, <code>&lt;::</code> for <code>&lt; ::</code></td>
<td>More intuitive parsing of template parameters</td>
-<td><a href="http://stackoverflow.com/questions/15785496/c-templates-angle-brackets-pitfall-what-is-the-c11-fix">
-C++ Templates Angle Brackets Pitfall</a></td>
+<td><a href="http://stackoverflow.com/questions/15785496/c-templates-angle-brackets-pitfall-what-is-the-c11-fix">C++ Templates Angle Brackets Pitfall</a></td>
<td>Recommended to increase readability. Approved without discussion.</td>
</tr>
@@ -93,8 +91,7 @@ C++ Templates Angle Brackets Pitfall</a></td>
<td>Arrays</td>
<td><code>std::array</code></td>
<td>A fixed-size replacement for built-in arrays, with STL support</td>
-<td><a href="http://en.cppreference.com/w/cpp/container/array">
-std::array</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/container/array">std::array</a></td>
<td>Useful in performance-critical situations, with small, fixed-size arrays. In most cases, consider std::vector instead. std::vector is cheaper to std::move and is more widely used. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/pVRQCRWHEU8">Discussion thread</a>.</td>
</tr>
@@ -102,11 +99,8 @@ std::array</a></td>
<td>Automatic Types</td>
<td><code>auto</code></td>
<td>Automatic type deduction</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/auto">
-auto specifier</a></td>
-<td>Use according to the <a
-href="https://google.github.io/styleguide/cppguide.html#auto">Google
-Style Guide on <code>auto</code></a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/OQyYSfH9m2M">Discussion thread</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/5-Bt3BJzAo0">Another discussion thread</a>.</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/auto">auto specifier</a></td>
+<td><a href="https://google.github.io/styleguide/cppguide.html#auto">Google Style Guide</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/OQyYSfH9m2M">Discussion thread</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/5-Bt3BJzAo0">Another discussion thread</a>.</td>
</tr>
<tr>
@@ -120,75 +114,52 @@ Style Guide on <code>auto</code></a>. <a href="https://groups.google.com/a/chrom
<tr>
<td>Declared Type Accessor</td>
<td><code>decltype(<i>expression</i>)</code></td>
-<td>Provides a means to determine the type of an expression at compile-time,
-useful most often in templates.</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/decltype">
-decltype specifier</a></td>
+<td>Provides a means to determine the type of an expression at compile-time, useful most often in templates.</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/decltype">decltype specifier</a></td>
<td>Usage should be rare. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/_zoNvZd_dSo">Discussion thread</a></td>
</tr>
<tr>
-<td>Declared Type As Value</td>
-<td><code>declval(<i>expression</i>)</code></td>
-<td>Converts a type to a reference of the type to allow use of members of
-the type without constructing it in templates.</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/declval">
-decltype specifier</a></td>
-<td>Usage should be rare. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/ku6lYjk0-OU/discussion">Discussion thread</a></td>
-</tr>
-
-<tr>
<td>Default Function Creation</td>
<td><code><i>Function</i>(<i>arguments</i>) = default;</code></td>
-<td>Instructs the compiler to generate a default version
-of the indicated function</td>
-<td><a href="http://stackoverflow.com/questions/823935/whats-the-point-in-defaulting-functions-in-c11">
-What's the point in defaulting functions in C++11?</a></td>
-<td>Doesn't work for move constructors and move assignment operators in MSVC2013.
-<a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/qgU4mh_MpGA">Discussion thread</a></td>
+<td>Instructs the compiler to generate a default version of the indicated function</td>
+<td><a href="http://stackoverflow.com/questions/823935/whats-the-point-in-defaulting-functions-in-c11">What's the point in defaulting functions in C++11?</a></td>
+<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/qgU4mh_MpGA">Discussion thread</a></td>
</tr>
<tr>
<td>Default Function Template Arguments</td>
-<td><code>template &lt;typename T = <i>type</i>&gt; <br />
-&nbsp;&nbsp;<i>type</i> <i>Function</i>(T <i>var</i>) {}</code></td>
+<td><code>template &lt;typename T = <i>type</i>&gt;<br />
+<i>type</i> <i>Function</i>(T <i>var</i>) {}</code></td>
<td>Allow function templates, like classes, to have default arguments</td>
-<td><a href="http://stackoverflow.com/questions/2447458/default-template-arguments-for-function-templates">
-Default Template Arguments for Function Templates</a></td>
+<td><a href="http://stackoverflow.com/questions/2447458/default-template-arguments-for-function-templates">Default Template Arguments for Function Templates</a></td>
<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/9KtaAsome-o">Discussion thread</a></td>
</tr>
<tr>
<td>Delegated Constructors</td>
-<td><code>Class() : Class(0) {}</code><br />
-<code>Class(<i>type</i> <i>var</i>) : Class(<i>var</i>, 0)</code></td>
+<td><code>Class() : Class(0) {}<br />
+Class(<i>type</i> <i>var</i>) : Class(<i>var</i>, 0) {}</code></td>
<td>Allow overloaded constructors to use common initialization code</td>
-<td><a href="https://www.ibm.com/developerworks/community/blogs/5894415f-be62-4bc0-81c5-3956e82276f3/entry/introduction_to_the_c_11_feature_delegating_constructors?lang=en">
-Introduction to the C++11 feature: delegating constructors</a></td>
+<td><a href="https://www.ibm.com/developerworks/community/blogs/5894415f-be62-4bc0-81c5-3956e82276f3/entry/introduction_to_the_c_11_feature_delegating_constructors?lang=en">Introduction to the C++11 feature: delegating constructors</a></td>
<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/0zVA8Ctx3Xo">Discussion thread</a></td>
</tr>
<tr>
<td>Enumerated Type Classes and Enum Bases</td>
-<td><code>enum class <i>classname</i></code><br>
- <code>enum class <i>classname</i> : <i>base-type</i></code><br>
- <code>enum <i>enumname</i> : <i>base-type</i></code></td>
-<td>Provide enums as full classes, with no implicit
-conversion to booleans or integers. Provide an explicit underlying type for
-enum classes and regular enums.</td>
+<td><code>enum class <i>classname</i><br />
+enum class <i>classname</i> : <i>base-type</i><br />
+enum <i>enumname</i> : <i>base-type</i></code></td>
+<td>Provide enums as full classes, with no implicit conversion to booleans or integers. Provide an explicit underlying type for enum classes and regular enums.</td>
<td><a href="http://www.stroustrup.com/C++11FAQ.html#enum">enum-class</a></td>
-<td>Enum classes are still enums and follow enum naming rules
-(which means SHOUTY_CASE in the <a href="http://www.chromium.org/developers/coding-style#Naming">current style guide</a>).
-<a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/Q5WmkAImanc">Discussion thread</a></td>
+<td>Enum classes are still enums and follow enum naming rules (which means SHOUTY_CASE in the <a href="http://www.chromium.org/developers/coding-style#Naming">Chromium Style Guide</a>). <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/Q5WmkAImanc">Discussion thread</a></td>
</tr>
<tr>
<td>Explicit Conversion Operators</td>
-<td><code>explicit operator <i>type</i>() {
-<br />&nbsp;&nbsp;// code<br /> }</code></td>
+<td><code>explicit operator <i>type</i>() { ... }</code></td>
<td>Allows conversion operators that cannot be implicitly invoked</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/explicit">
-explicit specifier</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/explicit">explicit specifier</a></td>
<td>Prefer to the "safe bool" idiom. <a href="https://groups.google.com/a/chromium.org/d/msg/chromium-dev/zGF1SrQ-1HQ/BAiC12vwPeEJ">Discussion thread</a></td>
</tr>
@@ -197,14 +168,13 @@ explicit specifier</a></td>
<td><code>final</code></td>
<td> Indicates that a class or function is final and cannot be overridden</td>
<td><a href="http://en.cppreference.com/w/cpp/language/final">final Language Reference</a></td>
-<td>Recommended for new code. Existing uses of the <code>FINAL</code> macro will be <a href="https://crbug.com/417463">replaced throughout the codebase</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/VTNZzizN0zo">Discussion thread</a></td>
+<td>Recommended for new code. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/VTNZzizN0zo">Discussion thread</a></td>
</tr>
<tr>
<td>Function Suppression</td>
<td><code><i>Function</i>(<i>arguments</i>) = delete;</code></td>
-<td>Suppresses the implementation of a function, especially a
-synthetic function such as a copy constructor</td>
+<td>Suppresses the implementation of a function, especially a synthetic function such as a copy constructor</td>
<td>TODO: documentation link</td>
<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/i1o7-RNRnMs">Discussion thread</a></td>
</tr>
@@ -214,54 +184,33 @@ synthetic function such as a copy constructor</td>
<td><code>[<i>captures</i>](<i>params</i>) -&gt; <i>ret</i> { <i>body</i> }</code></td>
<td>Anonymous functions</td>
<td><a href="http://en.cppreference.com/w/cpp/language/lambda">Lambda functions</a></td>
-<td>Do not bind or store lambdas; use <code>base::Bind</code> and
-<code>base::Callback</code> instead, because they offer protection against a
-large class of object lifetime mistakes. Don't use default captures
-(<code>[=]</code>, <code>[&amp;]</code> &ndash; <a
- href="https://google.github.io/styleguide/cppguide.html#Lambda_expressions">Google Style Guide</a>).
-Lambdas are typically useful as a parameter to methods or
-functions that will use them immediately, such as those in
-<code>&lt;algorithm&gt;</code>. <a
- href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/D9UnnxBnciQ">Discussion
- thread</a></td>
+<td>Do not bind or store lambdas; use <code>base::Bind</code> and <code>base::Callback</code> instead, because they offer protection against a large class of object lifetime mistakes. Don't use default captures (<code>[=]</code>, <code>[&amp;]</code> &ndash; <a href="https://google.github.io/styleguide/cppguide.html#Lambda_expressions">Google Style Guide</a>). Lambdas are typically useful as a parameter to methods or functions that will use them immediately, such as those in <code>&lt;algorithm&gt;</code>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/D9UnnxBnciQ">Discussion thread</a></td>
</tr>
<tr>
<td>Local Types as Template Arguments</td>
<td></td>
<td>Allows local and unnamed types as template arguments</td>
-<td><a href="http://stackoverflow.com/questions/742607/using-local-classes-with-stl-algorithms">
-Local types, types without linkage and unnamed types as template arguments</a></td>
+<td><a href="http://stackoverflow.com/questions/742607/using-local-classes-with-stl-algorithms">Local types, types without linkage and unnamed types as template arguments</a></td>
<td>Usage should be rare. Approved without discussion.</td>
</tr>
<tr>
<td>Non-Static Class Member Initializers</td>
-<td>
-<code>
-class C {<br />
- <i>type</i> <i>var</i> = <i>value</i>;<br/>
- C() // copy-initializes <i>var</i><br/>
-</code>
+<td><code>class C {<br />
+&nbsp;&nbsp;<i>type</i> <i>var</i> = <i>value</i>;<br />
+&nbsp;&nbsp;C()&nbsp;&nbsp;// copy-initializes <i>var</i></code>
<td>Allows non-static class members to be initialized at their definitions (outside constructors)</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/data_members">
-Non-static data members</a></td>
-<td>
-<a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/zqB-DySA4V0">Discussion thread</a>
-</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/data_members">Non-static data members</a></td>
+<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/zqB-DySA4V0">Discussion thread</a></td>
</tr>
<tr>
<td>Null Pointer Constant</td>
<td><code>nullptr</code></td>
<td>Declares a type-safe null pointer</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/nullptr">
-nullptr</a></td>
-<td>Recommended for new code.
-<a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/4mijeJHzxLg">Discussion thread</a>.
-<a href="https://google.github.io/styleguide/cppguide.html#0_and_nullptr/NULL">Google Style Guide</a>.
-<code>std::nullptr_t</code> can be used too.
-</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/nullptr">nullptr</a></td>
+<td>Prefer over <code>NULL</code> or <code>0</code>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/4mijeJHzxLg">Discussion thread</a>. <a href="https://google.github.io/styleguide/cppguide.html#0_and_nullptr/NULL">Google Style Guide</a>. <code>std::nullptr_t</code> can be used too.</td>
</tr>
<tr>
@@ -269,44 +218,31 @@ nullptr</a></td>
<td><code>override</code></td>
<td>Indicates that a class or function overrides a base implementation</td>
<td><a href="http://en.cppreference.com/w/cpp/language/override">override Language Reference</a></td>
-<td>Recommended for new code. Existing uses of the <code>OVERRIDE</code> macro will be <a href="https://crbug.com/417463">replaced throughout the codebase</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/VTNZzizN0zo">Discussion</a></td>
+<td>Recommended for new code. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/VTNZzizN0zo">Discussion thread</a></td>
</tr>
<tr>
<td>Range-Based For Loops</td>
<td><code>for (<i>type</i> <i>var</i> : <i>range</i>)</code></td>
-<td>Facilitates a more concise syntax for iterating over the elements
-of a container (or a range of iterators) in a <code>for</code> loop</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/range-for">
-Range-based for loop</a></td>
+<td>Facilitates a more concise syntax for iterating over the elements of a container (or a range of iterators) in a <code>for</code> loop</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/range-for">Range-based for loop</a></td>
<td>As a rule of thumb, use <code>for (const auto& ...)</code>, <code>for (auto& ...)</code>, or <code>for (<i>concrete type</i> ...)</code>. For pointers, use <code>for (auto* ...)</code> to make clear that the copy of the loop variable is intended, and only a pointer is copied. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/hpzz4EqbVmc">Discussion thread</a></td>
</tr>
<tr>
<td>Rvalue References</td>
-<td><code>T(T&amp;&amp; t)</code> and <code>T&amp; operator=(T&amp;&amp; t)</code><br/><br/>
- <code>template &lt;typename T&gt;<br/>void Function(T&& t) { ... }</code></td>
+<td><code>T(T&amp;&amp; t)</code> and <code>T&amp; operator=(T&amp;&amp; t)<br/><br/>
+template &lt;typename T&gt;<br/>void Function(T&& t) { ... }</code></td>
<td>Reference that only binds to a temporary object</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/references#Rvalue_references">
-Rvalue references</a></td>
-<td>As per the <a href="https://google.github.io/styleguide/cppguide.html#Rvalue_references">Google style guide</a>: Only use these to define move constructors and move assignment operators, and for perfect forwarding.<br/>Most classes should not be copyable, even if movable. Continue to use DISALLOW_COPY_AND_ASSIGN (or DISALLOW_COPY_AND_ASSIGN_WITH_MOVE_FOR_BIND if needed) in most cases. <a href="https://groups.google.com/a/chromium.org/d/topic/chromium-dev/UnRaORb4TSw">Discussion thread</a> and <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/Q526tkruXpM">discussion thread</a>.
-<br/><br/>
-MSVC 2013 has some known bugs with rvalue references:
-<ul>
-<li>Exported classes generate copy constructors even if they are not used, which tries to use copy constructors on members. Use DISALLOW_COPY_AND_ASSIGN on the exported class to resolve it.</li>
-<li>The compiler chooses a T::(T&) constructor before T::(T&&). However copy constructors should be written as T::T(const T&) and these are prioritized correctly.</li>
-<li>The compiler does not create default move constructors, either implicitly or with the =default keyword. You must provide such constructors explicitly to create them.</li>
-</ul>
-</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/references#Rvalue_references">Rvalue references</a></td>
+<td>As per the <a href="https://google.github.io/styleguide/cppguide.html#Rvalue_references">Google Style Guide</a>: Only use these to define move constructors and move assignment operators, and for perfect forwarding. Most classes should not be copyable, even if movable. Continue to use DISALLOW_COPY_AND_ASSIGN (or DISALLOW_COPY_AND_ASSIGN_WITH_MOVE_FOR_BIND if needed) in most cases. <a href="https://groups.google.com/a/chromium.org/d/topic/chromium-dev/UnRaORb4TSw">Discussion thread</a>. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/Q526tkruXpM">Another discussion thread</a>.</td>
</tr>
<tr>
<td>Standard Integers</td>
-<td>Typedefs within <code>&lt;stdint.h&gt;</code>
-and <code>&lt;inttypes&gt;</code></td>
+<td>Typedefs within <code>&lt;stdint.h&gt;</code> and <code>&lt;inttypes&gt;</code></td>
<td>Provides fixed-size integers independent of platforms</td>
-<td><a href="http://www.cplusplus.com/reference/cstdint/">
-&lt;stdint.h&gt; (cstdint)</a></td>
+<td><a href="http://www.cplusplus.com/reference/cstdint/">&lt;stdint.h&gt; (cstdint)</a></td>
<td>Already in common use in the codebase. Approved without discussion.</td>
</tr>
@@ -322,8 +258,7 @@ and <code>&lt;inttypes&gt;</code></td>
<td>Variadic Macros</td>
<td><code>#define <i>MACRO</i>(...) <i>Impl</i>(<i>args</i>, __VA_ARGS__)</code></td>
<td>Allows macros that accept a variable number of arguments</td>
-<td><a href="http://stackoverflow.com/questions/4786649/are-variadic-macros-nonstandard">
-Are Variadic macros nonstandard?</a></td>
+<td><a href="http://stackoverflow.com/questions/4786649/are-variadic-macros-nonstandard">Are Variadic macros nonstandard?</a></td>
<td>Usage should be rare. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/sRx9j3CQqyA">Discussion thread</a></td>
</tr>
@@ -331,8 +266,7 @@ Are Variadic macros nonstandard?</a></td>
<td>Variadic Templates</td>
<td><code>template &lt;<i>typename</i> ... <i>arg</i>&gt;</code></td>
<td>Allows templates that accept a variable number of arguments</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/parameter_pack">
-Parameter pack</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/parameter_pack">Parameter pack</a></td>
<td>Usage should be rare. Use instead of .pump files. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/6ItymeMXpMc">Discussion thread</a></td>
</tr>
@@ -374,37 +308,34 @@ Parameter pack</a></td>
<code>is_sorted</code>, <code>is_sorted_until</code><br/>
<code>is_heap</code>, <code>is_heap_until</code><br/>
<code>minmax</code>, <code>minmax_element</code><br/>
-<code>is_permutation<br/>
-</td>
+<code>is_permutation<br/></td>
<td>Safe and performant implementations of common algorithms</td>
<td><a href="http://en.cppreference.com/w/cpp/header/algorithm"><code>&lt;algorithm&gt;</code></a></td>
-<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/UJQk8S1IuHk">Discussion thread</a><br/>
-Note that &lt;algorithm&gt; contains a range-based <code>move</code> method. This is allowed, but because people may confuse it with the single-arg <code>std::move</code>, there is often a way to write code without it that is more readable. <a href='https://groups.google.com/a/chromium.org/forum/#!topic/cxx/8WzmtYrZvQ8'>Discussion thread</a></td>
+<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/UJQk8S1IuHk">Discussion thread</a><br/> Note that &lt;algorithm&gt; contains a range-based <code>move</code> method. This is allowed, but because people may confuse it with the single-arg <code>std::move</code>, there is often a way to write code without it that is more readable. <a href='https://groups.google.com/a/chromium.org/forum/#!topic/cxx/8WzmtYrZvQ8'>Discussion thread</a></td>
</tr>
<tr>
<td>Begin and End Non-Member Functions</td>
-<td><code>std::begin()</code> and <code>std::end()</code></td>
+<td><code>std::begin()</code>, <code>std::end()</code></td>
<td>Allows use of free functions on any container, including fixed-size arrays</td>
-<td><a href="http://en.cppreference.com/w/cpp/iterator/begin">std::begin</a> and <a href="http://en.cppreference.com/w/cpp/iterator/end">std::end</a></td>
-<td>Useful for fixed-size arrays. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/5iFNE8P5qT4/discussion">Discussion thread</a><br>
-Note that non-member <code>cbegin()</code> and <code>cend()</code> are not available until C++14.</td>
+<td><a href="http://en.cppreference.com/w/cpp/iterator/begin">std::begin</a>, <a href="http://en.cppreference.com/w/cpp/iterator/end">std::end</a></td>
+<td>Useful for fixed-size arrays. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/5iFNE8P5qT4/discussion">Discussion thread</a><br> Note that non-member <code>cbegin()</code> and <code>cend()</code> are not available until C++14.</td>
danakj 2016/04/14 21:22:25 <br/>? Line breaking after a br makes sense in th
Peter Kasting 2016/04/14 21:32:43 I'll reword this a bit to put the "Discussion thre
</tr>
<tr>
<td>Conditional Type Selection</td>
-<td><code>std::enable_if</code> and <code>std::conditional</code></td>
+<td><code>std::enable_if</code>, <code>std::conditional</code></td>
<td>Enables compile-time conditional type selection</td>
-<td><a href="http://en.cppreference.com/w/cpp/types/enable_if">std::enable_if</a> and <a href="http://en.cppreference.com/w/cpp/types/conditional">conditional</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/types/enable_if">std::enable_if</a>, <a href="http://en.cppreference.com/w/cpp/types/conditional">conditional</a></td>
<td>Usage should be rare. <a href='https://groups.google.com/a/chromium.org/forum/#!topic/cxx/vCxo4tZNd_M'>Discussion thread</a></td>
</tr>
<tr>
<td>Constant Iterator Methods on Containers</td>
-<td><code>std::vector::cbegin()</code>, <code>std::vector::cend()</code></td>
+<td>E.g. <code>std::vector::cbegin()</code>, <code>std::vector::cend()</code></td>
<td>Allows more widespread use of <code>const_iterator</code></td>
-<td>E.g. <a href="http://en.cppreference.com/w/cpp/container/vector/begin">std::vector::cbegin<a> and <a href="http://en.cppreference.com/w/cpp/container/vector/end">std::vector::cend<a></td>
-<td>Applies to all containers, not just <code>vector</code>. Consider using <code>const_iterator</code> over <code>iterator</code> where possible for the same reason as using <code>const</code> variables and functions where possible; see Effective Modern C++ item 13 for motivation. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/cS83F_buqLM/discussion">Discussion thread</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/container/vector/begin">std::vector::cbegin</a>, <a href="http://en.cppreference.com/w/cpp/container/vector/end">std::vector::cend<a></td>
+<td>Applies to all containers, not just <code>vector</code>. Consider using <code>const_iterator</code> over <code>iterator</code> where possible for the same reason as using <code>const</code> variables and functions where possible; see Effective Modern C++ item 13 for motivation. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/cS83F_buqLM/discussion">Discussion thread</a></td>
</tr>
<tr>
@@ -412,15 +343,23 @@ Note that non-member <code>cbegin()</code> and <code>cend()</code> are not avail
<td><code>vector&lt;scoped_ptr&gt;</code></td>
<td>Enables containers that contain move-only types like <code>scoped_ptr</code></td>
<td>TODO</td>
-<td>Allows getting rid of <a href="http://crbug.com/554289">ScopedVector</a></td>
+<td>Prefer over <a href="http://crbug.com/554289">ScopedVector</a>.</td>
</tr>
+<tr>
+<td>Declared Type As Value</td>
+<td><code>std::declval&lt;<i>class</i>&gt;()</code></td>
+<td>Converts a type to a reference of the type to allow use of members of the type without constructing it in templates.</td>
+<td><a href="http://en.cppreference.com/w/cpp/utility/declval">std::declval</a></td>
+<td>Usage should be rare. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/ku6lYjk0-OU/discussion">Discussion thread</a></td>
+</tr>
+
<tr>
<td>Emplacement methods for containers</td>
<td><code>emplace()</code>, <code>emplace_back()</code>, <code>emplace_front()</code>, <code>emplace_hint()</code></td>
-<td>Constructs elements directly within a container without a copy or a move. Less verbose than <code>push_back()</code> due to not naming the type being constructed.</td>
+<td>Constructs elements directly within a container without a copy or a move. Less verbose than <code>push_back()</code> due to not naming the type being constructed.</td>
<td>E.g. <a href="http://en.cppreference.com/w/cpp/container/vector/emplace_back">std::vector::emplace_back</a></td>
-<td><code>std::map::emplace()</code> is not yet available on all libstdc++ versions we support. When using emplacement for performance reasons, your type should probably be movable (since e.g. a vector of it might be resized); given a movable type, then, consider whether you really need to avoid the move done by <code>push_back()</code>. For readability concerns, treat like <code>auto</code>; sometimes the brevity over <code>push_back()</code> is a win, sometimes a loss. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/m3cblzEta7A">Discussion thread</a></td>
+<td><code>std::map::emplace()</code> is not yet available on all libstdc++ versions we support. When using emplacement for performance reasons, your type should probably be movable (since e.g. a vector of it might be resized); given a movable type, then, consider whether you really need to avoid the move done by <code>push_back()</code>. For readability concerns, treat like <code>auto</code>; sometimes the brevity over <code>push_back()</code> is a win, sometimes a loss. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/m3cblzEta7A">Discussion thread</a></td>
</tr>
<tr>
@@ -428,9 +367,7 @@ Note that non-member <code>cbegin()</code> and <code>cend()</code> are not avail
<td><code>std::forward()</code></td>
<td>Perfectly forwards arguments (including rvalues)</td>
<td><a href="http://en.cppreference.com/w/cpp/utility/forward"><code>std::forward</code></a></td>
-<td>
- Allowed, though usage should be rare (primarily for forwarding constructor arguments, or in carefully reviewed library code).
- <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/-O7euklhSxs/discussion">Discussion thread</a>
+<td>Allowed, though usage should be rare (primarily for forwarding constructor arguments, or in carefully reviewed library code). <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/-O7euklhSxs/discussion">Discussion thread</a>
</td>
</tr>
@@ -439,7 +376,7 @@ Note that non-member <code>cbegin()</code> and <code>cend()</code> are not avail
<td><code>tie(a, b, c) &lt;<br>&nbsp; tie(rhs.a, rhs.b, rhs.c)</code></td>
<td>Idiom for <code>operator&lt;</code> implementation</td>
<td><a href="http://en.cppreference.com/w/cpp/utility/tuple/tie">std::tie</a></td>
-<td>General use of <code>std::tuple</code>, and <code>std::tie</code> for unpacking or multiple assignments is still not allowed. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/3DZ64dIMRTY/discussion">Discussion thread</a></td>
+<td>General use of <code>std::tie</code> for unpacking or multiple assignments is still not allowed. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/3DZ64dIMRTY/discussion">Discussion thread</a></td>
</tr>
<tr>
@@ -472,12 +409,9 @@ Note that non-member <code>cbegin()</code> and <code>cend()</code> are not avail
<tr>
<td>String Direct Reference Functions</td>
-<td><code>std::string::front()</code> and <code>std::string::back()</code></td>
+<td><code>std::string::front()</code>, <code>std::string::back()</code></td>
<td>Returns a reference to the front or back of a string</td>
-<td><a href="http://en.cppreference.com/w/cpp/string/basic_string/front">
-std::basic_string::front</a> and
-<a href="http://en.cppreference.com/w/cpp/string/basic_string/back">
-std::basic_string::back</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/string/basic_string/front">std::basic_string::front</a>, <a href="http://en.cppreference.com/w/cpp/string/basic_string/back">std::basic_string::back</a></td>
<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/DRJuROAYCV4">Discussion thread</a></td>
</tr>
@@ -488,11 +422,10 @@ std::basic_string::back</a></td>
<code>is_floating_point</code>, <code>is_rvalue_reference</code>, <code>is_scalar</code><br/>
<code>is_const</code>, <code>is_pod</code>, <code>is_unsigned</code><br/>
<code>is_default_constructible</code>, <code>is_move_constructible</code>, <code>is_copy_assignable</code><br/>
-<code>enable_if</code>, <code>conditional</code>, <code>result_of</code><br/>
-</td>
+<code>enable_if</code>, <code>conditional</code>, <code>result_of</code><br/></td>
<td>Allows compile-time inspection of the properties of types</td>
<td><a href="http://en.cppreference.com/w/cpp/header/type_traits">&lt;type_traits&gt;</a></td>
-<td>Note that not all type traits are available on all platforms (eg std::underlying_type doesn't work in libstdc++4.6). Use judiciously. <a href='https://groups.google.com/a/chromium.org/forum/#!topic/cxx/vCxo4tZNd_M'>Discussion thread</a></td>
+<td>Note that not all type traits are available on all platforms (e.g. <code>std::underlying_type</code> doesn't work in libstdc++4.6). Use judiciously. <a href='https://groups.google.com/a/chromium.org/forum/#!topic/cxx/vCxo4tZNd_M'>Discussion thread</a></td>
</tr>
<tr>
@@ -500,20 +433,15 @@ std::basic_string::back</a></td>
<td><code>std::tuple</code></td>
<td>A fixed-size ordered collection of values of mixed types</td>
<td><a href="http://en.cppreference.com/w/cpp/utility/tuple">std::tuple</a></td>
-<td><a href="https://crbug.com/554987">Tracking bug</a> to plan moving from <code>base::Tuple</code> to <code>std::tuple</code>. See also <code>std::tie</code>.
-<code>base::Tuple</code> is now an alias for <code>std::tuple</code>. In class template specializations, use <code>std::tuple</code> instead of <code>base::Tuple</code> to work around a MSVS2013 internal compiler error (Error code: C1001).
-</td>
+<td><a href="https://crbug.com/554987">Tracking bug</a> to plan moving from <code>base::Tuple</code> to <code>std::tuple</code>. See also <code>std::tie</code>. <code>base::Tuple</code> is now an alias for <code>std::tuple</code>.</td>
danakj 2016/04/14 21:22:25 You could just say "Prefer over base::Tuple" and l
Peter Kasting 2016/04/14 21:32:43 Good idea.
</tr>
<tr>
<td>Unordered Associative Containers</td>
-<td><code>std::unordered_set</code>, <code>std::unordered_map</code>,
-<code>std::unordered_multiset</code>, and <code>std::unordered_multimap</code></td>
+<td><code>std::unordered_set</code>, <code>std::unordered_map</code>, <code>std::unordered_multiset</code>, <code>std::unordered_multimap</code></td>
<td>Allows efficient containers of key/value pairs</td>
-<td><a href="http://en.cppreference.com/w/cpp/container/unordered_map">std::unordered_map</a>
-and <a href="http://en.cppreference.com/w/cpp/container/unordered_set">std::unordered_set</a>
-</td>
-<td>Per the <a href="https://google.github.io/styleguide/cppguide.html#std_hash">Google style guide</a>, specify custom hashers instead of specializing <code>std::hash</code> for custom types. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/nCdjQqnouO4">Discussion thread</a>.</td>
+<td><a href="http://en.cppreference.com/w/cpp/container/unordered_map">std::unordered_map</a>, <a href="http://en.cppreference.com/w/cpp/container/unordered_set">std::unordered_set</a></td>
+<td>Per the <a href="https://google.github.io/styleguide/cppguide.html#std_hash">Google Style Guide</a>, specify custom hashers instead of specializing <code>std::hash</code> for custom types. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/cxx/nCdjQqnouO4">Discussion thread</a>.</td>
</tr>
<tr>
@@ -521,7 +449,7 @@ and <a href="http://en.cppreference.com/w/cpp/container/unordered_set">std::unor
<td><code>std::unique_ptr&lt;<i>type</i>&gt;</code></td>
<td>A smart pointer with sole ownership of the owned object.</td>
<td><a href="http://en.cppreference.com/w/cpp/memory/unique_ptr">std::unique_ptr</a></td>
-<td>Google style guide: <a href="https://google.github.io/styleguide/cppguide.html#Ownership_and_Smart_Pointers">Ownership and Smart Pointers</a>. <a href="https://groups.google.com/a/chromium.org/d/msg/cxx/aT2wsBLKvzI/oZuZ718oAwAJ">Discussion thread</a>. Use in all newly written code. scoped_ptr is a <a href="https://groups.google.com/a/chromium.org/d/msg/chromium-dev/roY78iTblYc/bb8nYsxfCgAJ">typedef for std::unique_ptr</a> and is going away shortly.</td>
+<td>Use in all newly written code. <a href="https://google.github.io/styleguide/cppguide.html#Ownership_and_Smart_Pointers">Google Style Guide</a>. <a href="https://groups.google.com/a/chromium.org/d/msg/cxx/aT2wsBLKvzI/oZuZ718oAwAJ">Discussion thread</a>. <code>scoped_ptr</code> is a <a href="https://groups.google.com/a/chromium.org/d/msg/chromium-dev/roY78iTblYc/bb8nYsxfCgAJ">typedef for <code>std::unique_ptr</code></a> and is going away shortly.</td>
</tr>
</tbody>
@@ -550,106 +478,82 @@ codebase.
<tr>
<td>Alignment Features</td>
-<td>
-<code>alignas</code> specifier,
-<code>alignof</code> operator
+<td><code>alignas</code> specifier, <code>alignof</code> operator</td>
<td>Object alignment</td>
-<td>
-<a href="http://en.cppreference.com/w/cpp/language/alignas">alignas</a>,
-<a href="http://en.cppreference.com/w/cpp/language/alignof">alignof</a>
-</td>
-<td>
-<a href="https://codereview.chromium.org/1497963002/">Doesn't work in
-MSVS2013</a>.
-<a href="https://msdn.microsoft.com/en-us/library/dn956970.aspx">MSVS2015
-supports them</a>; reevaluate after MSVS2015 is available.
-<a href="https://groups.google.com/a/chromium.org/d/msg/cxx/rwXN02jzzq0/CpUc1ZzMBQAJ">Discussion thread</a>
-</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/alignas">alignas</a>, <a href="http://en.cppreference.com/w/cpp/language/alignof">alignof</a></td>
+<td>Reevaluate now that MSVS2015 is available. <a href="https://groups.google.com/a/chromium.org/d/msg/cxx/rwXN02jzzq0/CpUc1ZzMBQAJ">Discussion thread</a></td>
</tr>
<tr>
<td>Function Local Variable</td>
<td><code>__func__</code></td>
-<td>Provides a local variable of the name of the enclosing
-function for logging purposes</td>
-<td><a href="http://www.informit.com/guides/content.aspx?g=cplusplus&amp;seqNum=338">
-The __func__ Predeclared Identifier is Coming to C++</a></td>
-<td>Doesn't work in MSVS2013. Reevaluate once it does. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/ojGfcgSDzHM">Discussion thread</a></td>
+<td>Provides a local variable of the name of the enclosing function for logging purposes</td>
+<td><a href="http://www.informit.com/guides/content.aspx?g=cplusplus&amp;seqNum=338">The __func__ Predeclared Identifier is Coming to C++</a></td>
+<td>Reevaluate now that MSVS2015 is available. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/ojGfcgSDzHM">Discussion thread</a></td>
</tr>
<tr>
<td>Inherited Constructors</td>
-<td><code>class Derived : Base {
-<br />&nbsp;&nbsp;using Base::Base;
-<br />};</code></td>
+<td><code>class Derived : Base {<br />
+&nbsp;&nbsp;using Base::Base;<br />
+};</code></td>
<td>Allow derived classes to inherit constructors from base classes</td>
<td><a href="http://en.cppreference.com/w/cpp/language/using_declaration">Using-declaration</a></td>
-<td>Doesn't work in MSVS2013. Reevaluate once it does. <a
-href="https://groups.google.com/a/chromium.org/d/msg/chromium-dev/BULzgIKZ-Ao/PLO7_GoVNvYJ">Discussion thread</a></td>
+<td>Reevaluate now that MSVS2015 is available. <a href="https://groups.google.com/a/chromium.org/d/msg/chromium-dev/BULzgIKZ-Ao/PLO7_GoVNvYJ">Discussion thread</a></td>
</tr>
<tr>
<td><code>long long</code> Type</td>
<td><code>long long <i>var</i>= <i>value</i>;</code></td>
<td>An integer of at least 64 bits</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/types">
-Fundamental types</a></td>
-<td>Use an stdint.h type if you need a 64bit number. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/RxugZ-pIDxk">Discussion thread</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/types">Fundamental types</a></td>
+<td>Use a stdint.h type if you need a 64bit number. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/RxugZ-pIDxk">Discussion thread</a></td>
</tr>
<tr>
<td>Raw String Literals</td>
<td><code>string <i>var</i>=R&quot;(<i>raw_string</i>)&quot;;</code></td>
-<td>Allows a string to be encoded without any escape
-sequences, easing parsing in regex expressions, for example</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/string_literal">
-string literal</a></td>
+<td>Allows a string to be encoded without any escape sequences, easing parsing in regex expressions, for example</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/string_literal">string literal</a></td>
<td>Causes incorrect line numbers in MSVS2013 and gcc. Reevaluate once that works. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/2kWQHbbuMHI">Discussion thread</a></td>
</tr>
<tr>
<td>(Uniform) Initialization Syntax</td>
-<td><code><i>type</i> <i>name</i> { [<i>value</i> ..., <i>value</i>]};</code></td>
-<td>Allows any object of primitive, aggregate or class
-type to be initialized using brace syntax</td>
+<td><code><i>type</i> <i>name</i> {[<i>value</i> ..., <i>value</i>]};</code></td>
+<td>Allows any object of primitive, aggregate or class type to be initialized using brace syntax</td>
<td>TODO: documentation link</td>
-<td>Dangerous without library support, see thread. Reevaulate once we have C++11 library support. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/GF96FshwHLw">Discussion thread</a></td>
+<td>Reevaulate now that MSVS2015 is available. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/GF96FshwHLw">Discussion thread</a></td>
</tr>
<tr>
<td>UTF-16 and UTF-32 Support (16-Bit and 32-Bit Character Types)</td>
<td><code>char16_t</code> and <code>char32_t</code></td>
-<td>Provides character types for handling 16-bit
-and 32-bit code units (useful for encoding
-UTF-16 and UTF-32 string data)</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/types">
-Fundamental types</a></td>
-<td>Doesn't work in MSVS2013. Reevaluate once it does. Non-UTF-8 text is
-banned by the
-<a href="https://google.github.io/styleguide/cppguide.html#Non-ASCII_Characters">
-C++ Style Guide</a>. However, may be useful for
-consuming non-ASCII data. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/ME2kL7_Kvyk">Discussion thread</a></td>
+<td>Provides character types for handling 16-bit and 32-bit code units (useful for encoding UTF-16 and UTF-32 string data)</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/types">Fundamental types</a></td>
+<td>Reevaluate now that MSVS2015 is available. Non-UTF-8 text is banned by the <a href="https://google.github.io/styleguide/cppguide.html#Non-ASCII_Characters">Google Style Guide</a>. However, may be useful for consuming non-ASCII data. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/ME2kL7_Kvyk">Discussion thread</a></td>
</tr>
<tr>
<td>UTF-8, UTF-16, UTF-32 String Literals</td>
<td><code>u8&quot;<i>string</i>&quot;, u&quot;<i>string</i>&quot;, U&quot;<i>string</i>&quot;</code></td>
<td>Enforces UTF-8, UTF-16, UTF-32 encoding on all string literals</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/string_literal">
-string literal</a></td>
-<td>Does not yet work in MSVS2013. Reevaluate once it does. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/gcoUbcjfsII">Discussion thread</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/string_literal">string literal</a></td>
+<td>Reevaluate now that MSVS2015 is available. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/gcoUbcjfsII">Discussion thread</a></td>
</tr>
<tr>
<td>Ref-qualified Member Functions</td>
-<td><code>class T {<br/>&nbsp;&nbsp;void f() & {}<br/>&nbsp;&nbsp;void f() && {}<br/>};<br/>t.f(); // first<br/>T().f(); // second<br/>std::move(t).f(); // second</code></td>
+<td><code>class T {<br />
+&nbsp;&nbsp;void f() & {}<br />
+&nbsp;&nbsp;void f() && {}<br />
+};<br />
+t.f();&nbsp;&nbsp;// first<br />
+T().f();&nbsp;&nbsp;// second<br />
+std::move(t).f();&nbsp;&nbsp;// second</code></td>
<td>Allows class member functions to only bind to |this| as an rvalue or lvalue.</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/member_functions">
-Member functions</a></td>
-<td>
- Banned in the google3 C++11 library style guide. Banned in Chromium except by explicit approval from <code>styleguide/c++/OWNERS</code>.
- <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/gowclr2LPQA/discussion">Discussion Thread</a>
-</td>
+<td><a href="http://en.cppreference.com/w/cpp/language/member_functions">Member functions</a></td>
+<td>Banned in the <a href="https://google.github.io/styleguide/cppguide.html#C++11">Google Style Guide</a>. Banned in Chromium except by explicit approval from <code>styleguide/c++/OWNERS</code>. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/gowclr2LPQA/discussion">Discussion Thread</a></td>
</tr>
</tbody>
@@ -688,8 +592,8 @@ Member functions</a></td>
<tr>
<td>Thread Library</td>
-<td><code>&lt;thread&gt; support, including &lt;future&gt;,
-&lt;mutex&gt;, &lt;condition_variable&gt;</code></td>
+<td><code>&lt;thread&gt;</code> support, including<br />
+<code>&lt;future&gt;</code>, <code>&lt;mutex&gt;</code>, <code>&lt;condition_variable&gt;</code></td>
<td>Provides a standard mulitthreading library using <code>std::thread</code> and associates</td>
<td><a href="http://en.cppreference.com/w/cpp/thread">Thread support library</a></td>
<td>C++11 has all kinds of classes for threads, mutexes, etc. Since we already have good code for this in <code>base/</code>, we should keep using the base classes, at least at first. <code>base::Thread</code> is tightly coupled to <code>MessageLoop</code> which would make it hard to replace. We should investigate using standard mutexes, or unique_lock, etc. to replace our locking/synchronization classes.</td>
@@ -708,11 +612,7 @@ Member functions</a></td>
<td><code>std::shared_ptr</code></td>
<td>Allows shared ownership of a pointer through reference counts</td>
<td><a href="http://en.cppreference.com/w/cpp/memory/shared_ptr">std::shared_ptr</a></td>
-<td>
- Needs a lot more evaluation for Chromium, and there isn't enough of a push for this feature.
- <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/aT2wsBLKvzI/discussion">Discussion Thread</a>,
- <a href="https://google.github.io/styleguide/cppguide.html#Ownership_and_Smart_Pointers">Google Style Guide</a>
-</td>
+<td>Needs a lot more evaluation for Chromium, and there isn't enough of a push for this feature. <a href="https://google.github.io/styleguide/cppguide.html#Ownership_and_Smart_Pointers">Google Style Guide</a>. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/aT2wsBLKvzI/discussion">Discussion Thread</a>.</td>
</tr>
<tr>
@@ -720,10 +620,7 @@ Member functions</a></td>
<td><code>std::initializer_list&lt;T&gt;</code></td>
<td>Allows containers to be initialized with aggregate elements</td>
<td><a href="http://en.cppreference.com/w/cpp/utility/initializer_list"><code>std::initializer_list</code></a></td>
-<td>
- Banned for now; will be re-evaluated once we switch to MSVC 2015.
- <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/TQQ-L51_naM/discussion">Discussion Thread</a>
-</td>
+<td>Reevaluate now that MSVS2015 is available. <a href="https://groups.google.com/a/chromium.org/d/topic/cxx/TQQ-L51_naM/discussion">Discussion Thread</a></td>
</tr>
</tbody>
@@ -751,23 +648,17 @@ work in all our compilers yet.</p>
<tr>
<td>Attributes</td>
<td><code>[[<i>attribute_name</i>]]</code></td>
-<td>Attaches properties to declarations that
-specific compiler implementations may use.</td>
-<td><a href="http://www.codesynthesis.com/~boris/blog/2012/04/18/cxx11-generalized-attributes/">
-C++11 generalized attributes</a></td>
+<td>Attaches properties to declarations that specific compiler implementations may use.</td>
+<td><a href="http://www.codesynthesis.com/~boris/blog/2012/04/18/cxx11-generalized-attributes/">C++11 generalized attributes</a></td>
<td></td>
</tr>
<tr>
<td>Exception Features</td>
-<td><code>noexcept</code>, <code>exception_ptr</code>,
-<code>current_exception()</code>, <code>rethrow_exception</code>,
-and <code>nested_exception</code></td>
+<td><code>noexcept</code>, <code>exception_ptr</code>, <code>current_exception()</code>, <code>rethrow_exception</code>, <code>nested_exception</code></td>
<td>Enhancements to exception throwing and handling</td>
-<td><a href="http://en.cppreference.com/w/cpp/error/exception">
-std::exception</a></td>
-<td>Exceptions are banned by the
-<a href="https://google.github.io/styleguide/cppguide.html#Exceptions"> C++ Style Guide</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/8i4tMqNpHhg">Discussion thread</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/error/exception">std::exception</a></td>
+<td>Exceptions are banned by the <a href="https://google.github.io/styleguide/cppguide.html#Exceptions">Google Style Guide</a>. <a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/8i4tMqNpHhg">Discussion thread</a></td>
</tr>
<tr>
@@ -780,10 +671,9 @@ std::exception</a></td>
<tr>
<td>Union Class Members</td>
-<td><code>union <i>name</i> { <i>class</i> <i>var</i>}</code></td>
+<td><code>union <i>name</i> {<i>class</i> <i>var</i>}</code></td>
<td>Allows class type members</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/union">
-Union declarations</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/union">Union declarations</a></td>
<td></td>
</tr>
@@ -791,8 +681,7 @@ Union declarations</a></td>
<td>User-Defined Literals</td>
<td><code><i>type</i> <i>var</i> = <i>literal_value</i>_<i>type</i></code></td>
<td>Allows user-defined literal expressions</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/user_literal">
-User-defined literals</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/user_literal">User-defined literals</a></td>
<td></td>
</tr>
@@ -819,33 +708,23 @@ User-defined literals</a></td>
<td><code>std::addressof()</code></td>
<td>Obtains the address of an object even with overloaded <code>operator&amp;</code></td>
<td><a href="http://en.cppreference.com/w/cpp/memory/addressof">std::addressof</a></td>
-<td>Usage should be rare as
-<a href="https://google.github.io/styleguide/cppguide.html#Operator_Overloading">
-Operator Overloading</a> is rare and <code>&amp;</code>
-should suffice in most cases. May be preferable
-over <code>&amp;</code> for performing object
-identity checks.</td>
+<td>Usage should be rare as <a href="https://google.github.io/styleguide/cppguide.html#Operator_Overloading">operator overloading</a> is rare and <code>&amp;</code> should suffice in most cases. May be preferable over <code>&amp;</code> for performing object identity checks.</td>
</tr>
<tr>
<td>Aligned Storage</td>
-<td><code>std::aligned_storage&lt;Size, Align&gt;::type</code>
-<code>std::alignment_of&lt;T&gt;</code>,
-<code>std::aligned_union&lt;Size, ...Types&gt;</code> and
-<code>std::max_align_t</code></td>
+<td><code>std::aligned_storage&lt;Size, Align&gt;::type</code><br />
+<code>std::alignment_of&lt;T&gt;</code>, <code>std::aligned_union&lt;Size, ...Types&gt;</code> <code>std::max_align_t</code></td>
<td>Declare uninitialized storage having a specified alignment, or determine alignments.</td>
<td><a href="http://en.cppreference.com/w/cpp/types/aligned_storage">std::aligned_storage</a></td>
-<td><code>std::aligned_storage</code> and <code>std::aligned_union</code> are
-disallowed in google3 over concerns about compatibility with internal cross-compiling
-toolchains.</td>
+<td><code>std::aligned_storage</code> and <code>std::aligned_union</code> are disallowed in google3 over concerns about compatibility with internal cross-compiling toolchains.</td>
</tr>
<tr>
<td>Allocator Traits</td>
<td><code>std::allocator_traits</code></td>
<td>Provides an interface for accessing custom allocators</td>
-<td><a href="http://en.cppreference.com/w/cpp/memory/allocator_traits">
-std::allocator_traits</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/memory/allocator_traits">std::allocator_traits</a></td>
<td>Usage should be rare.</td>
</tr>
@@ -862,56 +741,39 @@ std::allocator_traits</a></td>
<td><code>&lt;cfenv&gt;</code>, <code>&lt;fenv.h&gt;</code></td>
<td>Provides floating point status flags and control modes for C-compatible code</td>
<td><a href="http://en.cppreference.com/w/cpp/header/cfenv">Standard library header &lt;cfenv&gt;</a></td>
-<td>Compilers do not support use. This is banned in google style guide over
-compilers not supporting these reliably.</td>
+<td>Banned in <a href="https://google.github.io/styleguide/cppguide.html#C++11">Google Style Guide</a> due to concerns about compiler support.</td>
</tr>
<tr>
<td>Complex Inverse Trigonometric and Hyperbolic Functions</td>
<td>Functions within <code>&lt;complex&gt;</code></td>
-<td>Adds inverse trigonomentric and hyperbolic non-member functions to
-the <code>&lt;complex&gt;</code> library.</td>
+<td>Adds inverse trigonomentric and hyperbolic non-member functions to the <code>&lt;complex&gt;</code> library.</td>
<td><a href="http://en.cppreference.com/w/cpp/numeric/complex">std::complex</a></td>
<td></td>
</tr>
<tr>
<td>Container Compaction Functions</td>
-<td><code>std::vector::shrink_to_fit()</code>,
-<code>std::deque::shrink_to_fit()</code>, and
-<code>std::string::shrink_to_fit()</code></td>
-<td>Requests the removal of unused space
-in the container</td>
-<td><a href="http://en.cppreference.com/w/cpp/container/vector/shrink_to_fit">
-std::vector::shrink_to_fit</a>,
-<a href="http://en.cppreference.com/w/cpp/container/deque/shrink_to_fit">
-std::deque::shrink_to_fit</a>, and
-<a href="http://en.cppreference.com/w/cpp/string/basic_string/shrink_to_fit">
-std::basic_string::shrink_to_fit</a></td>
+<td><code>std::vector::shrink_to_fit()</code>, <code>std::deque::shrink_to_fit()</code>, <code>std::string::shrink_to_fit()</code></td>
+<td>Requests the removal of unused space in the container</td>
+<td><a href="http://en.cppreference.com/w/cpp/container/vector/shrink_to_fit">std::vector::shrink_to_fit</a>, <a href="http://en.cppreference.com/w/cpp/container/deque/shrink_to_fit">std::deque::shrink_to_fit</a>, <a href="http://en.cppreference.com/w/cpp/string/basic_string/shrink_to_fit">std::basic_string::shrink_to_fit</a></td>
<td></td>
</tr>
<tr>
<td>Date/Time String Formatting Specifiers</td>
<td><code>std::strftime()</code></td>
-<td>Converts date and time information into a
-formatted string using new specifiers</td>
-<td><a href="http://en.cppreference.com/w/cpp/chrono/c/strftime">
-std::strftime</a></td>
+<td>Converts date and time information into a formatted string using new specifiers</td>
+<td><a href="http://en.cppreference.com/w/cpp/chrono/c/strftime">std::strftime</a></td>
<td></td>
</tr>
<tr>
<td>Function Return Type Deduction</td>
<td><code>std::result_of&lt;<i>Functor(ArgTypes...)</i>&gt;</code></td>
-<td>Extracts the return type from the type signature of
-a function call invocation at compile-time.</td>
-<td><a href="http://en.cppreference.com/w/cpp/types/result_of">
-std::result_of</a></td>
-<td>
-<a href="http://stackoverflow.com/questions/15486951/why-does-stdresult-of-take-an-unrelated-function-type-as-a-type-argument">
-Why does std::result_of take an (unrelated) function type as a type argument?
-</a></td>
+<td>Extracts the return type from the type signature of a function call invocation at compile-time.</td>
+<td><a href="http://en.cppreference.com/w/cpp/types/result_of">std::result_of</a></td>
+<td><a href="http://stackoverflow.com/questions/15486951/why-does-stdresult-of-take-an-unrelated-function-type-as-a-type-argument">Why does std::result_of take an (unrelated) function type as a type argument?</a></td>
</tr>
<tr>
@@ -926,61 +788,47 @@ Why does std::result_of take an (unrelated) function type as a type argument?
<td>Forward Lists</td>
<td><code>std::forward_list</code></td>
<td>Provides an efficient singly linked list</td>
-<td><a href="http://en.cppreference.com/w/cpp/container/forward_list">
-std::forward_list</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/container/forward_list">std::forward_list</a></td>
<td></td>
</tr>
<tr>
<td>Gamma Natural Log</td>
<td><code>std::lgamma()</code></td>
-<td>Computes the natural log of the gamma of a
-floating point value</td>
-<td><a href="http://en.cppreference.com/w/cpp/numeric/math/lgamma">
-std::lgamma</a></td>
+<td>Computes the natural log of the gamma of a floating point value</td>
+<td><a href="http://en.cppreference.com/w/cpp/numeric/math/lgamma">std::lgamma</a></td>
<td></td>
</tr>
<tr>
<td>Garbage Collection Features</td>
-<td><code>std::{un}declare_reachable()</code> and
-<code>std::{un}declare_no_pointers()</code></td>
+<td><code>std::{un}declare_reachable()</code>, <code>std::{un}declare_no_pointers()</code></td>
<td>Enables garbage collection implementations</td>
-<td><a href="http://en.cppreference.com/w/cpp/memory/gc/declare_reachable">
-std::declare_reachable</a>
-and <a href="http://en.cppreference.com/w/cpp/memory/gc/declare_no_pointers">
-std::declare_no_pointers</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/memory/gc/declare_reachable">std::declare_reachable</a>, <a href="http://en.cppreference.com/w/cpp/memory/gc/declare_no_pointers">std::declare_no_pointers</a></td>
<td></td>
</tr>
<tr>
<td>Iterator Operators</td>
-<td><code>std::next()</code> and <code>std::prev()</code></td>
-<td>Copies an iterator and increments or decrements the copy by
-some value</td>
-<td><a href="http://en.cppreference.com/w/cpp/iterator/next">std::next</a>
-and <a href="http://en.cppreference.com/w/cpp/iterator/prev">std::prev</a>
-</td>
+<td><code>std::next()</code>, <code>std::prev()</code></td>
+<td>Copies an iterator and increments or decrements the copy by some value</td>
+<td><a href="http://en.cppreference.com/w/cpp/iterator/next">std::next</a>, <a href="http://en.cppreference.com/w/cpp/iterator/prev">std::prev</a></td>
<td></td>
</tr>
<tr>
<td>Pointer Traits Class Template</td>
<td><code>std::pointer_traits</code></td>
-<td>Provides a standard way to access properties
-of pointers and pointer-like types</td>
-<td><a href="http://en.cppreference.com/w/cpp/memory/pointer_traits">
-std::pointer_traits</a></td>
-<td>Useful for determining the element type
-pointed at by a (possibly smart) pointer.</td>
+<td>Provides a standard way to access properties of pointers and pointer-like types</td>
+<td><a href="http://en.cppreference.com/w/cpp/memory/pointer_traits">std::pointer_traits</a></td>
+<td>Useful for determining the element type pointed at by a (possibly smart) pointer.</td>
</tr>
<tr>
<td>Random Number Generators</td>
<td>Functions within <code>&lt;random&gt;</code></td>
<td>Random number generation algorithms and utilities</td>
-<td><a href="http://en.cppreference.com/w/cpp/numeric/random">
-Pseudo-random number generation</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/numeric/random">Pseudo-random number generation</a></td>
<td></td>
</tr>
@@ -988,48 +836,31 @@ Pseudo-random number generation</a></td>
<td>Ratio Template Class</td>
<td><code>std::ratio&lt;<i>numerator</i>, <i>denominator</i>&gt;</code></td>
<td>Provides compile-time rational numbers</td>
-<td><a href="http://en.cppreference.com/w/cpp/numeric/ratio/ratio">std::ratio
-</a></td>
-<td>Note: These are banned in the google style guide over concerns that they are
-tied to a more template-heavy interface style.</td>
+<td><a href="http://en.cppreference.com/w/cpp/numeric/ratio/ratio">std::ratio</a></td>
+<td>Banned in <a href="https://google.github.io/styleguide/cppguide.html#C++11">Google Style Guide</a> due to concerns that they are tied to a more template-heavy interface style.</td>
</tr>
<tr>
<td>Reference Wrapper Classes</td>
-<td><code>std::reference_wrapper</code> and
-<code>std::ref()</code>, <code>std::cref()</code></td>
-<td>Allows you to wrap a reference within a standard
-object (and use those within containers)</td>
-<td><a href="http://www.informit.com/guides/content.aspx?g=cplusplus&amp;seqNum=217">
-Reference Wrappers</a></td>
+<td><code>std::reference_wrapper</code> and <code>std::ref()</code>, <code>std::cref()</code></td>
+<td>Allows you to wrap a reference within a standard object (and use those within containers)</td>
+<td><a href="http://www.informit.com/guides/content.aspx?g=cplusplus&amp;seqNum=217">Reference Wrappers</a></td>
<td></td>
</tr>
<tr>
<td>Soft Program Exits</td>
-<td><code>std::at_quick_exit()</code>
-and <code>std::quick_exit()</code></td>
-<td>Allows registration of functions to be called upon exit,
-allowing cleaner program exit than <code>abort()</code> or
-<code>exit</code></td>
-<td><a href="http://en.cppreference.com/w/cpp/utility/program/quick_exit">
-std:quick_exit</a></td>
+<td><code>std::at_quick_exit()</code>, <code>std::quick_exit()</code></td>
+<td>Allows registration of functions to be called upon exit, allowing cleaner program exit than <code>abort()</code> or <code>exit</code></td>
+<td><a href="http://en.cppreference.com/w/cpp/utility/program/quick_exit">std:quick_exit</a></td>
<td></td>
</tr>
<tr>
<td>String to Number Functions</td>
-<td><code>std::stoi()</code>, <code>std::stol()</code>,
-<code>std::stoul()</code>, <code>std::stoll</code>, <code>std::stoull()</code>,
-<code>std::stof()</code>, <code>std::stod()</code>, <code>std::stold()</code>,
-and <code>std::to_string()</code></td>
+<td><code>std::stoi()</code>, <code>std::stol()</code>, <code>std::stoul()</code>, <code>std::stoll</code>, <code>std::stoull()</code>, <code>std::stof()</code>, <code>std::stod()</code>, <code>std::stold()</code>, <code>std::to_string()</code></td>
<td>Converts strings to numbers</td>
-<td><a href="http://en.cppreference.com/w/cpp/string/basic_string/stol">
-std::stoi, std::stol, std::stoll</a>,
-<a href="http://en.cppreference.com/w/cpp/string/basic_string/stoul">
-std::stoul, std::stoull</a>, and
-<a href="http://en.cppreference.com/w/cpp/string/basic_string/stof">
-std::stof, std::stod, std::stold</a> </td>
+<td><a href="http://en.cppreference.com/w/cpp/string/basic_string/stol">std::stoi, std::stol, std::stoll</a>, <a href="http://en.cppreference.com/w/cpp/string/basic_string/stoul">std::stoul, std::stoull</a>, <a href="http://en.cppreference.com/w/cpp/string/basic_string/stof">std::stof, std::stod, std::stold</a></td>
<td></td>
</tr>
@@ -1045,33 +876,24 @@ std::stof, std::stod, std::stold</a> </td>
<td>Trailing Return Types</td>
<td><code>auto <i>function declaration</i> -> <i>return_type</i></code></td>
<td>Allows trailing function return value syntax</td>
-<td><a href="http://en.cppreference.com/w/cpp/language/function">
-Declaring functions</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/language/function">Declaring functions</a></td>
<td><a href="https://groups.google.com/a/chromium.org/forum/#!topic/chromium-dev/OQyYSfH9m2M">Discussion thread</a></td>
</tr>
<tr>
<td>Type-Generic Math Functions</td>
<td>Functions within <code>&lt;ctgmath&gt;</code></td>
-<td>Provides a means to call real or complex functions
-based on the type of arguments</td>
-<td><a href="http://en.cppreference.com/w/cpp/header/ctgmath">
-Standard library header &lt;ctgmath&gt;</a></td>
+<td>Provides a means to call real or complex functions based on the type of arguments</td>
+<td><a href="http://en.cppreference.com/w/cpp/header/ctgmath">Standard library header &lt;ctgmath&gt;</a></td>
<td></td>
</tr>
<tr>
<td>Type Info Enhancements</td>
-<td><code>std::type_index</code> and <code>std::type_info::hash_code()</code></td>
-<td>Allows type information (most often within containers)
-that can be copied, assigned, or hashed</td>
-<td><a href="http://en.cppreference.com/w/cpp/types/type_index">
-std::type_index</a> and
-<a href="http://en.cppreference.com/w/cpp/types/type_info/hash_code">
-std::type_info::hash_code</a></td>
-<td><code>std::type_index</code> is a thin wrapper for
-<code>std::type_info</code>, allowing you to use it directly
-within both associative and unordered containers</td>
+<td><code>std::type_index</code>, <code>std::type_info::hash_code()</code></td>
+<td>Allows type information (most often within containers) that can be copied, assigned, or hashed</td>
+<td><a href="http://en.cppreference.com/w/cpp/types/type_index">std::type_index</a>, <a href="http://en.cppreference.com/w/cpp/types/type_info/hash_code">std::type_info::hash_code</a></td>
+<td><code>std::type_index</code> is a thin wrapper for <code>std::type_info</code>, allowing you to use it directly within both associative and unordered containers</td>
</tr>
<tr>
@@ -1086,34 +908,17 @@ within both associative and unordered containers</td>
<td>Weak Pointers</td>
<td><code>std::weak_ptr</code></td>
<td>Allows a weak reference to a <code>std::shared_ptr</code></td>
-<td><a href="http://en.cppreference.com/w/cpp/memory/weak_ptr">
-std::weak_ptr</a></td>
-<td><a href="https://google.github.io/styleguide/cppguide.html#Ownership_and_Smart_Pointers">
-Ownership and Smart Pointers</a></td>
+<td><a href="http://en.cppreference.com/w/cpp/memory/weak_ptr">std::weak_ptr</a></td>
+<td><a href="https://google.github.io/styleguide/cppguide.html#Ownership_and_Smart_Pointers">Ownership and Smart Pointers</a></td>
</tr>
<tr>
<td>Wide String Support</td>
-<td><code>std::wstring_convert</code>,
-<code>std::wbuffer_convert</code>.
-<code>std::codecvt_utf8</code>, <code>std::codecvt_utf16</code>,
-and <code>std::codecvt_utf8_utf16</code></td>
+<td><code>std::wstring_convert</code>, <code>std::wbuffer_convert</code><br />
+<code>std::codecvt_utf8</code>, <code>std::codecvt_utf16</code>, <code>std::codecvt_utf8_utf16</code></td>
<td>Converts between string encodings</td>
-<td><a href="http://en.cppreference.com/w/cpp/locale/wstring_convert">
-std::wstring_convert</a>,
-<a href="http://en.cppreference.com/w/cpp/locale/wbuffer_convert">
-std::wbuffer_convert</a>,
-<a href="http://en.cppreference.com/w/cpp/locale/codecvt_utf8">
-std::codecvt_utf8</a>,
-<a href="http://en.cppreference.com/w/cpp/locale/codecvt_utf16">
-std::codecvt_utf16</a>, and
-<a href="http://en.cppreference.com/w/cpp/locale/codecvt_utf8_utf16">
-std::codecvt_utf8_utf16</a>
-</td>
-<td>Non-UTF-8 text is banned by the
-<a href="https://google.github.io/styleguide/cppguide.html#Non-ASCII_Characters">
-C++ Style Guide</a>. However, may be useful for
-consuming non-ASCII data.</td>
+<td><a href="http://en.cppreference.com/w/cpp/locale/wstring_convert">std::wstring_convert</a>, <a href="http://en.cppreference.com/w/cpp/locale/wbuffer_convert">std::wbuffer_convert</a>, <a href="http://en.cppreference.com/w/cpp/locale/codecvt_utf8">std::codecvt_utf8</a>, <a href="http://en.cppreference.com/w/cpp/locale/codecvt_utf16">std::codecvt_utf16</a>, <a href="http://en.cppreference.com/w/cpp/locale/codecvt_utf8_utf16">std::codecvt_utf8_utf16</a></td>
+<td>Non-UTF-8 text is banned by the <a href="https://google.github.io/styleguide/cppguide.html#Non-ASCII_Characters">Google Style Guide</a>. However, may be useful for consuming non-ASCII data.</td>
</tr>
</tbody>
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698