Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/gcc.dg/format/ext-5.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 /* Test for gettext default attributes. */ | |
2 /* Origin: Joseph Myers <jsm28@cam.ac.uk> */ | |
3 /* { dg-do compile } */ | |
4 /* { dg-options "-std=gnu99 -Wformat" } */ | |
5 | |
6 #include "format.h" | |
7 | |
8 void | |
9 foo (int i, long l) | |
10 { | |
11 printf (gettext ("%d"), i); | |
12 printf (gettext ("%ld"), i); /* { dg-warning "format" "gettext" } */ | |
13 printf (dgettext ("", "%d"), i); | |
14 printf (dgettext ("", "%ld"), i); /* { dg-warning "format" "dgettext" } */ | |
15 printf (dcgettext ("", "%d", 0), i); | |
16 printf (dcgettext ("", "%ld", 0), i); /* { dg-warning "format" "dcgettext" } */ | |
17 } |