<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/152514>152514</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[LifetimeSafety] Add support for tracking temporaries
</td>
</tr>
<tr>
<th>Labels</th>
<td>
clang:memory-safety
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
usx95
</td>
</tr>
</table>
<pre>
`Temporary`: Detect a common bug where a reference is taken to a temporary object that is destroyed at the end of the full expression.
A warning for code such as `std::string_view sv = std::string("temporary string");`
This is noted as a lower priority since it is already detected by a pre-existing analysis.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJxcks2OpDoMhZ8mbKwqhYSfYsGCVqlWd3d7PwrEQKYDQbGpat5-FKZbLc0qkRPb5_OxIXLTitiK8k2U98zsPIfY7vTZlFkf7NGKSr7jsoVo4iEqKXQHd2QcGAwMYVnCCv0-wWvGiGAg4ogR1wHBEbD5wBU4gAH-rgGh_52yeTac_lgkjuFACyYFEXC1EMbzOu7eA35uEYlcWK8gZCdk18HLxNWtE4whwhAsAu3DDIZAVJLYCt0J3RFHt06_ng5fQE8Q-g7_vAl1E0r9SPuOKqEaod8S7tnwfXaUtK6Bk04CAz68MMIWXYiODyB3Ip9Exkc09gB7jgkt9AcY2CJe8NMRJ91mNf4gR1chu8y22ja6MRm2eV0WZV3pm87m1hZDnVfY1LapxyJXY9UMtZUab7KobaMy1yqpSnmTdV7kTaGvea6tsb2u-rxsKitFIXExzl-9fy7XEKfMEe3Y5qUq8yLzpkdPp_VKDd6sk9DdgkuIx4XMiHykUZT3LLapwKXfJxKF9I6YfkqyY3_uz39uRHYL_v83tbxDZy3Qvm0h8mkVRzN8JP7vkTukbI--nZk3Ss6oh1CPyfG899chLEI9Up-v47LFkHZHqMfJQUI9vlCerfoTAAD__yUo7EQ">