From: Eric Botcazou Date: Mon, 27 May 2019 11:12:57 +0000 (+0000) Subject: utils.c (maybe_pad_type): Issue the warning for the specific case of component types... X-Git-Tag: releases/gcc-9.2.0~310 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b8b0a7dc69cafa89ea320202d0f86bf06b237b8f;p=thirdparty%2Fgcc.git utils.c (maybe_pad_type): Issue the warning for the specific case of component types preferably. * gcc-interface/utils.c (maybe_pad_type): Issue the warning for the specific case of component types preferably. From-SVN: r271656 --- diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 9bfb21d3e76f..27cedf9c020e 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2019-05-27 Eric Botcazou + + * gcc-interface/utils.c (maybe_pad_type): Issue the warning for the + specific case of component types preferably. + 2019-05-27 Eric Botcazou * gcc-interface/trans.c (Identifier_to_gnu): Minor tweaks. diff --git a/gcc/ada/gcc-interface/utils.c b/gcc/ada/gcc-interface/utils.c index da4e1009e8c5..ab8b93abf5ff 100644 --- a/gcc/ada/gcc-interface/utils.c +++ b/gcc/ada/gcc-interface/utils.c @@ -1530,14 +1530,14 @@ built: generated for some other corresponding source entity. */ if (Comes_From_Source (gnat_entity)) { - if (Present (gnat_error_node)) - post_error_ne_tree ("{^ }bits of & unused?", - gnat_error_node, gnat_entity, - size_diffop (size, orig_size)); - else if (is_component_type) + if (is_component_type) post_error_ne_tree ("component of& padded{ by ^ bits}?", gnat_entity, gnat_entity, size_diffop (size, orig_size)); + else if (Present (gnat_error_node)) + post_error_ne_tree ("{^ }bits of & unused?", + gnat_error_node, gnat_entity, + size_diffop (size, orig_size)); } }