<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/115609>115609</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[Clang] Allow auto() as an extension in all language modes
</td>
</tr>
<tr>
<th>Labels</th>
<td>
clang:frontend
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
philnik777
</td>
</tr>
</table>
<pre>
Currently clang allows `auto()` casting only in C++23 and later. I don't think there is any reason to not support this as an extension all the way back to C++03, especially given that GCC does so already. This would allow us to replace `_LIBCPP_AUTO_CAST` with the appropriate language facility in a lot of places.
CC @AaronBallman
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxkUk9vnD4Q_TTmMgoyxsD6wIEl2p8i_aRGanqOBjwLbrw2sk22fPsKEjWVerEv8-bN-4MxmskRtaw6s-oxwzXNPrTLbKwzb03TZIPXW9uvIZBLdoPRopsArfX3CKzmuCbPxIkJxWoOI8Zk3ATe2Q2Mg56JMxNnUQI6DRYThRyeQHvHRJMgzca9QZopEJgI6DYIhNE7SB6cTxDXZfHhGIyA-wTQr0QuGu_2I3Ys3HGDAce3HfRJyEsmeqC40GjQ2g0m804O0owJ_ut70J4iRA9oA6HecnjZCe5-tfpDG6xxXxdosTjSLvT1_6dz__z82v14-fbad99fdr13k-bjBlyW4JdgMBHsDq04EVxxNNakwwkE6xP4KxwLY874I-Pd32_fA5O8w-DdGa29oYNMt6VWpcKM2qIpi6JuypPM5rYkpcdTpQclpTwpJYtGi6Ks6isOzcBlZlrBhSwKropKKilzrTgprjTWshlPdGWS0w2Nza19v-U-TJmJcaW2KKqaq8ziQDYerRDiyJyV3TV4l8hpJsTeldDu2IdhnSKT3JqY4te2ZJI9WtUf4OoRusPXr778k6f5iPSPfTevKWZrsO2c0hJZ2TFxYeIymTSvQz76GxOXnfDze1iC_0ljYuJyaIlMXD7lvLfidwAAAP__3Lzx1g">