extra: handle loops like: while (--i >= 0) {
commitef44898484280ea811139e3f9f13010b0cc34631
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 19 Jan 2018 13:28:15 +0000 (19 16:28 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Fri, 19 Jan 2018 13:28:15 +0000 (19 16:28 +0300)
tree44a88558996251629e030b08226b7bd5877ea92b
parentde329024a8f85292543c23747d9d42ccfe41a88c
extra: handle loops like: while (--i >= 0) {

Smatch has historically only handled while countdown loops like:

while (--i) {

This adds support for comparing against zero or another number.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
smatch_extra.c
validation/sm_loops6.c [new file with mode: 0644]