<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/55388>55388</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
usage of moved variable in same function call not detected by clang-tidy when function takes rvalue
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
firewave
</td>
</tr>
</table>
<pre>
```cpp
#include <list>
extern void func(std::list<int>&&, std::list<int>); // remove "&&" for the warning to appear
extern std::list<int> func2(const std::list<int>&);
static void f(std::list<int>l)
{
func(std::move(l), func2(l));
l.size(); // bugprone-use-after-move detected
}
```
https://godbolt.org/z/oYEP37nYc
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx1Uk2ToyAQ_TV46UpKQY05eJhJZs97nSNCq-wSsADNZn79Ikk2M1Mbq9Xu6q_3HnRWXlpS51cT00TyI8lfCGXKCD1LBMIOWvlA2Nstlb74J6AzsFgloZ-NILTxQRL2Eu1aflAmNdE62QGe5feEvQKhP6KBw5Nd4k5K730UeusgjAhn7owyAwQLfJqQuy9I_j89YYuzGmGND08h1FcUnwn6wIMSN4JP2em18dq1u7VDfL4rspKKcaqOStxBXePH5rVVb736WIu_CtPNw-Sswc3sccP7SHmTlJIYUASUdxDHm3M_0c-UxhAmvwJKIwcrO6vD1rohRh_xte9vP9nOvItMtkzu2Z5nQQWN7ez5gGB7WFdKWLhTvNMIKsrOT5j4BGUNCK41GBv-wYLuAkJzM2yCkhc4j2ge1YH_Rg9u4XrGbHa6_QZQhXHutsKeYqD1cv9tohC_4vQYKu9n9NGpKtY02dg2eVVT0THWiV4WHe1oVZaNKAtZy1JWZaZ5h9q3pHqNV8vgGdKI9b5Vx0y1NKc0r4qiaPI93W3rmsqqyPdljrzmRU-ic-JKb1ccq3KZaxOkeDw-Jte74R9J7r0aDGJaF-fzOYzWtb1yeOYLZml3m7D_BdY6ESw">