[gcc-python-plugin] cpychecker: FormatStringError -> FormatStringWarning in 3 places
by David Hugh Malcolm
commit 8da67e040d597fe2f4b8c6f3b5690366bb154277
Author: David Malcolm <dmalcolm(a)redhat.com>
Date: Thu Mar 1 17:12:44 2012 -0500
cpychecker: FormatStringError -> FormatStringWarning in 3 places
79e8350b07ed99b5fb01584249e5ee3fbafcbed8 changed FormatStringError to
FormatStringWarning, but in 3 places in the code there were try/except
clauses using the old spelling. Fix them
libcpychecker/refcounts.py | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/libcpychecker/refcounts.py b/libcpychecker/refcounts.py
index eed2ec9..55fdf7c 100644
--- a/libcpychecker/refcounts.py
+++ b/libcpychecker/refcounts.py
@@ -879,7 +879,7 @@ class CPython(Facet):
try:
fmt = PyArgParseFmt.from_string(fmt_string, with_size_t)
_handle_successful_parse(fmt)
- except FormatStringError:
+ except FormatStringWarning:
pass
return self.state.make_transitions_for_fncall(stmt, fnmeta,
@@ -1097,7 +1097,7 @@ class CPython(Facet):
fmt = PyBuildValueFmt.from_string(fmt_string, with_size_t)
if not _handle_successful_parse(fmt):
return [t_failure]
- except FormatStringError:
+ except FormatStringWarning:
pass
return [t_success, t_failure]
@@ -2306,7 +2306,7 @@ class CPython(Facet):
fmt = PyBuildValueFmt.from_string(fmt_string, with_size_t)
if not _handle_successful_parse(fmt):
return [t_failure]
- except FormatStringError:
+ except FormatStringWarning:
pass
return [t_success, t_failure]
12 years, 3 months
[gcc-python-plugin] misc/fedora: fix missing commit
by David Hugh Malcolm
commit 16ecf8968932cb3aab50d4fe49bf45f1e023dc26
Author: David Malcolm <dmalcolm(a)redhat.com>
Date: Thu Mar 1 16:10:01 2012 -0500
misc/fedora: fix missing commit
misc/fedora/mass-rebuild.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/misc/fedora/mass-rebuild.py b/misc/fedora/mass-rebuild.py
index a4dc7ad..f9b49ab 100644
--- a/misc/fedora/mass-rebuild.py
+++ b/misc/fedora/mass-rebuild.py
@@ -243,8 +243,8 @@ if 1:
resultdir = get_result_dir(srpmpath)
if not os.path.exists(resultdir):
local_rebuild_of_srpm_in_mock(srpmpath, MOCK_CONFIG)
- generate_index_html(resultdir, 'Errors seen in %s' % resultdir)
- prepare_bug_report(srpmpath)
+ index = Index(resultdir, 'Errors seen in %s' % resultdir)
+ prepare_bug_report(srpmpath, index)
break
# TODO:
12 years, 3 months
[gcc-python-plugin] misc/fedora: rework how we inject the plugin within the mass rebuild
by David Hugh Malcolm
commit 0f24ff0089328c74c2d097fd48bced9809323a0c
Author: David Malcolm <dmalcolm(a)redhat.com>
Date: Wed Feb 29 17:03:48 2012 -0500
misc/fedora: rework how we inject the plugin within the mass rebuild
Previously, I attempted to run the plugin by adding the necessary flags to
the __global_cflags macro.
However, this doesn't work for packages that don't use these build flags,
sometimes for the whole build, sometimes for just subsets of the build.
So instead, move /usr/bin/gcc to /usr/bin/the-real-gcc, and copy a harness
to /usr/bin/gcc; with similar changes for /usr/bin/g++
Hopefully this should make *everything* use the plugin during the mass rebuild
misc/fedora/fake-g++.py | 59 +++++++++++++++++++++++++++++++++++++++++++
misc/fedora/fake-gcc.py | 59 +++++++++++++++++++++++++++++++++++++++++++
misc/fedora/mass-rebuild.py | 20 ++++----------
3 files changed, 124 insertions(+), 14 deletions(-)
---
diff --git a/misc/fedora/fake-g++.py b/misc/fedora/fake-g++.py
new file mode 100755
index 0000000..f12dbef
--- /dev/null
+++ b/misc/fedora/fake-g++.py
@@ -0,0 +1,59 @@
+#!/usr/bin/env python
+# Copyright 2012 David Malcolm <dmalcolm(a)redhat.com>
+# Copyright 2012 Red Hat, Inc.
+#
+# This is free software: you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see
+# <http://www.gnu.org/licenses/>.
+
+# Harness for forcibly invoking GCC with the cpychecker Python code within the python
+# plugin
+#
+# This code assumes that it is /usr/bin/g++ and that the real GCC has been
+# moved to /usr/bin/the-real-g++
+#
+# (This code runs under the regular Python interpreter, not within gcc)
+
+import subprocess
+import sys
+
+# Enable the refcount-checker when running via this script
+#
+# We would use the regular keyword argument syntax:
+# verify_refcounting=True
+# but unfortunately gcc's option parser seems to not be able to cope with '='
+# within an option's value. So we do it using dictionary syntax instead:
+cmd = 'from libcpychecker import main; main(**{"verify_refcounting":True})'
+
+args = ['the-real-g++',
+ '-fplugin=python2',
+ '-fplugin-arg-python2-command=%s' % cmd]
+args += sys.argv[1:] # (the args we didn't consume)
+
+# Beware of quoting: if the command is quoted within the Popen call, then
+# Python interprets it as a string literal, and does nothing.
+#
+# But if invoking from a shell, you need quotes aroung the command
+#
+# To add to the fun, "gcc -v" emits it in unquoted form,
+# which will need quotes added
+
+if 0:
+ print(' '.join(args))
+p = subprocess.Popen(args)
+
+try:
+ r = p.wait()
+except KeyboardInterrupt:
+ r = 1
+sys.exit(r)
diff --git a/misc/fedora/fake-gcc.py b/misc/fedora/fake-gcc.py
new file mode 100755
index 0000000..c2eb395
--- /dev/null
+++ b/misc/fedora/fake-gcc.py
@@ -0,0 +1,59 @@
+#!/usr/bin/env python
+# Copyright 2012 David Malcolm <dmalcolm(a)redhat.com>
+# Copyright 2012 Red Hat, Inc.
+#
+# This is free software: you can redistribute it and/or modify it
+# under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see
+# <http://www.gnu.org/licenses/>.
+
+# Harness for forcibly invoking GCC with the cpychecker Python code within the python
+# plugin
+#
+# This code assumes that it is /usr/bin/gcc and that the real GCC has been
+# moved to /usr/bin/the-real-gcc
+#
+# (This code runs under the regular Python interpreter, not within gcc)
+
+import subprocess
+import sys
+
+# Enable the refcount-checker when running via this script
+#
+# We would use the regular keyword argument syntax:
+# verify_refcounting=True
+# but unfortunately gcc's option parser seems to not be able to cope with '='
+# within an option's value. So we do it using dictionary syntax instead:
+cmd = 'from libcpychecker import main; main(**{"verify_refcounting":True})'
+
+args = ['the-real-gcc',
+ '-fplugin=python2',
+ '-fplugin-arg-python2-command=%s' % cmd]
+args += sys.argv[1:] # (the args we didn't consume)
+
+# Beware of quoting: if the command is quoted within the Popen call, then
+# Python interprets it as a string literal, and does nothing.
+#
+# But if invoking from a shell, you need quotes aroung the command
+#
+# To add to the fun, "gcc -v" emits it in unquoted form,
+# which will need quotes added
+
+if 0:
+ print(' '.join(args))
+p = subprocess.Popen(args)
+
+try:
+ r = p.wait()
+except KeyboardInterrupt:
+ r = 1
+sys.exit(r)
diff --git a/misc/fedora/mass-rebuild.py b/misc/fedora/mass-rebuild.py
index c929daa..a4dc7ad 100644
--- a/misc/fedora/mass-rebuild.py
+++ b/misc/fedora/mass-rebuild.py
@@ -112,26 +112,18 @@ def local_rebuild_of_srpm_in_mock(srpmpath, mockcfg):
# FIXME: ^^ this will need changing
run_mock(['--copyin', module, HACKED_PATH])
- # Locate existing __global_cflags so that we can prepend our flags to it:
- out, err = run_mock(['--chroot', 'rpm --eval "%{__global_cflags}"'],
- captureOut=True)
- global_cflags = out.strip()
- # print('global_cflags: %r' % global_cflags)
-
- # Create script within chroot:
- SCRIPT_PATH='/test.py'
- run_mock(['--copyin', 'test.py', SCRIPT_PATH])
+ # Override the real gcc/g++ with our fake ones, which add the necessary flags
+ # and then invokes the real one:
+ run_mock(['--chroot', 'mv /usr/bin/gcc /usr/bin/the-real-gcc'])
+ run_mock(['--chroot', 'mv /usr/bin/g++ /usr/bin/the-real-g++'])
+ run_mock(['--copyin', 'fake-gcc.py', '/usr/bin/gcc'])
+ run_mock(['--copyin', 'fake-g++.py', '/usr/bin/g++'])
# Rebuild src.rpm, using the script:
run_mock(['--rebuild', srpmpath,
'--no-clean',
- # setting revised cflags so as to use the script:
- # FIXME: calling this repeatedly with --init disabled leads to
- # an accumulation of multiple copies of our flags at the front of __global_cflags
- ('--define=__global_cflags -fplugin=python2 -fplugin-arg-python2-script=%s %s'
- % (SCRIPT_PATH, global_cflags))
])
# Extract build logs:
12 years, 3 months
[gcc-python-plugin] cpychecker: improve the description when splitting ranges
by David Hugh Malcolm
commit ca0a1930241de22df9e99475c77d42a301e26928
Author: David Malcolm <dmalcolm(a)redhat.com>
Date: Thu Mar 1 14:51:29 2012 -0500
cpychecker: improve the description when splitting ranges
When splitting a range, rather than emitting descriptions with the rather
vague "value", such as:
"when considering range: 1 <= value <= 0x7fffffff"
instead try to embed a descriptive name for the value, such as:
"when considering range: 1 <= n <= 0x7fffffff"
Doing so requires adding an rhsdesc argument to various AbstractValue methods,
changing the signature of AbstractValue.eval_binop from:
def eval_binop(self, exprcode, rhs, gcctype, loc):
to:
def eval_binop(self, exprcode, rhs, rhsdesc, gcctype, loc):
and of AbstractValue.eval_comparison from:
def eval_comparison(self, opname, rhs):
to:
def eval_comparison(self, opname, rhs, rhsdesc):
libcpychecker/absinterp.py | 54 +++++++++++---------
libcpychecker/refcounts.py | 12 ++--
.../division-by-zero/possible/stdout.txt | 4 +-
.../arithmetic/negative-shift/possible/stdout.txt | 4 +-
.../ConcreteValue-eq-max-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-eq-min-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-ge-min-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-gt-max-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-le-max-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-le-min-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-lt-min-of-WithinRange/stdout.txt | 4 +-
.../ConcreteValue-lt-two-value-range/stdout.txt | 4 +-
tests/cpychecker/absinterp/two-loops/stdout.txt | 6 +-
.../PyList_Append/incorrect-loop/stderr.txt | 4 +-
.../PyList_Append/incorrect-loop/stdout.txt | 18 +++---
tests/cpychecker/refcounts/loop_n_times/stdout.txt | 8 ++--
.../loops/complex-loop-conditional-1/stderr.txt | 4 +-
.../loops/complex-loop-conditional-1/stdout.txt | 18 +++---
.../uninitialized_data/comparison/stderr.txt | 16 +++---
.../uninitialized_data/comparison/stdout.txt | 4 +-
.../uninitialized_data/function_arg/stderr.txt | 16 +++---
.../uninitialized_data/function_arg/stdout.txt | 4 +-
22 files changed, 104 insertions(+), 100 deletions(-)
---
diff --git a/libcpychecker/absinterp.py b/libcpychecker/absinterp.py
index d7ecb89..756b3ba 100644
--- a/libcpychecker/absinterp.py
+++ b/libcpychecker/absinterp.py
@@ -234,11 +234,11 @@ class AbstractValue(object):
raise NotImplementedError("Don't know how to cope with exprcode: %r (%s) on %s at %s"
% (exprcode, exprcode, self, loc))
- def eval_binop(self, exprcode, rhs, gcctype, loc):
+ def eval_binop(self, exprcode, rhs, rhsdesc, gcctype, loc):
raise NotImplementedError
@dump_comparison
- def eval_comparison(self, opname, rhs):
+ def eval_comparison(self, opname, rhs, rhsdesc):
"""
opname is a string in opnames
Return a boolean, or None (meaning we don't know)
@@ -319,11 +319,11 @@ class UnknownValue(AbstractValue):
def eval_unary_op(self, exprcode, gcctype, loc):
return UnknownValue.make(gcctype, loc)
- def eval_binop(self, exprcode, rhs, gcctype, loc):
+ def eval_binop(self, exprcode, rhs, rhsdesc, gcctype, loc):
return UnknownValue.make(gcctype, loc)
@dump_comparison
- def eval_comparison(self, opname, rhs):
+ def eval_comparison(self, opname, rhs, rhsdesc):
if opname == 'eq':
# If it's the *same* value, it's equal to itself:
if self is rhs:
@@ -474,7 +474,7 @@ class ConcreteValue(AbstractValue):
raise NotImplementedError("Don't know how to cope with exprcode: %r (%s) on %s at %s"
% (exprcode, exprcode, self, loc))
- def eval_binop(self, exprcode, rhs, gcctype, loc):
+ def eval_binop(self, exprcode, rhs, rhsdesc, gcctype, loc):
if isinstance(rhs, ConcreteValue):
newvalue = eval_binop(exprcode, self.value, rhs.value, rhs)
if newvalue is not None:
@@ -482,7 +482,7 @@ class ConcreteValue(AbstractValue):
return UnknownValue.make(gcctype, loc)
@dump_comparison
- def eval_comparison(self, opname, rhs):
+ def eval_comparison(self, opname, rhs, rhsdesc):
log('ConcreteValue.eval_comparison(%s, %s%s)', self, opname, rhs)
if isinstance(rhs, ConcreteValue):
return raw_comparison(self.value, opname, rhs.value)
@@ -508,7 +508,7 @@ class ConcreteValue(AbstractValue):
rhs.loc,
self.value+1,
rhs.maxvalue))
- rhs.raise_split(*ranges)
+ rhs.raise_split(rhsdesc, *ranges)
# For everything else (inequalities), consider ranges:
self_vs_min = raw_comparison(self.value, opname, rhs.minvalue)
@@ -618,7 +618,7 @@ class ConcreteValue(AbstractValue):
if debug_comparisons:
from pprint import pprint
pprint(ranges)
- rhs.raise_split(*[roc.rng for roc in ranges])
+ rhs.raise_split(rhsdesc, *[roc.rng for roc in ranges])
return None
def extract_from_parent(self, region, gcctype, loc):
@@ -743,7 +743,7 @@ class WithinRange(AbstractValue):
raise NotImplementedError("Don't know how to cope with exprcode: %r (%s) on %s at %s"
% (exprcode, exprcode, self, loc))
- def eval_binop(self, exprcode, rhs, gcctype, loc):
+ def eval_binop(self, exprcode, rhs, rhsdesc, gcctype, loc):
if isinstance(rhs, ConcreteValue):
values = [eval_binop(exprcode, val, rhs.value, rhs)
for val in (self.minvalue, self.maxvalue)]
@@ -759,7 +759,7 @@ class WithinRange(AbstractValue):
zero_range = WithinRange.make(rhs.gcctype, rhs.loc, 0)
gt_zero_range = WithinRange.make(rhs.gcctype, rhs.loc,
1, rhs.maxvalue)
- rhs.raise_split(zero_range, gt_zero_range)
+ rhs.raise_split(rhsdesc, zero_range, gt_zero_range)
# Avoid negative shifts:
# (see https://fedorahosted.org/gcc-python-plugin/ticket/14 )
@@ -769,7 +769,7 @@ class WithinRange(AbstractValue):
rhs.minvalue, -1)
ge_zero_range = WithinRange.make(rhs.gcctype, rhs.loc,
0, rhs.maxvalue)
- rhs.raise_split(neg_range, ge_zero_range)
+ rhs.raise_split(rhsdesc, neg_range, ge_zero_range)
values = (eval_binop(exprcode, self.minvalue, rhs.minvalue, rhs),
eval_binop(exprcode, self.minvalue, rhs.maxvalue, rhs),
@@ -785,7 +785,7 @@ class WithinRange(AbstractValue):
return self.minvalue <= rawvalue and rawvalue <= self.maxvalue
@dump_comparison
- def eval_comparison(self, opname, rhs):
+ def eval_comparison(self, opname, rhs, rhsdesc):
log('WithinRange.eval_comparison(%s, %s%s)', self, opname, rhs)
# If it's the *same* value, it's equal to itself:
@@ -805,22 +805,25 @@ class WithinRange(AbstractValue):
if isinstance(rhs, ConcreteValue):
# to implement WithinRange op ConcreteValue, use:
# ConcreteValue flip(op) WithinRange
- return rhs.eval_comparison(flip_opname(opname), self)
+ return rhs.eval_comparison(flip_opname(opname), self, None)
return None
- def raise_split(self, *new_ranges):
+ def raise_split(self, valuedesc, *new_ranges):
"""
Raise a SplitValue exception to subdivide this range into subranges
"""
descriptions = []
+ if valuedesc is None:
+ valuedesc = 'value'
for r in new_ranges:
if isinstance(r, WithinRange):
- descriptions.append('when considering range: %s <= value <= %s' %
+ descriptions.append('when considering range: %s <= %s <= %s' %
(value_to_str(r.minvalue),
+ valuedesc,
value_to_str(r.maxvalue)))
elif isinstance(r, ConcreteValue):
- descriptions.append('when considering value == %s' % r)
+ descriptions.append('when considering %s == %s' % (valuedesc, r))
else:
raise TypeError('unrecognized type: %r' % r)
raise SplitValue(self, new_ranges, descriptions)
@@ -875,7 +878,7 @@ class PointerToRegion(AbstractValue):
def __repr__(self):
return 'PointerToRegion(gcctype=%r, loc=%r, region=%r)' % (str(self.gcctype), self.loc, self.region)
- def eval_comparison(self, opname, rhs):
+ def eval_comparison(self, opname, rhs, rhsdesc):
log('PointerToRegion.eval_comparison:(%s, %s%s)', self, opname, rhs)
if opname == 'eq':
@@ -2332,7 +2335,8 @@ class State(object):
# so that we can split the new state:
eqzero = v_returnval.eval_comparison(
'lt',
- ConcreteValue.from_int(0))
+ ConcreteValue.from_int(0),
+ None)
if eqzero is True:
# Mark the global exception state (with an arbitrary
# error):
@@ -2415,27 +2419,27 @@ class State(object):
'comparison against uninitialized data (%s)' % expr_rhs)
if exprcode == gcc.EqExpr:
- result = lhs.eval_comparison('eq', rhs)
+ result = lhs.eval_comparison('eq', rhs, expr_rhs)
if result is not None:
return result
elif exprcode == gcc.NeExpr:
- result = lhs.eval_comparison('eq', rhs)
+ result = lhs.eval_comparison('eq', rhs, expr_rhs)
if result is not None:
return not result
elif exprcode == gcc.LtExpr:
- result = lhs.eval_comparison('lt', rhs)
+ result = lhs.eval_comparison('lt', rhs, expr_rhs)
if result is not None:
return result
elif exprcode == gcc.LeExpr:
- result = lhs.eval_comparison('le', rhs)
+ result = lhs.eval_comparison('le', rhs, expr_rhs)
if result is not None:
return result
elif exprcode == gcc.GeExpr:
- result = lhs.eval_comparison('ge', rhs)
+ result = lhs.eval_comparison('ge', rhs, expr_rhs)
if result is not None:
return result
elif exprcode == gcc.GtExpr:
- result = lhs.eval_comparison('gt', rhs)
+ result = lhs.eval_comparison('gt', rhs, expr_rhs)
if result is not None:
return result
@@ -2484,7 +2488,7 @@ class State(object):
'usage of uninitialized data (%s) on right-hand side of %s'
% (stmt.rhs[0], stmt.exprcode.get_symbol()))
try:
- c = a.eval_binop(stmt.exprcode, b, stmt.lhs.type, stmt.loc)
+ c = a.eval_binop(stmt.exprcode, b, rhs[1], stmt.lhs.type, stmt.loc)
check_isinstance(c, AbstractValue)
return c
except NotImplementedError:
diff --git a/libcpychecker/refcounts.py b/libcpychecker/refcounts.py
index 98fcab0..eed2ec9 100644
--- a/libcpychecker/refcounts.py
+++ b/libcpychecker/refcounts.py
@@ -160,7 +160,7 @@ class RefcountValue(AbstractValue):
def __repr__(self):
return 'RefcountValue(%i, %i)' % (self.relvalue, self.min_external)
- def eval_binop(self, exprcode, rhs, gcctype, loc):
+ def eval_binop(self, exprcode, rhs, rhsdesc, gcctype, loc):
if isinstance(rhs, ConcreteValue):
if exprcode == gcc.PlusExpr:
return RefcountValue(self.relvalue + rhs.value, self.min_external)
@@ -168,7 +168,7 @@ class RefcountValue(AbstractValue):
return RefcountValue(self.relvalue - rhs.value, self.min_external)
return UnknownValue.make(gcctype, loc)
- def eval_comparison(self, opname, rhs):
+ def eval_comparison(self, opname, rhs, rhsdesc):
"""
opname is a string in opnames
Return a boolean, or None (meaning we don't know)
@@ -407,7 +407,7 @@ class CPython(Facet):
s_new.cpython.dec_ref(v_pyobjectptr, stmt.loc)
v_ob_refcnt = s_new.cpython.get_refcount(v_pyobjectptr, stmt)
# print('ob_refcnt: %r' % v_ob_refcnt)
- eq_zero = v_ob_refcnt.eval_comparison('eq', ConcreteValue.from_int(1))
+ eq_zero = v_ob_refcnt.eval_comparison('eq', ConcreteValue.from_int(1), None)
# print('eq_zero: %r' % eq_zero)
if eq_zero or eq_zero is None:
# tri-state; it might be zero:
@@ -3196,7 +3196,7 @@ class CPython(Facet):
# Because of the way we store RefcountValue instances, we can't
# easily prove that the refcount == 1, so only follow this path
# if we can prove that refcount != 1
- eq_one = v_ob_refcnt.eval_comparison('eq', ConcreteValue.from_int(1))
+ eq_one = v_ob_refcnt.eval_comparison('eq', ConcreteValue.from_int(1), None)
if eq_one is False: # tri-state
# FIXME: Py_XDECREF on newitem
s_failure = self.state.mkstate_concrete_return_of(stmt, -1)
@@ -3214,8 +3214,8 @@ class CPython(Facet):
v_op.region,
'ob_size')
- lt_zero = v_i.eval_comparison('lt', ConcreteValue.from_int(0))
- lt_size = v_i.eval_comparison('lt', v_ob_size)
+ lt_zero = v_i.eval_comparison('lt', ConcreteValue.from_int(0), None)
+ lt_size = v_i.eval_comparison('lt', v_ob_size, None)
# The above could be None: signifying that we don't know, and that
# False is possible. Out-of-range is possible if either aren't known
# to be non-False:
diff --git a/tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/stdout.txt b/tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/stdout.txt
index 0827766..458048b 100644
--- a/tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/stdout.txt
+++ b/tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering value == (unsigned int)0 from tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/input.c:28'
+ 'when considering j == (unsigned int)0 from tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/input.c:28'
error: PredictedArithmeticError()
error: possible integer division or modulo by zero with right-hand-side (unsigned int)0 from tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/input.c:28
Exception:
@@ -8,7 +8,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= j <= 0xffffffff'
'returning'
Return value:
repr(): WithinRange(gcctype='unsigned int', loc=gcc.Location(file='tests/cpychecker/absinterp/arithmetic/division-by-zero/possible/input.c', line=30), minvalue=0, maxvalue=0x7fffffff)
diff --git a/tests/cpychecker/absinterp/arithmetic/negative-shift/possible/stdout.txt b/tests/cpychecker/absinterp/arithmetic/negative-shift/possible/stdout.txt
index 1049936..ce7cfc6 100644
--- a/tests/cpychecker/absinterp/arithmetic/negative-shift/possible/stdout.txt
+++ b/tests/cpychecker/absinterp/arithmetic/negative-shift/possible/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering range: -0x80000000 <= value <= -1'
+ 'when considering range: -0x80000000 <= j <= -1'
error: PredictedArithmeticError()
error: possible negative shift count with right-hand-side (int)val [-0x80000000 <= val <= -1] from tests/cpychecker/absinterp/arithmetic/negative-shift/possible/input.c:29
Exception:
@@ -8,7 +8,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 0 <= value <= 0x7fffffff'
+ 'when considering range: 0 <= j <= 0x7fffffff'
'returning'
Return value:
repr(): WithinRange(gcctype='int', loc=gcc.Location(file='tests/cpychecker/absinterp/arithmetic/negative-shift/possible/input.c', line=31), minvalue=-0x80000000, maxvalue=0x7fffffff)
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-max-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-max-of-WithinRange/stdout.txt
index 4c6bfe0..e303329 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-max-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-max-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering range: 0 <= value <= 0xfffffffe'
+ 'when considering range: 0 <= j.0 <= 0xfffffffe'
'taking False path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering value == (const unsigned int)0xffffffff from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-max-of-WithinRange/input.c:22'
+ 'when considering j.0 == (const unsigned int)0xffffffff from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-max-of-WithinRange/input.c:22'
'taking True path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-min-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-min-of-WithinRange/stdout.txt
index 35efdf5..9063ec0 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-min-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-min-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering value == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-min-of-WithinRange/input.c:22'
+ 'when considering j.1 == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-eq-min-of-WithinRange/input.c:22'
'taking True path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= j.1 <= 0xffffffff'
'taking False path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-ge-min-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-ge-min-of-WithinRange/stdout.txt
index d1c39c2..6bed1dc 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-ge-min-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-ge-min-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering value == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-ge-min-of-WithinRange/input.c:22'
+ 'when considering j.1 == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-ge-min-of-WithinRange/input.c:22'
'taking True path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= j.1 <= 0xffffffff'
'taking False path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-gt-max-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-gt-max-of-WithinRange/stdout.txt
index d9d20c1..8095b64 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-gt-max-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-gt-max-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering range: 0 <= value <= 0xfffffffe'
+ 'when considering range: 0 <= j.0 <= 0xfffffffe'
'taking True path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering value == (const unsigned int)0xffffffff from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-gt-max-of-WithinRange/input.c:22'
+ 'when considering j.0 == (const unsigned int)0xffffffff from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-gt-max-of-WithinRange/input.c:22'
'taking False path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-max-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-max-of-WithinRange/stdout.txt
index d958954..4a13352 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-max-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-max-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering range: 0 <= value <= 0xfffffffe'
+ 'when considering range: 0 <= j.0 <= 0xfffffffe'
'taking False path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering value == (const unsigned int)0xffffffff from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-max-of-WithinRange/input.c:22'
+ 'when considering j.0 == (const unsigned int)0xffffffff from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-max-of-WithinRange/input.c:22'
'taking True path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-min-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-min-of-WithinRange/stdout.txt
index e2e162a..d71d561 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-min-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-min-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering value == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-min-of-WithinRange/input.c:22'
+ 'when considering j.1 == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-le-min-of-WithinRange/input.c:22'
'taking False path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= j.1 <= 0xffffffff'
'taking True path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-min-of-WithinRange/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-min-of-WithinRange/stdout.txt
index ed506cc..8d21f10 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-min-of-WithinRange/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-min-of-WithinRange/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering value == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-min-of-WithinRange/input.c:22'
+ 'when considering j.1 == (const unsigned int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-min-of-WithinRange/input.c:22'
'taking False path'
'returning'
Return value:
@@ -11,7 +11,7 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= j.1 <= 0xffffffff'
'taking True path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/stdout.txt b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/stdout.txt
index d8c8aaa..d3d20af 100644
--- a/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/stdout.txt
+++ b/tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/stdout.txt
@@ -15,7 +15,7 @@ Trace 1:
'taking False path'
'when considering range: 0 <= value <= 1'
'taking False path'
- 'when considering value == (int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/input.c:23'
+ 'when considering j == (int)0 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/input.c:23'
'taking False path'
'returning'
Return value:
@@ -30,7 +30,7 @@ Trace 2:
'taking False path'
'when considering range: 0 <= value <= 1'
'taking False path'
- 'when considering value == (int)1 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/input.c:23'
+ 'when considering j == (int)1 from tests/cpychecker/absinterp/comparisons/boundaries/ConcreteValue-lt-two-value-range/input.c:23'
'taking True path'
'returning'
Return value:
diff --git a/tests/cpychecker/absinterp/two-loops/stdout.txt b/tests/cpychecker/absinterp/two-loops/stdout.txt
index 0a8574b..dc1669a 100644
--- a/tests/cpychecker/absinterp/two-loops/stdout.txt
+++ b/tests/cpychecker/absinterp/two-loops/stdout.txt
@@ -1,6 +1,6 @@
Trace 0:
Transitions:
- 'when considering range: -0x80000000 <= value <= 0'
+ 'when considering range: -0x80000000 <= len <= 0'
'taking False path'
'taking False path'
'returning'
@@ -9,9 +9,9 @@ Trace 0:
Trace 1:
Transitions:
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= len <= 0x7fffffff'
'taking True path'
- 'when considering value == (int)1 from tests/cpychecker/absinterp/two-loops/input.c:27'
+ 'when considering len == (int)1 from tests/cpychecker/absinterp/two-loops/input.c:27'
'taking False path'
'taking True path'
'taking False path'
diff --git a/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stderr.txt b/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stderr.txt
index 2d19aba..7ed49e8 100644
--- a/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stderr.txt
+++ b/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stderr.txt
@@ -7,7 +7,7 @@ tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:41:nn: note: new
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:34:nn: note: when PyList_New() succeeds at: list = PyList_New(0);
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:35:nn: note: taking False path at: if (!list) {
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: reaching: for (i = 0; i < n; i++) {
-tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: when considering range: 1 <= value <= 0x7fffffff at: for (i = 0; i < n; i++) {
+tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: when considering range: 1 <= n <= 0x7fffffff at: for (i = 0; i < n; i++) {
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: taking True path at: for (i = 0; i < n; i++) {
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:41:nn: note: reaching: item = item_ctor();
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:41:nn: note: when item_ctor() succeeds at: item = item_ctor();
@@ -19,7 +19,7 @@ tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:47:nn: note: ob_
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:47:nn: note: '*item' is now referenced by 1 non-stack value(s): PyListObject.ob_item[0]
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:47:nn: note: taking False path at: if (PyList_Append(list, item)) {
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: reaching: for (i = 0; i < n; i++) {
-tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: when considering value == (int)1 from tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:29 at: for (i = 0; i < n; i++) {
+tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: when considering n == (int)1 from tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:29 at: for (i = 0; i < n; i++) {
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:38:nn: note: taking False path at: for (i = 0; i < n; i++) {
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:59:nn: note: reaching: return list;
tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:60:nn: note: returning
diff --git a/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stdout.txt b/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stdout.txt
index 99d0991..ab17aae 100644
--- a/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stdout.txt
+++ b/tests/cpychecker/refcounts/PyList_Append/incorrect-loop/stdout.txt
@@ -2,7 +2,7 @@ Trace 0:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: -0x80000000 <= value <= 0'
+ 'when considering range: -0x80000000 <= n <= 0'
'taking False path'
'returning'
Return value:
@@ -17,13 +17,13 @@ Trace 1:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() succeeds'
'taking False path'
'when PyList_Append() succeeds'
'taking False path'
- 'when considering value == (int)1 from tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:29'
+ 'when considering n == (int)1 from tests/cpychecker/refcounts/PyList_Append/incorrect-loop/input.c:29'
'taking False path'
'returning'
Return value:
@@ -43,7 +43,7 @@ Trace 2:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() succeeds'
'taking False path'
@@ -72,7 +72,7 @@ Trace 3:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() succeeds'
'taking False path'
@@ -102,7 +102,7 @@ Trace 4:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() succeeds'
'taking False path'
@@ -132,7 +132,7 @@ Trace 5:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() succeeds'
'taking False path'
@@ -163,7 +163,7 @@ Trace 6:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() fails'
'taking True path'
@@ -184,7 +184,7 @@ Trace 7:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= n <= 0x7fffffff'
'taking True path'
'when item_ctor() fails'
'taking True path'
diff --git a/tests/cpychecker/refcounts/loop_n_times/stdout.txt b/tests/cpychecker/refcounts/loop_n_times/stdout.txt
index 6ae249f..13bcfd3 100644
--- a/tests/cpychecker/refcounts/loop_n_times/stdout.txt
+++ b/tests/cpychecker/refcounts/loop_n_times/stdout.txt
@@ -6,7 +6,7 @@ Trace 0:
'taking False path'
'when PyLong_FromLong() succeeds'
'taking False path'
- 'when considering range: -0x80000000 <= value <= 0'
+ 'when considering range: -0x80000000 <= count.1 <= 0'
'taking False path'
'when taking True path'
'returning'
@@ -41,7 +41,7 @@ Trace 1:
'taking False path'
'when PyLong_FromLong() succeeds'
'taking False path'
- 'when considering range: -0x80000000 <= value <= 0'
+ 'when considering range: -0x80000000 <= count.1 <= 0'
'taking False path'
'when taking False path'
'calling tp_dealloc on PyLongObject allocated at tests/cpychecker/refcounts/loop_n_times/input.c:42'
@@ -77,10 +77,10 @@ Trace 2:
'taking False path'
'when PyLong_FromLong() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= count.1 <= 0x7fffffff'
'taking True path'
'PyList_SetItem() succeeds'
- 'when considering value == (int)1 from tests/cpychecker/refcounts/loop_n_times/input.c:34'
+ 'when considering count.1 == (int)1 from tests/cpychecker/refcounts/loop_n_times/input.c:34'
'taking False path'
'taking True path'
'returning'
diff --git a/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stderr.txt b/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stderr.txt
index d9ea4d4..7867018 100644
--- a/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stderr.txt
+++ b/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stderr.txt
@@ -7,7 +7,7 @@ tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:39:nn: note:
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:33:nn: note: when PyList_New() succeeds at: result = PyList_New(0);
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:34:nn: note: taking False path at: if (!result) {
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: reaching: for (i = 0; i < unknown_unsigned_val; i++) {
-tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: when considering range: 1 <= value <= 0xffffffff at: for (i = 0; i < unknown_unsigned_val; i++) {
+tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff at: for (i = 0; i < unknown_unsigned_val; i++) {
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: taking True path at: for (i = 0; i < unknown_unsigned_val; i++) {
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:39:nn: note: reaching: PyObject *item = make_item(i);
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:39:nn: note: when make_item() succeeds at: PyObject *item = make_item(i);
@@ -19,7 +19,7 @@ tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:43:nn: note:
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:43:nn: note: '*item' is now referenced by 1 non-stack value(s): PyListObject.ob_item[0]
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:43:nn: note: taking False path at: if (-1 == PyList_Append(result, item)) {
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: reaching: for (i = 0; i < unknown_unsigned_val; i++) {
-tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: when considering value == (const unsigned int)1 from tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:22 at: for (i = 0; i < unknown_unsigned_val; i++) {
+tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: when considering unknown_unsigned_val.1 == (const unsigned int)1 from tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:22 at: for (i = 0; i < unknown_unsigned_val; i++) {
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:38:nn: note: taking False path at: for (i = 0; i < unknown_unsigned_val; i++) {
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:57:nn: note: reaching: return result;
tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:62:nn: note: returning
diff --git a/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stdout.txt b/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stdout.txt
index 2d0a020..53522f4 100644
--- a/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stdout.txt
+++ b/tests/cpychecker/refcounts/loops/complex-loop-conditional-1/stdout.txt
@@ -2,7 +2,7 @@ Trace 0:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering value == (const unsigned int)0 from tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:22'
+ 'when considering unknown_unsigned_val.1 == (const unsigned int)0 from tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:22'
'taking False path'
'returning'
Return value:
@@ -27,13 +27,13 @@ Trace 1:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() succeeds'
'taking False path'
'when PyList_Append() succeeds'
'taking False path'
- 'when considering value == (const unsigned int)1 from tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:22'
+ 'when considering unknown_unsigned_val.1 == (const unsigned int)1 from tests/cpychecker/refcounts/loops/complex-loop-conditional-1/input.c:22'
'taking False path'
'returning'
Return value:
@@ -63,7 +63,7 @@ Trace 2:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() succeeds'
'taking False path'
@@ -103,7 +103,7 @@ Trace 3:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() succeeds'
'taking False path'
@@ -144,7 +144,7 @@ Trace 4:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() succeeds'
'taking False path'
@@ -185,7 +185,7 @@ Trace 5:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() succeeds'
'taking False path'
@@ -227,7 +227,7 @@ Trace 6:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() fails'
'taking True path'
@@ -259,7 +259,7 @@ Trace 7:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0xffffffff'
+ 'when considering range: 1 <= unknown_unsigned_val.1 <= 0xffffffff'
'taking True path'
'when make_item() fails'
'taking True path'
diff --git a/tests/cpychecker/refcounts/uninitialized_data/comparison/stderr.txt b/tests/cpychecker/refcounts/uninitialized_data/comparison/stderr.txt
index fcdf027..e79bacc 100644
--- a/tests/cpychecker/refcounts/uninitialized_data/comparison/stderr.txt
+++ b/tests/cpychecker/refcounts/uninitialized_data/comparison/stderr.txt
@@ -1,9 +1,9 @@
tests/cpychecker/refcounts/uninitialized_data/comparison/input.c: In function 'test':
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41:5: warning: comparison against uninitialized data (item) at tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41 [enabled by default]
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:34:12: note: when PyList_New() succeeds at: result = PyList_New(len);
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:35:8: note: taking False path at: if (!result) {
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:39:12: note: reaching: for (i = 0; i < len; i++) {
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:39:5: note: when considering range: 1 <= value <= 0x7fffffff at: for (i = 0; i < len; i++) {
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:39:5: note: taking True path at: for (i = 0; i < len; i++) {
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41:5: note: reaching: if (!item) {
-tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:29:1: note: graphical error report for function 'test' written out to 'tests/cpychecker/refcounts/uninitialized_data/comparison/input.c.test-refcount-errors.html'
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41:nn: warning: comparison against uninitialized data (item) at tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41 [enabled by default]
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:34:nn: note: when PyList_New() succeeds at: result = PyList_New(len);
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:35:nn: note: taking False path at: if (!result) {
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:39:nn: note: reaching: for (i = 0; i < len; i++) {
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:39:nn: note: when considering range: 1 <= len <= 0x7fffffff at: for (i = 0; i < len; i++) {
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:39:nn: note: taking True path at: for (i = 0; i < len; i++) {
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41:nn: note: reaching: if (!item) {
+tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:29:nn: note: graphical error report for function 'test' written out to 'tests/cpychecker/refcounts/uninitialized_data/comparison/input.c.test-refcount-errors.html'
diff --git a/tests/cpychecker/refcounts/uninitialized_data/comparison/stdout.txt b/tests/cpychecker/refcounts/uninitialized_data/comparison/stdout.txt
index a87540e..fd615a5 100644
--- a/tests/cpychecker/refcounts/uninitialized_data/comparison/stdout.txt
+++ b/tests/cpychecker/refcounts/uninitialized_data/comparison/stdout.txt
@@ -2,7 +2,7 @@ Trace 0:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: -0x80000000 <= value <= 0'
+ 'when considering range: -0x80000000 <= len <= 0'
'taking False path'
'returning'
Return value:
@@ -17,7 +17,7 @@ Trace 1:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= len <= 0x7fffffff'
'taking True path'
error: UsageOfUninitializedData()
error: comparison against uninitialized data (item) at tests/cpychecker/refcounts/uninitialized_data/comparison/input.c:41
diff --git a/tests/cpychecker/refcounts/uninitialized_data/function_arg/stderr.txt b/tests/cpychecker/refcounts/uninitialized_data/function_arg/stderr.txt
index 320cce5..6129dba 100644
--- a/tests/cpychecker/refcounts/uninitialized_data/function_arg/stderr.txt
+++ b/tests/cpychecker/refcounts/uninitialized_data/function_arg/stderr.txt
@@ -1,9 +1,9 @@
tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c: In function 'test':
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41:16: warning: passing uninitialized data (item) as argument 3 to function at tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41 [enabled by default]
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:34:12: note: when PyList_New() succeeds at: result = PyList_New(len);
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:35:8: note: taking False path at: if (!result) {
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:39:12: note: reaching: for (i = 0; i < len; i++) {
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:39:5: note: when considering range: 1 <= value <= 0x7fffffff at: for (i = 0; i < len; i++) {
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:39:5: note: taking True path at: for (i = 0; i < len; i++) {
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41:16: note: reaching: PyList_SetItem(result, i, item);
-tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:29:1: note: graphical error report for function 'test' written out to 'tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c.test-refcount-errors.html'
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41:nn: warning: passing uninitialized data (item) as argument 3 to function at tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41 [enabled by default]
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:34:nn: note: when PyList_New() succeeds at: result = PyList_New(len);
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:35:nn: note: taking False path at: if (!result) {
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:39:nn: note: reaching: for (i = 0; i < len; i++) {
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:39:nn: note: when considering range: 1 <= len <= 0x7fffffff at: for (i = 0; i < len; i++) {
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:39:nn: note: taking True path at: for (i = 0; i < len; i++) {
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41:nn: note: reaching: PyList_SetItem(result, i, item);
+tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:29:nn: note: graphical error report for function 'test' written out to 'tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c.test-refcount-errors.html'
diff --git a/tests/cpychecker/refcounts/uninitialized_data/function_arg/stdout.txt b/tests/cpychecker/refcounts/uninitialized_data/function_arg/stdout.txt
index b099161..b2ccc9d 100644
--- a/tests/cpychecker/refcounts/uninitialized_data/function_arg/stdout.txt
+++ b/tests/cpychecker/refcounts/uninitialized_data/function_arg/stdout.txt
@@ -2,7 +2,7 @@ Trace 0:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: -0x80000000 <= value <= 0'
+ 'when considering range: -0x80000000 <= len <= 0'
'taking False path'
'returning'
Return value:
@@ -17,7 +17,7 @@ Trace 1:
Transitions:
'when PyList_New() succeeds'
'taking False path'
- 'when considering range: 1 <= value <= 0x7fffffff'
+ 'when considering range: 1 <= len <= 0x7fffffff'
'taking True path'
error: UsageOfUninitializedData()
error: passing uninitialized data (item) as argument 3 to function at tests/cpychecker/refcounts/uninitialized_data/function_arg/input.c:41
12 years, 3 months