Issue 60956
Summary `-Wpointer-bool-conversion` not reported in macro
Labels new issue
Assignees
Reporter firewave
    ```cpp
#define cb(...) cb_(__VA_ARGS__)
#define cb2(x) cb_(x)
void cb_(bool);

int main() {
  int i;
  cb_(&i); // warning
  cb(&i); // no warning
 cb2(&i);
}
```

```
<source>:6:8: warning: address of 'i' will always evaluate to 'true' [-Wpointer-bool-conversion]
  cb_(&i);
  ~~~ ^
```

https://godbolt.org/z/3GovP6r3n
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to