<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/57199>57199</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Cannot insert breakpoints for lambda functions wrapped with a macro
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
saschanaz
</td>
</tr>
</table>
<pre>
On Windows:
```cpp
// macro.cpp
#include <stdio.h>
#include <Windows.h>
#define CALL(Lambda) Lambda();
int main(int argc, char **argv) {
CALL([]() {
printf("Hello world");
printf("Bye world");
});
}
```
With `clang -g macro.cpp` breakpoints can't be added to each `printf` call, and trying to do that on VSCode will instead add one at the end of the `main` block.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx1UsFunDAQ_RpzGQWBvUA4cEh2W_UQqYdKzdnYA7hxbGSbrNKv78DuqqRKJQtm_GbevBlP7_V7993Bs3HanyMTD6w4seL2rYvLUfN8veFf6cCrVMHnu1thnLKLRmDiGJM2Pp-Y-PIZeq20x29RGgfjEI4PT0-M3z_J115Lxlu4WffkMPG4zzIukRjjCFxNGUbF-BHUJAMwTqQPdPW2krDmmgi3Aqx6ZNXpQruHAeZAZMOG8G9orYezD1aTt1fwb-TjO_4njjWnD9LJ_TjffUvPJk2wztxKN8LduBt2XUAfUL7MnqpGUJL6bhL0CFJr1JA8oFRb9lUYZShp7ToT6SggvBsipTjtIU0ygXfw88fR09ucjbVgXEwo9cpHEPEmCkNAyvXDZhLlNvBVi_XqJc-wK-u6aKqqaXmmO6Fb0cosmWSxO0rnfFppMaQP4gcfwG4PC8PiVDLeRTgHOc_UyHmdgbx0ni3BdlNK87ad2_6NBC99rvwrOda-3X53c_C_UCVyTYwLRjKqpmzbbOrEoayqoT2oXvRc1HKoEYUelD4I5KrBzMoebezWreDc4Rk2ivUtq1NmOl5wXtyXTdkUoizzssBe9RUORd23AwUdCqS52HzVkfswZqHbJPXLGAm0Jqb4F5QxmtEhdpclzOSSJh-6KCOtrpO_s614t4n_A-S8FtQ">