1<!DOCTYPE html> 2<html> 3<head> 4 <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> 5 <title>Clang - C++17, C++14, C++11 and C++98 Status</title> 6 <link type="text/css" rel="stylesheet" href="menu.css"> 7 <link type="text/css" rel="stylesheet" href="content.css"> 8 <style type="text/css"> 9 .none { background-color: #FFCCCC } 10 .partial { background-color: #FFE0B0 } 11 .svn { background-color: #FFFF99 } 12 .full { background-color: #CCFF99 } 13 .na { background-color: #DDDDDD } 14 :target { background-color: #FFFFBB; outline: #DDDD55 solid thin; } 15 th { background-color: #FFDDAA } 16 td { vertical-align: middle } 17 tt { white-space: nowrap } 18 </style> 19</head> 20<body> 21 22<!--#include virtual="menu.html.incl"--> 23 24<div id="content"> 25 26<!--*************************************************************************--> 27<h1>C++ Support in Clang</h1> 28<!--*************************************************************************--> 29<p>Last updated: $Date: 2019/06/23 22:05:16 $</p> 30 31<p>Clang fully implements all published ISO C++ standards (<a 32href="#cxx98">C++98 / C++03</a>, <a 33href="#cxx11">C++11</a>, and <a 34href="#cxx14">C++14</a>), and most of the upcoming <a 35href="#cxx17">C++17</a> standard. 36 37<p>The Clang community is continually striving to improve C++ standards 38compliance between releases by submitting and tracking <a 39href="cxx_dr_status.html">C++ Defect Reports</a> and implementing resolutions 40as they become available.</p> 41 42<p>Experimental work is also under way to implement <a href="#ts">C++ Technical 43Specifications</a> that will help drive the future of the C++ programming 44language.</p> 45 46<p>The <a href="https://bugs.llvm.org/">LLVM bug tracker</a> contains Clang 47C++ components that track known bugs with Clang's language conformance in 48each language mode.</p> 49 50<h2 id="cxx98">C++98 implementation status</h2> 51 52<p>Clang implements all of the ISO C++ 1998 standard 53 (including the defects addressed in the ISO C++ 2003 standard) 54 except for <tt>export</tt> (which was removed in C++11). 55 56<h2 id="cxx11">C++11 implementation status</h2> 57 58<p>Clang 3.3 and later implement all of the <a 59 href="https://www.iso.org/standard/50372.html">ISO 60 C++ 2011 standard</a>. 61 62<p>By default, Clang builds C++ code according to the C++98 standard, with many 63C++11 features accepted as extensions. You can use Clang in C++11 mode with the 64<code>-std=c++11</code> option. Clang's C++11 mode can be used 65with <a href="https://libcxx.llvm.org/">libc++</a> or with gcc's libstdc++. 66 67<details> 68<summary>List of features and minimum Clang version with support</summary> 69 70<table width="689" border="1" cellspacing="0"> 71 <tr> 72 <th>Language Feature</th> 73 <th>C++11 Proposal</th> 74 <th>Available in Clang?</th> 75 </tr> 76 <tr> 77 <td rowspan="2">Rvalue references</td> 78 <td><a href="https://wg21.link/n2118">N2118</a></td> 79 <td class="full" align="center">Clang 2.9</td> 80 <tr> <!-- from Kona 2019--> 81 <td><a href="https://wg21.link/p1825r0">P1825R0</a> (<a href="#dr">DR</a>)</td> 82 <td class="none" align="center">No</td> 83 </tr> 84 </tr> 85 <tr> 86 <td> Rvalue references for <code>*this</code></td> 87 <td><a href="https://wg21.link/n2439">N2439</a></td> 88 <td class="full" align="center">Clang 2.9</td> 89 </tr> 90 <tr> 91 <td>Initialization of class objects by rvalues</td> 92 <td><a href="https://wg21.link/n1610">N1610</a></td> 93 <td class="full" align="center">Clang 2.9</td> 94 </tr> 95 <tr> 96 <td>Non-static data member initializers</td> 97 <td><a href="https://wg21.link/n2756">N2756</a></td> 98 <td class="full" align="center">Clang 3.0</td> 99 </tr> 100 <tr> 101 <td>Variadic templates</td> 102 <td><a href="https://wg21.link/n2242">N2242</a></td> 103 <td class="full" align="center">Clang 2.9</td> 104 </tr> 105 <tr> 106 <td> Extending variadic template template parameters</td> 107 <td><a href="https://wg21.link/n2555">N2555</a></td> 108 <td class="full" align="center">Clang 2.9</td> 109 </tr> 110 <tr> 111 <td rowspan="2">Initializer lists</td> 112 <td><a href="https://wg21.link/n2672">N2672</a></td> 113 <td class="full" align="center">Clang 3.1</td> 114 </tr> 115 <tr> <!-- from Kona 2019--> 116 <td><a href="https://wg21.link/p1009r2">P1009R2</a> (<a href="#dr">DR</a>)</td> 117 <td class="full" align="center">Clang 9</td> 118 </tr> 119 <tr> 120 <td>Static assertions</td> 121 <td><a href="https://wg21.link/n1720">N1720</a></td> 122 <td class="full" align="center">Clang 2.9</td> 123 </tr> 124 <tr> 125 <td><code>auto</code>-typed variables</td> 126 <td><a href="https://wg21.link/n1984">N1984</a></td> 127 <td class="full" align="center">Clang 2.9</td> 128 </tr> 129 <tr> 130 <td> Multi-declarator <code>auto</code></td> 131 <td><a href="https://wg21.link/n1737">N1737</a></td> 132 <td class="full" align="center">Clang 2.9</td> 133 </tr> 134 <tr> 135 <td> Removal of auto as a storage-class specifier</td> 136 <td><a href="https://wg21.link/n2546">N2546</a></td> 137 <td class="full" align="center">Clang 2.9</td> 138 </tr> 139 <tr> 140 <td> New function declarator syntax</td> 141 <td><a href="https://wg21.link/n2541">N2541</a></td> 142 <td class="full" align="center">Clang 2.9</td> 143 </tr> 144 <tr> 145 <td rowspan="2">Lambda expressions</td> 146 <td><a href="https://wg21.link/n2927">N2927</a></td> 147 <td class="full" align="center">Clang 3.1</td> 148 </tr> 149 <tr> 150 <!-- from Albuquerque 2017 --> 151 <td><a href="https://wg21.link/p0588r1">P0588R1</a> (<a href="#dr">DR</a>)</td> 152 <td class="none" align="center">No</td> 153 </tr> 154 <tr> 155 <td>Declared type of an expression</td> 156 <td><a href="https://wg21.link/n2343">N2343</a></td> 157 <td class="full" align="center">Clang 2.9</td> 158 </tr> 159 <tr> 160 <td> Incomplete return types</td> 161 <td><a href="https://wg21.link/n3276">N3276</a></td> 162 <td class="full" align="center">Clang 3.1</td> 163 </tr> 164 <tr> 165 <td>Right angle brackets</td> 166 <td><a href="https://wg21.link/n1757">N1757</a></td> 167 <td class="full" align="center">Clang 2.9</td> 168 </tr> 169 <tr> 170 <td>Default template arguments for function templates</td> 171 <td><a href="https://wg21.link/cwg226">DR226</a></td> 172 <td class="full" align="center">Clang 2.9</td> 173 </tr> 174 <tr> 175 <td>Solving the SFINAE problem for expressions</td> 176 <td><a href="https://wg21.link/n2634">DR339</a></td> 177 <td class="full" align="center">Clang 2.9</td> 178 </tr> 179 <tr> 180 <td>Alias templates</td> 181 <td><a href="https://wg21.link/n2258">N2258</a></td> 182 <td class="full" align="center">Clang 3.0</td> 183 </tr> 184 <tr> 185 <td>Extern templates</td> 186 <td><a href="https://wg21.link/n1987">N1987</a></td> 187 <td class="full" align="center">Clang 2.9</td> 188 </tr> 189 <tr> 190 <td>Null pointer constant</td> 191 <td><a href="https://wg21.link/n2431">N2431</a></td> 192 <td class="full" align="center">Clang 3.0</td> 193 </tr> 194 <tr> 195 <td>Strongly-typed enums</td> 196 <td><a href="https://wg21.link/n2347">N2347</a></td> 197 <td class="full" align="center">Clang 2.9</td> 198 </tr> 199 <tr> 200 <td>Forward declarations for enums</td> 201 <td><a href="https://wg21.link/n2764">N2764</a> 202 <br><a href="https://wg21.link/cwg1206">DR1206</a></td> 203 <td class="full" align="center">Clang 3.1</td> 204 </tr> 205 <tr> 206 <td>Standardized attribute syntax</td> 207 <td><a href="https://wg21.link/n2761">N2761</a></td> 208 <td class="full" align="center">Clang 3.3 <a href="#n2761">(1)</a></td> 209 </tr> 210 <tr> 211 <td rowspan="2">Generalized constant expressions</td> 212 <td><a href="https://wg21.link/n2235">N2235</a></td> 213 <td class="full" align="center">Clang 3.1</td> 214 </tr> 215 <tr> 216 <!-- from Albuquerque 2017 --> 217 <td><a href="https://wg21.link/p0859r0">P0859R0</a> (<a href="#dr">DR</a>)</td> 218 <td class="full" align="center">Clang 8</td> 219 </tr> 220 <tr> 221 <td>Alignment support</td> 222 <td><a href="https://wg21.link/n2341">N2341</a></td> 223 <td class="full" align="center">Clang 3.3</td> 224 </tr> 225 <tr> 226 <td>Conditionally-support behavior</td> 227 <td><a href="https://wg21.link/n1627">N1627</a></td> 228 <td class="full" align="center">Clang 2.9</td> 229 </tr> 230 <tr> 231 <td>Changing undefined behavior into diagnosable errors</td> 232 <td><a href="https://wg21.link/n1727">N1727</a></td> 233 <td class="full" align="center">Clang 2.9</td> 234 </tr> 235 <tr> 236 <td>Delegating constructors</td> 237 <td><a href="https://wg21.link/n1986">N1986</a></td> 238 <td class="full" align="center">Clang 3.0</td> 239 </tr> 240 <tr> 241 <td rowspan="2">Inheriting constructors</td> 242 <td><a href="https://wg21.link/n2540">N2540</a></td> 243 <td class="full" align="center">Clang 3.3</td> 244 </tr> 245 <tr> 246 <!-- from Kona 2015 --> 247 <td><a href="https://wg21.link/p0136r1">P0136R1</a> (<a href="#dr">DR</a>)</td> 248 <td class="full" align="center">Clang 3.9</td> 249 </tr> 250 <tr> 251 <td>Explicit conversion operators</td> 252 <td><a href="https://wg21.link/n2437">N2437</a></td> 253 <td class="full" align="center">Clang 3.0</td> 254 </tr> 255 <tr> 256 <td>New character types</td> 257 <td><a href="https://wg21.link/n2249">N2249</a></td> 258 <td class="full" align="center">Clang 2.9</td> 259 </tr> 260 <tr> 261 <td>Unicode string literals</td> 262 <td><a href="https://wg21.link/n2442">N2442</a></td> 263 <td class="full" align="center">Clang 3.0</td> 264 </tr> 265 <tr> 266 <td>Raw string literals</td> 267 <td><a href="https://wg21.link/n2442">N2442</a></td> 268 <td class="full" align="center">Clang 3.0</td> 269 </tr> 270 <tr> 271 <td>Universal character names in literals</td> 272 <td><a href="https://wg21.link/n2170">N2170</a></td> 273 <td class="full" align="center">Clang 3.1</td> 274 </tr> 275 <tr> 276 <td>User-defined literals</td> 277 <td><a href="https://wg21.link/n2765">N2765</a></td> 278 <td class="full" align="center">Clang 3.1</td> 279 </tr> 280 <tr> 281 <td>Standard Layout Types</td> 282 <td><a href="https://wg21.link/n2342">N2342</a></td> 283 <td class="full" align="center">Clang 3.0</td> 284 </tr> 285 <tr> 286 <td rowspan="2">Defaulted functions</td> 287 <td><a href="https://wg21.link/n2346">N2346</a></td> 288 <td class="full" align="center">Clang 3.0</td> 289 </tr> 290 <tr> <!-- from Kona 2019--> 291 <td><a href="https://wg21.link/p1286r2">P1286R2</a> (<a href="#dr">DR</a>)</td> 292 <td class="full" align="center">Clang 9</td> 293 </tr> 294 <tr> 295 <td>Deleted functions</td> 296 <td><a href="https://wg21.link/n2346">N2346</a></td> 297 <td class="full" align="center">Clang 2.9</td> 298 </tr> 299 <tr> 300 <td>Extended friend declarations</td> 301 <td><a href="https://wg21.link/n1791">N1791</a></td> 302 <td class="full" align="center">Clang 2.9</td> 303 </tr> 304 <tr> 305 <td>Extending <code>sizeof</code></td> 306 <td><a href="https://wg21.link/n2253">N2253</a> 307 <br><a href="https://wg21.link/cwg850">DR850</a></td> 308 <td class="full" align="center">Clang 3.1</td> 309 </tr> 310 <tr> 311 <td>Inline namespaces</td> 312 <td><a href="https://wg21.link/n2535">N2535</a></td> 313 <td class="full" align="center">Clang 2.9</td> 314 </tr> 315 <tr> 316 <td>Unrestricted unions</td> 317 <td><a href="https://wg21.link/n2544">N2544</a></td> 318 <td class="full" align="center">Clang 3.1</td> 319 </tr> 320 <tr> 321 <td>Local and unnamed types as template arguments</td> 322 <td><a href="https://wg21.link/n2657">N2657</a></td> 323 <td class="full" align="center">Clang 2.9</td> 324 </tr> 325 <tr> 326 <td rowspan="2">Range-based for</td> 327 <td><a href="https://wg21.link/n2930">N2930</a></td> 328 <td class="full" align="center">Clang 3.0</td> 329 </tr> 330 <tr> 331 <!-- from Jacksonville 2018 --> 332 <td><a href="https://wg21.link/p0962r1">P0962R1</a> (<a href="#dr">DR</a>)</td> 333 <td class="full" align="center">Clang 8</td> 334 </tr> 335 <tr> 336 <td>Explicit virtual overrides</td> 337 <td><a href="https://wg21.link/n2928">N2928</a> 338 <br><a href="https://wg21.link/n3206">N3206</a> 339 <br><a href="https://wg21.link/n3272">N3272</a></td> 340 <td class="full" align="center">Clang 3.0</td> 341 </tr> 342 <tr> 343 <td>Minimal support for garbage collection and reachability-based leak detection</td> 344 <td><a href="https://wg21.link/n2670">N2670</a></td> 345 <td class="na" align="center">N/A <a href="#n2670">(2)</a></td> 346 </tr> 347 <tr> 348 <td>Allowing move constructors to throw [noexcept]</td> 349 <td><a href="https://wg21.link/n3050">N3050</a></td> 350 <td class="full" align="center">Clang 3.0</td> 351 </tr> 352 <tr> 353 <td>Defining move special member functions</td> 354 <td><a href="https://wg21.link/n3053">N3053</a></td> 355 <td class="full" align="center">Clang 3.0</td> 356 </tr> 357 358 <tr class="separator"> 359 <th align="center" colspan="3">Concurrency</th> 360 </tr> 361 <tr> 362 <td>Sequence points</td> 363 <td><a href="https://wg21.link/n2239">N2239</a></td> 364 <td class="full" align="center">Clang 3.3</td> 365 </tr> 366 <tr> 367 <td>Atomic operations</td> 368 <td><a href="https://wg21.link/n2427">N2427</a></td> 369 <td class="full" align="center">Clang 3.1</td> 370 </tr> 371 <tr> 372 <td>Strong Compare and Exchange</td> 373 <td><a href="https://wg21.link/n2748">N2748</a></td> 374 <td class="full" align="center">Clang 3.1 <a href="#n2748">(3)</a></td> 375 </tr> 376 <tr> 377 <td>Bidirectional Fences</td> 378 <td><a href="https://wg21.link/n2752">N2752</a></td> 379 <td class="full" align="center">Clang 3.1</td> 380 </tr> 381 382 <tr> 383 <td>Memory model</td> 384 <td><a href="https://wg21.link/n2429">N2429</a></td> 385 <td class="full" align="center">Clang 3.2</td> 386 </tr> 387 <tr> 388 <td>Data-dependency ordering: atomics and memory model</td> 389 <td><a href="https://wg21.link/n2664">N2664</a></td> 390 <td class="full" align="center">Clang 3.2 <a href="#n2664">(4)</a></td> 391 </tr> 392 <tr> 393 <td>Propagating exceptions</td> 394 <td><a href="https://wg21.link/n2179">N2179</a></td> 395 <td class="full" align="center">Clang 2.9</td> 396 </tr> 397 <tr> 398 <td>Allow atomics use in signal handlers</td> 399 <td><a href="https://wg21.link/n2547">N2547</a></td> 400 <td class="full" align="center">Clang 3.1</td> 401 </tr> 402 <tr> 403 <td>Thread-local storage</td> 404 <td><a href="https://wg21.link/n2659">N2659</a></td> 405 <td class="full" align="center">Clang 3.3 <a href="#n2659">(5)</a></td> 406 </tr> 407 <tr> 408 <td>Dynamic initialization and destruction with concurrency</td> 409 <td><a href="https://wg21.link/n2660">N2660</a></td> 410 <td class="full" align="center">Clang 2.9</td> 411 </tr> 412 413 <tr class="separator"> 414 <th align="center" colspan="3">C99 Features in C++11</th> 415 </tr> 416 <tr> 417 <td><code>__func__</code> predefined identifier</td> 418 <td><a href="https://wg21.link/n2340">N2340</a></td> 419 <td class="full" align="center">Clang 2.9</td> 420 </tr> 421 <tr> 422 <td>C99 preprocessor</td> 423 <td><a href="https://wg21.link/n1653">N1653</a></td> 424 <td class="full" align="center">Clang 2.9</td> 425 </tr> 426 <tr> 427 <td><code>long long</code></td> 428 <td><a href="https://wg21.link/n1811">N1811</a></td> 429 <td class="full" align="center">Clang 2.9</td> 430 </tr> 431 <tr> 432 <td>Extended integral types</td> 433 <td><a href="https://wg21.link/n1988">N1988</a></td> 434 <td class="na" align="center">N/A <a href="#n1988">(6)</a></td> 435 </tr> 436</table> 437 438<p> 439<span id="n2761">(1): The <code>[[carries_dependency]]</code> attribute 440has no effect.</span><br> 441<span id="n2670">(2): No compiler changes are required for an implementation 442such as Clang that does not provide garbage collection.</span><br> 443<span id="n2748">(3): All compare-exchange operations are emitted as 444strong compare-exchanges.</span><br> 445<span id="n2664">(4): <code>memory_order_consume</code> is lowered to 446<code>memory_order_acquire</code>.</span><br> 447<span id="n2659">(5): <code>thread_local</code> support 448requires a C++ runtime library providing <code>__cxa_thread_atexit</code>, such 449as <a href="https://libcxxabi.llvm.org">libc++abi</a> 3.6 or later, 450or libsupc++ 4.8 or later.</span><br> 451<span id="n1988">(6): No compiler changes are required for an implementation 452such as Clang that does not provide any extended integer types. 453<code>__int128</code> is not treated as an extended integer type, 454because changing <code>intmax_t</code> would be an ABI-incompatible 455change.</span> 456</p> 457</details> 458 459<h2 id="cxx14">C++14 implementation status</h2> 460 461<p>Clang 3.4 and later implement all of the <a 462 href="https://www.iso.org/standard/64029.html">ISO 463 C++ 2014 standard</a>. 464 465<p>You can use Clang in C++14 mode with the <code>-std=c++14</code> option 466(use <code>-std=c++1y</code> in Clang 3.4 and earlier).</p> 467 468<details> 469<summary>List of features and minimum Clang version with support</summary> 470 471<table width="689" border="1" cellspacing="0"> 472 <tr> 473 <th>Language Feature</th> 474 <th>C++14 Proposal</th> 475 <th>Available in Clang?</th> 476 </tr> 477 <tr> 478 <td>Tweak to certain C++ contextual conversions</td> 479 <td><a href="https://wg21.link/n3323">N3323</a></td> 480 <td class="full" align="center">Clang 3.4</td> 481 </tr> 482 <tr> 483 <td>Binary literals</td> 484 <td><a href="https://wg21.link/n3472">N3472</a></td> 485 <td class="full" align="center">Clang 2.9</td> 486 </tr> 487 <tr> 488 <td>decltype(auto)</td> 489 <td rowspan=2 style="vertical-align:middle"><a href="https://wg21.link/n3638">N3638</a></td> 490 <td class="full" align="center">Clang 3.3</td> 491 </tr> 492 <tr> 493 <td>Return type deduction for normal functions</td> 494 <td class="full" align="center">Clang 3.4</td> 495 </tr> 496 <tr> 497 <td>Initialized lambda captures</td> 498 <td><a href="https://wg21.link/n3648">N3648</a></td> 499 <td class="full" align="center">Clang 3.4</td> 500 </tr> 501 <tr> 502 <td>Generic lambdas</td> 503 <td><a href="https://wg21.link/n3649">N3649</a></td> 504 <td class="full" align="center">Clang 3.4</td> 505 </tr> 506 <tr> 507 <td>Variable templates</td> 508 <td><a href="https://wg21.link/n3651">N3651</a></td> 509 <td class="full" align="center">Clang 3.4</td> 510 </tr> 511 <tr> 512 <td>Relaxing requirements on constexpr functions</td> 513 <td><a href="https://wg21.link/n3652">N3652</a></td> 514 <td class="full" align="center">Clang 3.4</td> 515 </tr> 516 <tr> 517 <td>Member initializers and aggregates</td> 518 <td><a href="https://wg21.link/n3653">N3653</a></td> 519 <td class="full" align="center">Clang 3.3</td> 520 </tr> 521 <tr> 522 <td>Clarifying memory allocation</td> 523 <td><a href="https://wg21.link/n3664">N3664</a></td> 524 <td class="full" align="center">Clang 3.4</td> 525 </tr> 526 <tr> 527 <td><tt>[[deprecated]]</tt> attribute</td> 528 <td><a href="https://wg21.link/n3760">N3760</a></td> 529 <td class="full" align="center">Clang 3.4</td> 530 </tr> 531 <tr> 532 <td>Single quotation mark as digit separator</td> 533 <td><a href="https://wg21.link/n3781">N3781</a></td> 534 <td class="full" align="center">Clang 3.4</td> 535 </tr> 536 <tr> 537 <td>C++ Sized Deallocation</td> 538 <td><a href="https://wg21.link/n3778">N3778</a></td> 539 <td class="full" align="center">Clang 3.4 <a href="#n3778">(7)</a></td> 540 </tr> 541</table> 542 543<p> 544<span id="n3778">(7): In Clang 3.7 and later, sized deallocation is only enabled 545if the user passes the <code>-fsized-deallocation</code> flag. The user must 546supply definitions of the sized deallocation functions, either by providing them 547explicitly or by using a C++ standard library that does. <code>libstdc++</code> 548added these functions in version 5.0, and <code>libc++</code> added them in 549version 3.7. 550</span> 551</p> 552</details> 553 554<h2 id="cxx17">C++17 implementation status</h2> 555 556<p>Clang 5 and later implement all the features of the 557<a href="https://www.iso.org/standard/68564.html">ISO C++ 2017 standard</a>. 558 559<p>You can use Clang in C++17 mode with the <code>-std=c++17</code> option 560(use <code>-std=c++1z</code> in Clang 4 and earlier).</p> 561 562<details open> 563<summary>List of features and minimum Clang version with support</summary> 564 565<table width="689" border="1" cellspacing="0"> 566 <tr> 567 <th>Language Feature</th> 568 <th>C++17 Proposal</th> 569 <th>Available in Clang?</th> 570 </tr> 571 <!-- Issaquah 2014 papers --> 572 <tr> 573 <td><tt>static_assert</tt> with no message</td> 574 <td><a href="https://wg21.link/n3928">N3928</a></td> 575 <td class="full" align="center">Clang 3.5</td> 576 </tr> 577 <!-- Rapperswil papers --> 578 <tr> 579 <td>Disabling trigraph expansion by default</td> 580 <td><a href="https://wg21.link/n4086">N4086</a></td> 581 <td class="full" align="center">Clang 3.5</td> 582 </tr> 583 <!-- 584 <tr> 585 <td rowspan="2">Terse range-based for loops (removed from C++17)</td> 586 <td rowspan="2"><a href="https://wg21.link/n3994">N3994</a></td> 587 <td class="none" align="center">Clang 3.5: Yes</td> 588 </tr> 589 <tr> 590 <td class="svn" align="center">SVN: No</td> 591 </tr> 592 --> 593 <tr> 594 <td><tt>typename</tt> in a template template parameter</td> 595 <td><a href="https://wg21.link/n4051">N4051</a></td> 596 <td class="full" align="center">Clang 3.5</td> 597 </tr> 598 <tr> 599 <td>New <tt>auto</tt> rules for direct-list-initialization 600 <td><a href="https://wg21.link/n3922">N3922</a></td> 601 <td class="full" align="center">Clang 3.8 <a href="#n3922">(8)</a></td> 602 </tr> 603 <!-- Urbana papers --> 604 <tr> 605 <td rowspan="2">Fold expressions</td> 606 <td><a href="https://wg21.link/n4295">N4295</a></td> 607 <td class="full" align="center">Clang 3.6</td> 608 </tr> 609 <tr> <!-- from Jacksonville --> 610 <td><a href="https://wg21.link/p0036r0">P0036R0</a></td> 611 <td class="full" align="center">Clang 3.9</td> 612 </tr> 613 <tr> 614 <td><tt>u8</tt> character literals</td> 615 <td><a href="https://wg21.link/n4267">N4267</a></td> 616 <td class="full" align="center">Clang 3.6</td> 617 </tr> 618 <tr> 619 <td>Nested namespace definition</td> 620 <td><a href="https://wg21.link/n4230">N4230</a></td> 621 <td class="full" align="center">Clang 3.6</td> 622 </tr> 623 <tr> 624 <td>Attributes for namespaces and enumerators</td> 625 <td><a href="https://wg21.link/n4266">N4266</a></td> 626 <td class="full" align="center">Clang 3.6</td> 627 </tr> 628 <tr> 629 <td>Allow constant evaluation for all non-type template arguments</td> 630 <td><a href="https://wg21.link/n4268">N4268</a></td> 631 <td class="full" align="center">Clang 3.6</td> 632 </tr> 633 <!-- Kona papers --> 634 <tr> 635 <td>Remove deprecated <tt>register</tt> storage class</td> 636 <td><a href="https://wg21.link/p0001r1">P0001R1</a></td> 637 <td class="full" align="center">Clang 3.8</td> 638 </tr> 639 <tr> 640 <td>Remove deprecated <tt>bool</tt> increment</td> 641 <td><a href="https://wg21.link/p0002r1">P0002R1</a></td> 642 <td class="full" align="center">Clang 3.8</td> 643 </tr> 644 <tr> 645 <td>Make exception specifications part of the type system</td> 646 <td><a href="https://wg21.link/p0012r1">P0012R1</a></td> 647 <td class="full" align="center">Clang 4</td> 648 </tr> 649 <tr> 650 <td><tt>__has_include</tt> in preprocessor conditionals</td> 651 <td><a href="https://wg21.link/p0061r1">P0061R1</a></td> 652 <td class="full" align="center">Yes</td> 653 </tr> 654 <!-- Jacksonville papers --> 655 <tr> 656 <td><tt>[[fallthrough]]</tt> attribute</td> 657 <td><a href="https://wg21.link/p0188r1">P0188R1</a></td> 658 <td class="full" align="center">Clang 3.9</td> 659 </tr> 660 <tr> 661 <td rowspan="2"><tt>[[nodiscard]]</tt> attribute</td> 662 <td><a href="https://wg21.link/p0189r1">P0189R1</a></td> 663 <td class="full" align="center">Clang 3.9</td> 664 </tr> 665 <tr> <!-- from Cologne 2019 --> 666 <td><a href="https://wg21.link/p1771r1">P1771R1</a> (<a href="#dr">DR</a>)</td> 667 <td class="full" align="center">Clang 9</td> 668 </tr> 669 <tr> 670 <td><tt>[[maybe_unused]]</tt> attribute</td> 671 <td><a href="https://wg21.link/p0212r1">P0212R1</a></td> 672 <td class="full" align="center">Clang 3.9</td> 673 </tr> 674 <tr> 675 <td>Aggregate initialization of classes with base classes</td> 676 <td><a href="https://wg21.link/p0017r1">P0017R1</a></td> 677 <td class="full" align="center">Clang 3.9</td> 678 </tr> 679 <tr> 680 <td><tt>constexpr</tt> lambda expressions</td> 681 <td><a href="https://wg21.link/p0170r1">P0170R1</a></td> 682 <td class="full" align="center">Clang 5</td> 683 </tr> 684 <tr> 685 <td>Differing <tt>begin</tt> and <tt>end</tt> types in range-based <tt>for</tt></td> 686 <td><a href="https://wg21.link/p0184r0">P0184R0</a></td> 687 <td class="full" align="center">Clang 3.9</td> 688 </tr> 689 <tr> 690 <td>Lambda capture of <tt>*this</tt></td> 691 <td><a href="https://wg21.link/p0018r3">P0018R3</a></td> 692 <td class="full" align="center">Clang 3.9</td> 693 </tr> 694 <tr> 695 <td>Direct-list-initialization of <tt>enum</tt>s</td> 696 <td><a href="https://wg21.link/p0138r2">P0138R2</a></td> 697 <td class="full" align="center">Clang 3.9</td> 698 </tr> 699 <tr> 700 <td>Hexadecimal floating-point literals</td> 701 <td><a href="https://wg21.link/p0245r1">P0245R1</a></td> 702 <td class="full" align="center">Yes</td> 703 </tr> 704 <!-- Oulu papers --> 705 <tr> 706 <td>Using attribute namespaces without repetition</td> 707 <td><a href="https://wg21.link/p0028r4">P0028R4</a></td> 708 <td class="full" align="center">Clang 3.9</td> 709 </tr> 710 <tr> 711 <td>Dynamic memory allocation for over-aligned data</td> 712 <td><a href="https://wg21.link/p0035r4">P0035R4</a></td> 713 <td class="full" align="center">Clang 4</td> 714 </tr> 715 <tr> 716 <td rowspan="4">Template argument deduction for class templates</td> 717 <td><a href="https://wg21.link/p0091r3">P0091R3</a></td> 718 <td rowspan="2" class="full" align="center">Clang 5</td> 719 </tr> 720 <tr> <!-- from Issaquah --> 721 <td><a href="https://wg21.link/p0512r0">P0512R0</a></td> 722 </tr> 723 <tr> 724 <!-- from Kona 2017 --> 725 <td><a href="https://wg21.link/p0620r1">P0620R0</a> (<a href="#dr">DR</a>)</td> 726 <td class="full" align="center">Clang 7</td> 727 </tr> 728 <tr> 729 <!-- from Toronto 2017 --> 730 <td><a href="https://wg21.link/p0702r1">P0702R1</a> (<a href="#dr">DR</a>)</td> 731 <td class="full" align="center">Clang 6</td> 732 </tr> 733 <tr> 734 <td>Non-type template parameters with <tt>auto</tt> type</td> 735 <td><a href="https://wg21.link/p0127r2">P0127R2</a></td> 736 <td class="full" align="center">Clang 4</td> 737 </tr> 738 <tr> 739 <td>Guaranteed copy elision</td> 740 <td><a href="https://wg21.link/p0135r1">P0135R1</a></td> 741 <td class="full" align="center">Clang 4</td> 742 </tr> 743 <tr> 744 <td rowspan=2>Stricter expression evaluation order</td> 745 <td><a href="https://wg21.link/p0145r3">P0145R3</a></td> 746 <td class="full" align="center" rowspan=2>Clang 4 <a href="#p0145">(9)</a></td> 747 </tr> 748 <tr> 749 <td><a href="https://wg21.link/p0400r0">P0400R0</a></td> 750 </tr> 751 <tr> 752 <td>Requirement to ignore unknown attributes</td> 753 <td><a href="https://wg21.link/p0283r2">P0283R2</a></td> 754 <td class="full" align="center">Yes</td> 755 </tr> 756 <tr> 757 <td><tt>constexpr</tt> <em>if-statement</em>s</td> 758 <td><a href="https://wg21.link/p0292r2">P0292R2</a></td> 759 <td class="full" align="center">Clang 3.9</td> 760 </tr> 761 <tr> 762 <td>Inline variables</td> 763 <td><a href="https://wg21.link/p0386r2">P0386R2</a></td> 764 <td class="full" align="center">Clang 3.9</td> 765 </tr> 766 <tr> 767 <td rowspan="3">Structured bindings</td> 768 <td><a href="https://wg21.link/p0217r3">P0217R3</a></td> 769 <td class="full" align="center">Clang 4</td> 770 </tr> 771 <tr> 772 <!-- from Jacksonville 2018 --> 773 <td><a href="https://wg21.link/p0961r1">P0961R1</a> (<a href="#dr">DR</a>)</td> 774 <td class="full" align="center">Clang 8</td> 775 </tr> 776 <tr> 777 <!-- from Jacksonville 2018 --> 778 <td><a href="https://wg21.link/p0969r0">P0969R0</a> (<a href="#dr">DR</a>)</td> 779 <td class="full" align="center">Clang 8</td> 780 </tr> 781 <tr> 782 <td>Separate variable and condition for <tt>if</tt> and <tt>switch</tt></td> 783 <td><a href="https://wg21.link/p0305r1">P0305R1</a></td> 784 <td class="full" align="center">Clang 3.9</td> 785 </tr> 786 <!-- Issaquah 2016 papers --> 787 <tr> 788 <td>Matching template template parameters to compatible arguments</td> 789 <td><a href="https://wg21.link/p0522r0">P0522R0</a></td> 790 <td class="partial" align="center">Partial <a href="#p0522">(10)</a></td> 791 </tr> 792 <tr> 793 <td>Removing deprecated dynamic exception specifications</td> 794 <td><a href="https://wg21.link/p0003r5">P0003R5</a></td> 795 <td class="full" align="center">Clang 4</td> 796 </tr> 797 <tr> 798 <td>Pack expansions in <em>using-declarations</em></td> 799 <td><a href="https://wg21.link/p0195r2">P0195R2</a></td> 800 <td class="full" align="center">Clang 4</td> 801 </tr> 802</table> 803 804<p> 805<span id="n3922">(8): This is a backwards-incompatible change that is applied to 806all language versions that allow type deduction from <tt>auto</tt> 807(per the request of the C++ committee). 808In Clang 3.7, a warning is emitted for all cases that would change meaning. 809</span><br> 810<span id="p0145">(9): Under the MS ABI, function parameters are destroyed from 811left to right in the callee. As a result, function parameters in calls to 812<tt>operator<<</tt>, <tt>operator>></tt>, <tt>operator->*</tt>, 813<tt>operator&&</tt>, <tt>operator||</tt>, and <tt>operator,</tt> 814functions using expression syntax are no longer guaranteed to be destroyed in 815reverse construction order in that ABI. 816</span><br> 817<span id="p0522">(10): Despite being the resolution to a Defect Report, this 818feature is disabled by default in all language versions, and can be enabled 819explicitly with the flag <tt>-frelaxed-template-template-args</tt> in Clang 4 820onwards. 821The change to the standard lacks a corresponding change for template partial 822ordering, resulting in ambiguity errors for reasonable and previously-valid 823code. This issue is expected to be rectified soon. 824</span> 825</p> 826</details> 827 828<h2 id="cxx20">C++20 implementation status</h2> 829 830<p>Clang has support for some of the features of the 831ISO C++ 2020 Draft International Standard. 832 833<p>You can use Clang in C++20 mode with the <code>-std=c++20</code> option 834(use <code>-std=c++2a</code> in Clang 10 and earlier).</p> 835 836<details open> 837<summary>List of features and minimum Clang version with support</summary> 838 839<table width="689" border="1" cellspacing="0"> 840 <tr> 841 <th>Language Feature</th> 842 <th>C++20 Proposal</th> 843 <th>Available in Clang?</th> 844 </tr> 845 <!-- Toronto 2017 papers --> 846 <tr> 847 <td>Default member initializers for bit-fields</td> 848 <td><a href="https://wg21.link/p0683r1">P0683R1</a></td> 849 <td class="full" align="center">Clang 6</td> 850 </tr> 851 <tr> 852 <td><tt>const&</tt>-qualified pointers to members</td> 853 <td><a href="https://wg21.link/p0704r1">P0704R1</a></td> 854 <td class="full" align="center">Clang 6</td> 855 </tr> 856 <tr> 857 <td>Allow <i>lambda-capture</i> <tt>[=, this]</tt></td> 858 <td><a href="https://wg21.link/p0409r2">P0409R2</a></td> 859 <td class="full" align="center">Clang 6</td> 860 </tr> 861 <tr> 862 <td rowspan="2"><tt>__VA_OPT__</tt> for preprocessor comma elision</td> 863 <td><a href="https://wg21.link/p0306r4">P0306R4</a></td> 864 <td class="full" align="center">Clang 6</td> 865 </tr> 866 <tr> <!-- from Rapperswil --> 867 <td><a href="https://wg21.link/p1042r1">P1042R1</a></td> 868 <td class="full" align="center">Clang 9</td> 869 </tr> 870 <tr> 871 <td>Designated initializers</td> 872 <td><a href="https://wg21.link/p0329r4">P0329R4</a></td> 873 <td class="svn" align="center">SVN</td> 874 </tr> 875 <tr> 876 <td><i>template-parameter-list</i> for generic lambdas</td> 877 <td><a href="https://wg21.link/p0428r2">P0428R2</a></td> 878 <td class="full" align="center">Clang 9</td> 879 </tr> 880 <tr id="p0734"> 881 <td rowspan="9">Concepts</td> 882 <td><a href="https://wg21.link/p0734r0">P0734R0</a></td> 883 <td rowspan="4" class="unreleased" align="center">SVN</td> 884 </tr> 885 <tr> <!-- from Albuquerque --> 886 <td><a href="https://wg21.link/p0857r0">P0857R0</a></td> 887 </tr> 888 <tr> <!-- from San Diego --> 889 <td><a href="https://wg21.link/p1084r2">P1084R2</a></td> 890 </tr> 891 <tr> 892 <td><a href="https://wg21.link/p1141r2">P1141R2</a></td> 893 </tr> 894 <tr> <!-- from Cologne --> 895 <td><a href="https://wg21.link/p0848r3">P0848R3</a></td> 896 <td rowspan="1" class="none" align="center">No</td> 897 </tr> 898 <tr> 899 <td><a href="https://wg21.link/p1616r1">P1616R1</a></td> 900 <td rowspan="2" class="unreleased" align="center">SVN</td> 901 </tr> 902 <tr> 903 <td><a href="https://wg21.link/p1452r2">P1452R2</a></td> 904 </tr> 905 <tr> <!-- from Belfast --> 906 <td><a href="https://wg21.link/p1972r0">P1972R0</a></td> 907 <td rowspan="2" class="none" align="center">No</td> 908 </tr> 909 <tr> 910 <td><a href="https://wg21.link/p1980r0">P1980R0</a></td> 911 </tr> 912 <!-- Albuquerque papers --> 913 <tr> 914 <td>Range-based for statements with initializer</td> 915 <td><a href="https://wg21.link/p0614r1">P0614R1</a></td> 916 <td class="full" align="center">Clang 8</td> 917 </tr> 918 <tr> 919 <td>ADL and function templates that are not visible</td> 920 <td><a href="https://wg21.link/p0846r0">P0846R0</a></td> 921 <td class="full" align="center">Clang 9</td> 922 </tr> 923 <tr> 924 <td><tt>const</tt> mismatch with defaulted copy constructor</td> 925 <td><a href="https://wg21.link/p0641r2">P0641R2</a></td> 926 <td class="full" align="center">Clang 8</td> 927 </tr> 928 <tr> 929 <td rowspan="8">Consistent comparison (<tt>operator<=></tt>)</td> 930 <td><a href="https://wg21.link/p0515r3">P0515R3</a></td> 931 <td rowspan="8" class="svn" align="center">SVN</td> 932 </tr> 933 <tr> <!-- from Jacksonville --> 934 <td><a href="https://wg21.link/p0905r1">P0905R1</a></td> 935 </tr> 936 <tr> <!-- from Rapperswil --> 937 <td><a href="https://wg21.link/p1120r0">P1120R0</a></td> 938 </tr> 939 <tr> <!-- from Kona 2019 --> 940 <td><a href="https://wg21.link/p1185r2">P1185R2</a></td> 941 </tr> 942 <tr> <!-- from Cologne --> 943 <td><a href="https://wg21.link/p1186r3">P1186R3</a></td> 944 </tr> 945 <tr> 946 <td><a href="https://wg21.link/p1630r1">P1630R1</a></td> 947 </tr> 948 <tr> <!-- from Belfast --> 949 <td><a href="https://wg21.link/p1946r0">P1946R0</a></td> 950 </tr> 951 <tr> 952 <td><a href="https://wg21.link/p1959r0">P1959R0</a></td> 953 </tr> 954 <tr> 955 <td>Access checking on specializations</td> 956 <td><a href="https://wg21.link/p0692r1">P0692R1</a></td> 957 <td class="partial" align="center">Partial</td> 958 </tr> 959 <tr> 960 <td>Default constructible and assignable stateless lambdas</td> 961 <td><a href="https://wg21.link/p0624r2">P0624R2</a></td> 962 <td class="full" align="center">Clang 8</td> 963 </tr> 964 <tr> 965 <td>Lambdas in unevaluated contexts</td> 966 <td><a href="https://wg21.link/p0315r4">P0315R4</a></td> 967 <td class="none" align="center">No</td> 968 </tr> 969 <!-- Jacksonville papers --> 970 <tr> 971 <td><tt>[[no_unique_address]]</tt> attribute</td> 972 <td><a href="https://wg21.link/p0840r2">P0840R2</a></td> 973 <td class="full" align="center">Clang 9</td> 974 </tr> 975 <tr> 976 <td><tt>[[likely]]</tt> and <tt>[[unlikely]]</tt> attributes</td> 977 <td><a href="https://wg21.link/p0479r5">P0479R5</a></td> 978 <td class="none" align="center">No</td> 979 </tr> 980 <tr> 981 <td><tt>typename</tt> optional in more contexts</td> 982 <td><a href="https://wg21.link/p0634r3">P0634R3</a></td> 983 <td class="none" align="center">No</td> 984 </tr> 985 <tr> 986 <td>Pack expansion in lambda <i>init-capture</i></td> 987 <td><a href="https://wg21.link/p0780r2">P0780R2</a></td> 988 <td class="full" align="center">Clang 9</td> 989 </tr> 990 <!-- Rapperswil papers --> 991 <tr> 992 <td rowspan="2">Class types as non-type template parameters</td> 993 <td><a href="https://wg21.link/p0732r2">P0732R2</a></td> 994 <td rowspan="2" class="none" align="center">No</td> 995 </tr> 996 <tr> <!-- from Belfast --> 997 <td><a href="https://wg21.link/p1907r1">P1907R1</a></td> 998 </tr> 999 <tr> 1000 <td>Destroying operator delete</td> 1001 <td><a href="https://wg21.link/p0722r3">P0722R3</a></td> 1002 <td class="full" align="center">Clang 6</td> 1003 </tr> 1004 <tr> 1005 <td rowspan="7">Relaxations of <tt>constexpr</tt> restrictions</td> 1006 <td><a href="https://wg21.link/p1064r0">P1064R0</a></td> 1007 <td class="full" align="center">Clang 9</td> 1008 </tr> 1009 <tr> <!-- from San Diego --> 1010 <td><a href="https://wg21.link/p1002r1">P1002R1</a></td> 1011 <td class="full" align="center">Clang 8</td> 1012 </tr> 1013 <tr> 1014 <td><a href="https://wg21.link/p1327r1">P1327R1</a></td> 1015 <td rowspan="2" class="full" align="center">Clang 9</td> 1016 </tr> 1017 <tr> 1018 <td><a href="https://wg21.link/p1330r0">P1330R0</a></td> 1019 </tr> 1020 <tr> <!-- from Cologne --> 1021 <td><a href="https://wg21.link/p1331r2">P1331R2</a></td> 1022 <td rowspan="3" class="svn" align="center">SVN</td> 1023 </tr> 1024 <tr> 1025 <td><a href="https://wg21.link/p1668r1">P1668R1</a></td> 1026 </tr> 1027 <tr> 1028 <td><a href="https://wg21.link/p0784r7">P0784R7</a></td> 1029 </tr> 1030 <tr> 1031 <td>Prohibit aggregates with user-declared constructors</td> 1032 <td><a href="https://wg21.link/p1008r1">P1008R1</a></td> 1033 <td class="full" align="center">Clang 8</td> 1034 </tr> 1035 <tr> 1036 <td>Feature test macros</td> 1037 <td><a href="https://wg21.link/p0941r2">P0941R2</a></td> 1038 <td class="full" align="center"><a href="#sd6">(see below)</a></td> 1039 </tr> 1040 <tr> 1041 <td><tt>explicit(bool)</tt></td> 1042 <td><a href="https://wg21.link/p0892r2">P0892R2</a></td> 1043 <td class="full" align="center">Clang 9</td> 1044 </tr> 1045 <!-- San Diego papers --> 1046 <tr> 1047 <td>Signed integers are two's complement</td> 1048 <td><a href="https://wg21.link/p1236r1">P1236R1</a></td> 1049 <td class="full" align="center">Clang 9</td> 1050 </tr> 1051 <tr> 1052 <td><tt>char8_t</tt></td> 1053 <td><a href="https://wg21.link/p0482r6">P0482R6</a></td> 1054 <td class="full" align="center">Clang 7 <a href="#p0482">(11)</a></td> 1055 </tr> 1056 <tr> 1057 <td>Immediate functions (<tt>consteval</tt>)</td> 1058 <td><a href="https://wg21.link/p1073r3">P1073R3</a></td> 1059 <td class="none" align="center">No</td> 1060 </tr> 1061 <tr> 1062 <td><tt>std::is_constant_evaluated</tt></td> 1063 <td><a href="https://wg21.link/p0595r2">P0595R2</a></td> 1064 <td class="full" align="center">Clang 9</td> 1065 </tr> 1066 <tr> 1067 <td>Nested inline namespaces</td> 1068 <td><a href="https://wg21.link/p1094r2">P1094R2</a></td> 1069 <td class="full" align="center">Clang 8</td> 1070 </tr> 1071 <!-- Kona 2019 papers --> 1072 <tr> 1073 <td rowspan="2">Structured binding extensions</td> 1074 <td><a href="https://wg21.link/p1091r3">P1091R3</a></td> 1075 <td rowspan="2" class="partial" align="center">Partial</td> 1076 </tr> 1077 <tr> 1078 <td><a href="https://wg21.link/p1381r1">P1381R1</a></td> 1079 </tr> 1080 <tr> 1081 <td rowspan="2">Stronger Unicode requirements</td> 1082 <td><a href="https://wg21.link/p1041r4">P1041R4</a></td> 1083 <td rowspan="2" class="full" align="center">Yes</td> 1084 </tr> 1085 <tr> 1086 <td><a href="https://wg21.link/p1139r2">P1139R2</a></td> 1087 </tr> 1088 <tr> 1089 <td rowspan="2">Parenthesized initialization of aggregates</td> 1090 <td><a href="https://wg21.link/p0960r3">P0960R3</a></td> 1091 <td rowspan="2" class="none" align="center">No</td> 1092 </tr> 1093 <tr> <!-- from Belfast --> 1094 <td><a href="https://wg21.link/p1975r0">P1975R0</a></td> 1095 </tr> 1096 <tr> 1097 <td rowspan="6">Modules</td> 1098 <td><a href="https://wg21.link/p1103r3">P1103R3</a></td> 1099 <td class="partial" align="center">Partial</td> 1100 </tr> 1101 <tr> <!-- from Cologne --> 1102 <td><a href="https://wg21.link/p1766r1">P1766R1</a> (<a href="#dr">DR</a>)</td> 1103 <td rowspan="3" class="none" align="center">No</td> 1104 </tr> 1105 <tr> 1106 <td><a href="https://wg21.link/p1811r0">P1811R0</a></td> 1107 </tr> 1108 <tr> 1109 <td><a href="https://wg21.link/p1703r1">P1703R1</a></td> 1110 </tr> 1111 <tr> <!-- from Belfast --> 1112 <td><a href="https://wg21.link/p1874r1">P1874R1</a></td> 1113 <td class="partial" align="center">Partial</td> 1114 </tr> 1115 <tr> <!-- from Belfast --> 1116 <td><a href="https://wg21.link/p1979r0">P1979R0</a></td> 1117 <td class="none" align="center">No</td> 1118 </tr> 1119 <tr> 1120 <td>Coroutines</td> 1121 <td><a href="https://wg21.link/p0912r5">P0912R5</a></td> 1122 <td class="partial" align="center">Partial</td> 1123 </tr> 1124 <!-- Cologne 2019 papers --> 1125 <tr> 1126 <td>Deprecate <tt>a[b,c]</tt></td> 1127 <td><a href="https://wg21.link/p1161r3">P1161R3</a></td> 1128 <td class="full" align="center">Clang 9</td> 1129 </tr> 1130 <tr> 1131 <td>Deprecate some problematic uses of <tt>volatile</tt></td> 1132 <td><a href="https://wg21.link/p1152r4">P1152R4</a></td> 1133 <td class="svn" align="center">SVN</td> 1134 </tr> 1135 <tr> 1136 <td><tt>[[nodiscard("with reason")]]</tt></td> 1137 <td><a href="https://wg21.link/p1301r4">P1301R4</a></td> 1138 <td class="full" align="center">Clang 9</td> 1139 </tr> 1140 <tr> 1141 <td><tt>using enum</tt></td> 1142 <td><a href="https://wg21.link/p1099r5">P1099R5</a></td> 1143 <td class="none" align="center">No</td> 1144 </tr> 1145 <tr> 1146 <td>Class template argument deduction for aggregates</td> 1147 <td><a href="https://wg21.link/p1816r0">P1816R0</a></td> 1148 <td class="none" align="center">No</td> 1149 </tr> 1150 <tr> 1151 <td>Class template argument deduction for alias templates</td> 1152 <td><a href="https://wg21.link/p1814r0">P1814R0</a></td> 1153 <td class="none" align="center">No</td> 1154 </tr> 1155 <tr> 1156 <td>Permit conversions to arrays of unknown bound</td> 1157 <td><a href="https://wg21.link/p0388r4">P0388R4</a></td> 1158 <td class="none" align="center">No</td> 1159 </tr> 1160 <tr> 1161 <td><tt>constinit</tt></td> 1162 <td><a href="https://wg21.link/p1143r2">P1143R2</a></td> 1163 <td class="svn" align="center">SVN</td> 1164 </tr> 1165</table> 1166 1167<p> 1168<span id="p0482">(11): Prior to Clang 8, this feature is not enabled by 1169<tt>-std=c++20</tt>, but can be enabled with <tt>-fchar8_t</tt>. 1170</span> 1171</p> 1172</details> 1173 1174<h2 id="dr">Defect reports</h2> 1175 1176<p>Clang generally aims to implement resolutions to Defect Reports (bug fixes 1177against prior standards) retroactively, in all prior standard versions where 1178the fix is meaningful. Significant Defect Report changes to language features 1179after the publication of the relevant standard are marked (DR) in the above 1180table.</p> 1181 1182<p>Clang also has a test suite for conformance to resolutions for issues on the 1183<a href="http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_toc.html">C++ core issues list</a>, 1184most of which are considered Defect Reports. 1185<a href="cxx_dr_status.html">Implementation status for C++ core issues</a> based on 1186that test suite is tracked on a separate page.</p> 1187 1188<h2 id="ts">Technical specifications and standing documents</h2> 1189 1190<p>ISO C++ also publishes a number of documents describing additional language 1191and library features that are not part of standard C++.</p> 1192 1193<details open> 1194<summary>List of features and minimum Clang version with support</summary> 1195 1196<table width="689" border="1" cellspacing="0"> 1197 <tr> 1198 <th>Document</th> 1199 <th>Latest draft</th> 1200 <th>Compiler flag</th> 1201 <th>Available in Clang?</th> 1202 </tr> 1203 <tr id="sd6"> 1204 <td rowspan="7">SD-6: SG10 feature test recommendations</td> 1205 <td rowspan="7"><a href="https://isocpp.org/std/standing-documents/sd-6-sg10-feature-test-recommendations">SD-6</a></td> 1206 <td rowspan="7">N/A</td> 1207 <td class="full" align="center"> 1208 Clang 3.4 (<a href="https://wg21.link/n3745">N3745</a>)</br> 1209 </td> 1210 </tr> 1211 <tr> 1212 <td class="full" align="center"> 1213 Clang 3.6 (<a href="https://wg21.link/n4200">N4200</a>)</a> 1214 </td> 1215 </tr> 1216 <tr> 1217 <td class="full" align="center"> 1218 Clang 4 (<a href="https://wg21.link/p0096r3">P0096R3</a>)</a> 1219 </td> 1220 </tr> 1221 <tr> 1222 <td class="full" align="center"> 1223 Clang 5 (<a href="https://wg21.link/p0096r4">P0096R4</a>)</a> 1224 </td> 1225 </tr> 1226 <tr> 1227 <td class="full" align="center"> 1228 Clang 7 (<a href="https://wg21.link/p0096r5">P0096R5</a>)</a> 1229 </td> 1230 </tr> 1231 <tr> 1232 <td class="full" align="center"> 1233 Clang 9 (<a href="https://wg21.link/p1353r0">P1353R0</a>) 1234 </td> 1235 </tr> 1236 <tr> 1237 <td class="svn" align="center"> 1238 SVN (<a href="https://wg21.link/p1902r1">P1902R1</a>)</a> 1239 </td> 1240 </tr> 1241 <!-- No compiler support is known to be needed for: 1242 * Concurrency TS 1243 * Parallelism TS (v1, v2) 1244 * Ranges TS 1245 * Networking TS 1246 * File System TS 1247 --> 1248 <tr> 1249 <td>[TS] Concepts</td> 1250 <td><a href="https://wg21.link/p0121r0">P0121R0</a></td> 1251 <td></td> 1252 <td class="na" align="center">Superseded by <a href="#p0734">P0734R0</a></td> 1253 </tr> 1254 <tr> 1255 <!-- track unimplemented Coroutines features: p0913r1 p0914r1 p1356r0 --> 1256 <td rowspan="2">[TS] Coroutines</td> 1257 <td rowspan="2"><a href="https://isocpp.org/files/papers/N4663.pdf">N4663</a></td> 1258 <td><tt>-fcoroutines-ts<br>-stdlib=libc++</tt></td> 1259 <td class="full" align="center">Clang 5</td> 1260 </tr> 1261 <tr> 1262 <td><tt>-std=c++20<br>-stdlib=libc++</tt></td> 1263 <td class="na" align="center">Superseded by <a href="#p0912">P0912R5</a></td> 1264 </tr> 1265 <tr> 1266 <td>[TS] Library Fundamentals, Version 1 (invocation type traits)</td> 1267 <td><a href="https://wg21.link/n4480">N4480</a></td> 1268 <td>N/A</td> 1269 <td class="none" align="center">No</td> 1270 </tr> 1271 <tr> 1272 <td>[TS] Library Fundamentals, Version 2 (<tt>source_location</tt>)</td> 1273 <td><a href="https://wg21.link/n4617">N4617</a></td> 1274 <td>N/A</td> 1275 <td class="full" align="center">Clang 9 (<a href="docs/LanguageExtensions.html#source-location-builtins">documentation</a>)</td> 1276 </tr> 1277 <tr> 1278 <td>[TS] Modules</td> 1279 <td><a href="https://wg21.link/n4720">N4720</a></td> 1280 <td><tt>-fmodules-ts</tt></td> 1281 <td class="na" align="center">Superseded by <a href="#p1103">P1103R3</a></td> 1282 </tr> 1283 <tr> 1284 <td>[DRAFT TS] Reflection</td> 1285 <td><a href="https://wg21.link/n4746">N4746</a></td> 1286 <td></td> 1287 <td class="none" align="center">No</td> 1288 </tr> 1289 <tr> 1290 <td>[TS] Transactional Memory</td> 1291 <td><a href="https://wg21.link/n4514">N4514</a></td> 1292 <td></td> 1293 <td class="none" align="center">No</td> 1294 </tr> 1295</table> 1296</details> 1297 1298</div> 1299</body> 1300</html> 1301