analyzer: fix testsuite assumption that sizeof(int) > 2
authorDavid Malcolm <dmalcolm@redhat.com>
Mon, 3 Feb 2020 20:39:50 +0000 (15:39 -0500)
committerDavid Malcolm <dmalcolm@redhat.com>
Tue, 4 Feb 2020 15:48:58 +0000 (10:48 -0500)
commitc422cec54a5495f6f42b80f35a11c5508fe8eec3
treee5de29270d21eae6f6f0466a5b1b62ab2f089004
parent1dae549dccfec1edb0cb4e65feadc4722bb3bcc8
analyzer: fix testsuite assumption that sizeof(int) > 2

Fix some failures on xstormy16-elf:
  gcc.dg/analyzer/data-model-1.c  (test for warnings, line 595)
  gcc.dg/analyzer/data-model-1.c  (test for warnings, line 642)
  gcc.dg/analyzer/data-model-1.c  (test for warnings, line 690)
  gcc.dg/analyzer/data-model-1.c  (test for warnings, line 738)

due to:

warning: overflow in conversion from ‘long int’ to ‘int’ changes
  value from ‘100024’ to ‘-31048’ [-Woverflow]
    20 |   p[0].x = 100024;
       |            ^~~~~~

gcc/testsuite/ChangeLog:
* gcc.dg/analyzer/data-model-1.c (struct coord): Convert fields
from int to long.
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/analyzer/data-model-1.c