param_filter: total re-write with bugfixes
I had re-written smatch_param_limit.c recently and wanted to re-write this
as well.
The problem is this wasn't parsing the following code correctly:
if (win->clipcount && !win->clips)
win->clipcount = 0;
if (win->clipcount > MAX_CLIPS)
win->clipcount = MAX_CLIPS;
At the first merge it says zero was set but the original filtered could be
any value, therefore there is no filter.
In the new code it says, "zero was set" the original filtered could be any
thing. But then it says "MAX_CLIPS" was set, the original value is
anything intersection with 0-16 so the original filtered is 0-16. This
uses the new pre_merge_hook()s that I introduced earlier.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>