Fix gcc.dg/cold-1.c
2017-10-09 Tom de Vries <tom@codesourcery.com> * gcc.dg/cold-1.c (foo1): Fix warning line number. Make warning line number relative. (abort): Declare. From-SVN: r253537
This commit is contained in:
parent
86a6f91eec
commit
b7807e11c4
2 changed files with 8 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
2017-10-09 Tom de Vries <tom@codesourcery.com>
|
||||
|
||||
* gcc.dg/cold-1.c (foo1): Fix warning line number. Make warning line
|
||||
number relative.
|
||||
(abort): Declare.
|
||||
|
||||
2017-10-08 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
* gcc.c-torture/execute/20171008-1.c: New test.
|
||||
|
|
|
@ -1,11 +1,12 @@
|
|||
/* { dg-do compile { target nonpic } } */
|
||||
/* { dg-options "-O2 -Wsuggest-attribute=cold" } */
|
||||
|
||||
extern void abort (void);
|
||||
extern void do_something_interesting_and_never_return ();
|
||||
|
||||
int
|
||||
foo1(int a)
|
||||
{ /* { dg-warning "cold" "detect cold candidate" { target *-*-* } "8" } */
|
||||
{ /* { dg-warning "cold" "detect cold candidate" { target *-*-* } ".-1" } */
|
||||
if (a)
|
||||
abort ();
|
||||
else
|
||||
|
|
Loading…
Add table
Reference in a new issue