C-family: Replace "may may" with "may" in warning message

gcc/c-family/

	* c-warn.c (warn_for_address_or_pointer_of_packed_member):
	Replace "may may" with "may" in warning message.

gcc/testsuite/

	* gcc.dg/pr51628-20.c: Updated.
	* gcc.dg/pr51628-21.c: Likewise.
	* gcc.dg/pr51628-25.c: Likewise.

From-SVN: r267904
This commit is contained in:
H.J. Lu 2019-01-13 12:53:47 +00:00 committed by H.J. Lu
parent 5f8865c358
commit 234c38181a
6 changed files with 15 additions and 4 deletions

View File

@ -1,3 +1,8 @@
2019-01-13 H.J. Lu <hongjiu.lu@intel.com>
* c-warn.c (warn_for_address_or_pointer_of_packed_member):
Replace "may may" with "may" in warning message.
2019-01-07 Jakub Jelinek <jakub@redhat.com>
PR c++/85052

View File

@ -2828,7 +2828,7 @@ warn_for_address_or_pointer_of_packed_member (bool convert_p, tree type,
location_t location = EXPR_LOC_OR_LOC (rhs, input_location);
warning_at (location, OPT_Waddress_of_packed_member,
"converting a packed %qT pointer (alignment %d) "
"to %qT (alignment %d) may may result in an "
"to %qT (alignment %d) may result in an "
"unaligned pointer value",
rhstype, rhs_align, type, type_align);
tree decl = TYPE_STUB_DECL (TREE_TYPE (rhstype));

View File

@ -1,3 +1,9 @@
2019-01-13 H.J. Lu <hongjiu.lu@intel.com>
* gcc.dg/pr51628-20.c: Updated.
* gcc.dg/pr51628-21.c: Likewise.
* gcc.dg/pr51628-25.c: Likewise.
2019-01-13 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/59345

View File

@ -8,4 +8,4 @@ struct C { struct B b; } __attribute__ ((packed));
extern struct C *p;
long* g8 (void) { return p; }
/* { dg-warning "may may result in an unaligned pointer value" "" { target *-*-* } .-1 } */
/* { dg-warning "may result in an unaligned pointer value" "" { target *-*-* } .-1 } */

View File

@ -8,4 +8,4 @@ struct C { struct B b; } __attribute__ ((packed));
extern struct C p[];
long* g8 (void) { return p; }
/* { dg-warning "may may result in an unaligned pointer value" "" { target *-*-* } .-1 } */
/* { dg-warning "may result in an unaligned pointer value" "" { target *-*-* } .-1 } */

View File

@ -6,4 +6,4 @@ struct B { int i; };
struct C { struct B b; } __attribute__ ((packed));
long* g8 (struct C *p) { return p; }
/* { dg-warning "may may result in an unaligned pointer value" "" { target *-*-* } .-1 } */
/* { dg-warning "may result in an unaligned pointer value" "" { target *-*-* } .-1 } */