Use SET_DECL_MODE in libcc1

2017-07-05  Richard Sandiford  <richard.sandiford@linaro.org>

libcc1/
	* libcp1plugin.cc (plugin_build_field): Use SET_DECL_MODE.

From-SVN: r250004
This commit is contained in:
Richard Sandiford 2017-07-05 15:32:37 +00:00 committed by Richard Sandiford
parent b8506a8ac0
commit d8448c583e
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2017-07-05 Richard Sandiford <richard.sandiford@linaro.org>
* libcp1plugin.cc (plugin_build_field): Use SET_DECL_MODE.
2017-06-30 Nathan Sidwell <nathan@acm.org>
* libcp1plugin.cc (plugin_build_decl): Use make_conv_op_name.

View File

@ -1887,7 +1887,7 @@ plugin_build_field (cc1_plugin::connection *,
= c_build_bitfield_integer_type (bitsize, TYPE_UNSIGNED (field_type));
}
DECL_MODE (decl) = TYPE_MODE (TREE_TYPE (decl));
SET_DECL_MODE (decl, TYPE_MODE (TREE_TYPE (decl)));
// There's no way to recover this from DWARF.
SET_DECL_OFFSET_ALIGN (decl, TYPE_PRECISION (pointer_sized_int_node));