blob: 5f3757491ec4dcc6f9f4e0d4e7b25904c10f9b07 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
# assert-with-side-effects
Tries to find `Q_ASSERT`s with side-effects. Asserts are compiled-out in release mode so you shouldn't put any important code inside them.
#### Example
```
// The connect statement wouldn't run in release mode
Q_ASSERT(connect(buttonm, &QPushButton::clicked, this, &MainWindow::handleClick));
```
#### Pitfalls
As this is a level3 check, it will have many false positives and might be buggy. Patches accepted!
|