Repository navigation
Commit b60f304
valueFlowForwardLifetime: do not forward lifetime of non-local variable past end of function
For a global variable the scope body end is null so the lifetime was
forwarded through the rest of the file, into unrelated functions.
colobot restext.cpp: ValueFlow 615s => 5s.
In 10000 Debian packages (--check-level=exhaustive) this removes 11
false positives (danglingLifetime, objectIndex) and adds no warnings.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>1 parent 9074c47 commit b60f304
2 files changed
Lines changed: 14 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2007 | 2007 | | |
2008 | 2008 | | |
2009 | 2009 | | |
| 2010 | + | |
| 2011 | + | |
| 2012 | + | |
| 2013 | + | |
| 2014 | + | |
| 2015 | + | |
2010 | 2016 | | |
2011 | 2017 | | |
2012 | 2018 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
826 | 826 | | |
827 | 827 | | |
828 | 828 | | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
829 | 837 | | |
830 | 838 | | |
831 | 839 | | |
| |||
0 commit comments