aboutsummaryrefslogtreecommitdiff
path: root/gcc/stor-layout.c
diff options
context:
space:
mode:
authorJoseph Myers <jsm28@gcc.gnu.org>2005-07-02 11:55:32 +0100
committerJoseph Myers <jsm28@gcc.gnu.org>2005-07-02 11:55:32 +0100
commitdee158440e16ef7272d823b9bd5e6d414968fd8a (patch)
tree3bc7f52a01952579e89d69c80d985e655c418278 /gcc/stor-layout.c
parent77008252819720c987f11b3dade670e2b3ba09b8 (diff)
downloadgcc-dee158440e16ef7272d823b9bd5e6d414968fd8a.zip
gcc-dee158440e16ef7272d823b9bd5e6d414968fd8a.tar.gz
gcc-dee158440e16ef7272d823b9bd5e6d414968fd8a.tar.bz2
toplev.c (default_tree_printer): Handle setting location with '+' flag.
2005-07-02 Zack Weinberg <zack@codesourcery.com> Joseph S. Myers <joseph@codesourcery.com> * toplev.c (default_tree_printer): Handle setting location with '+' flag. * c-objc.common.c (c_tree_printer): Likewise. * c-format.c (gcc_diag_flag_specs): Add '+'. (gcc_cdiag_char_table): Allow '+' flag for tree formats. (format_types_orig): Allow '+' flag for gcc_diag and gcc_cdiag formats. * c-common.c, c-decl.c, c-objc-common.c, c-pragma.c, config/arm/pe.c, config/i386/winnt.c, config/ia64/ia64.c, config/mcore/mcore.c, config/sh/symbian.c, config/sol2.c, config/v850/v850.c, function.c, stor-layout.c, toplev.c, tree-inline.c, tree-optimize.c, tree.c, varasm.c: Use '+' flag instead of %J or %H. Use 'q' flag for quoting. Avoid '.' at end of diagnostics. Use %q+D not %s for a decl. Do not pass excess format arguments where %J is used without %D. cp: * error.c (location_of): Add comment. (locate_error, cp_error_at, cp_warning_at, cp_pedwarn_at): Remove. * cp-tree.h (cp_error_at, cp_warning_at, cp_pedwarn_at): Remove. * call.c, class.c, decl.c, decl2.c, friend.c, init.c, name-lookup.c, parser.c, pt.c, search.c, semantics.c, typeck.c, typeck2.c: Use '+' flag instead of %J, cp_error_at, cp_warning_at or cp_pedwarn_at. Mark up some diagnostic strings with N_. java: * class.c, decl.c, expr.c: Use '+' flag instead of %J. Use 'q' flag for quoting. objc: * objc-act.c: Use '+' flag instead of %J. Use 'q' flag for quoting. testsuite: * gcc.dg/format/gcc_diag-1.c: Update. From-SVN: r101532
Diffstat (limited to 'gcc/stor-layout.c')
-rw-r--r--gcc/stor-layout.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/gcc/stor-layout.c b/gcc/stor-layout.c
index 50228b7..a2d55a8 100644
--- a/gcc/stor-layout.c
+++ b/gcc/stor-layout.c
@@ -451,10 +451,10 @@ layout_decl (tree decl, unsigned int known_align)
int size_as_int = TREE_INT_CST_LOW (size);
if (compare_tree_int (size, size_as_int) == 0)
- warning (0, "%Jsize of %qD is %d bytes", decl, decl, size_as_int);
+ warning (0, "size of %q+D is %d bytes", decl, size_as_int);
else
- warning (0, "%Jsize of %qD is larger than %d bytes",
- decl, decl, larger_than_size);
+ warning (0, "size of %q+D is larger than %d bytes",
+ decl, larger_than_size);
}
}
@@ -851,11 +851,11 @@ place_field (record_layout_info rli, tree field)
if (TYPE_ALIGN (type) > desired_align)
{
if (STRICT_ALIGNMENT)
- warning (OPT_Wattributes, "%Jpacked attribute causes "
- "inefficient alignment for %qD", field, field);
+ warning (OPT_Wattributes, "packed attribute causes "
+ "inefficient alignment for %q+D", field);
else
- warning (OPT_Wattributes, "%Jpacked attribute is "
- "unnecessary for %qD", field, field);
+ warning (OPT_Wattributes, "packed attribute is "
+ "unnecessary for %q+D", field);
}
}
else
@@ -869,7 +869,7 @@ place_field (record_layout_info rli, tree field)
/* No, we need to skip space before this field.
Bump the cumulative size to multiple of field alignment. */
- warning (OPT_Wpadded, "%Jpadding struct to align %qD", field, field);
+ warning (OPT_Wpadded, "padding struct to align %q+D", field);
/* If the alignment is still within offset_align, just align
the bit position. */