Ken-Patrick Lehrmann 61ccf888b3 Fix some false positives when the same expression at different places does not have the same value
Typically with
```
int F(int *f);
void F2(int *a, int *b) {
  int c = *a;
  F(a); // modifies *a
  if (b && c != *a) {}
}
```
we would get the following FP:
```
[test.cpp:3] -> [test.cpp:5]: (style) The comparison 'c != *a' is always false because 'c' and '*a' represent the same value.\n
```

I guess it boils down to isSameExpression only checking that the
expression is the same (in the above case, "*a" and "*a" are indeed the
same), but there's not real check on the values.
So the patch here is a bit hackish, and we still have false negatives in
cases with dereferenced pointers.
2020-07-11 14:13:18 +02:00
..
2019-06-29 07:49:14 +02:00
2019-06-29 07:49:14 +02:00
2020-06-13 16:37:12 +02:00
2020-05-10 11:16:32 +02:00
2019-02-09 07:24:06 +01:00
2020-05-10 11:16:32 +02:00
2020-06-17 17:06:06 -05:00
2020-05-10 11:16:32 +02:00
2020-05-10 11:16:32 +02:00
2020-06-13 16:37:12 +02:00
2020-06-13 16:37:12 +02:00
2019-02-09 07:24:06 +01:00
2020-05-10 11:16:32 +02:00
2020-05-10 11:16:32 +02:00
2020-05-10 11:16:32 +02:00
2019-02-09 07:24:06 +01:00
2020-05-10 11:16:32 +02:00
2020-05-10 11:16:32 +02:00
2020-05-10 11:16:32 +02:00
2019-06-29 07:49:14 +02:00
2020-06-13 16:37:12 +02:00
2020-06-13 16:37:12 +02:00
2020-05-23 07:16:49 +02:00
2019-02-09 07:24:06 +01:00
2019-02-09 07:24:06 +01:00
2020-05-10 11:16:32 +02:00
2020-05-10 11:16:32 +02:00
2020-06-13 16:37:12 +02:00
2020-05-10 11:16:32 +02:00
2020-06-13 16:37:12 +02:00
2019-03-16 09:17:50 +01:00
2020-05-25 16:02:34 +02:00