[cfe-commits] Review: fix failing test
Ted Kremenek
kremenek at apple.com
Mon Feb 16 11:19:43 PST 2009
On Feb 16, 2009, at 11:15 AM, Ben Laurie wrote:
> This fixes a currently failing test by using the
> RangeConstraintManager.
These aren't broken tests; their just testing expected behavior. The
expected behavior is that BasicConstraintManager doesn't handle these
cases well.
>
> Index: test/Analysis/null-deref-ps.c
> ===================================================================
> --- test/Analysis/null-deref-ps.c (revision 64627)
> +++ test/Analysis/null-deref-ps.c (working copy)
> @@ -1,6 +1,6 @@
> -// RUN: clang -analyze -std=gnu99 -checker-simple -verify %s &&
> -// RUN: clang -analyze -std=gnu99 -checker-simple
> -analyzer-store-region -analyzer-purge-dead=false -verify %s &&
> -// RUN: clang -analyze -std=gnu99 -checker-cfref
> -analyzer-store-region -verify %s
> +// RUN: clang -analyze -analyzer-range-constraints -std=gnu99
> -checker-simple -verify %s &&
> +// RUN: clang -analyze -analyzer-range-constraints -std=gnu99
> -checker-simple -analyzer-store-region -analyzer-purge-dead=false
> -verify %s &&
> +// RUN: clang -analyze -analyzer-range-constraints -std=gnu99
> -checker-cfref -analyzer-store-region -verify %s
Please don't remove the RUN lines that invoke BasicConstraintManager.
We still wanted that tested. As we discussed via IM, please add the
separate RUN lines and #ifdef logic for the alternate warnings (some
comments in the test case are also good to explain the divergent
behavior).
More information about the cfe-commits
mailing list