Commit a6496605 by Mark Mitchell Committed by Mark Mitchell

c-commom.c (c_apply_type_quals_to_decl): REFERENCE_TYPES are always TREE_READONLY.

	* c-commom.c (c_apply_type_quals_to_decl): REFERENCE_TYPES are
	always TREE_READONLY.

From-SVN: r33500
parent d8b2fb52
2000-04-27 Mark Mitchell <mark@codesourcery.com>
* c-commom.c (c_apply_type_quals_to_decl): REFERENCE_TYPES are
always TREE_READONLY.
2000-04-27 Ulrich Drepper <drepper@cygnus.com>
* i386.h (FUNCTION_BLOCK_PROFILER_EXIT): Generate mem reference
......
......@@ -3217,7 +3217,9 @@ c_apply_type_quals_to_decl (type_quals, decl)
int type_quals;
tree decl;
{
if (type_quals & TYPE_QUAL_CONST)
if ((type_quals & TYPE_QUAL_CONST)
|| (TREE_TYPE (decl)
&& TREE_CODE (TREE_TYPE (decl)) == REFERENCE_TYPE))
TREE_READONLY (decl) = 1;
if (type_quals & TYPE_QUAL_VOLATILE)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment