This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

C++ PATCH for dump/doc changes



This patch adds dumping support and documentation for RESULT_DECLs.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com

1999-09-25  Mark Mitchell  <mark@codesourcery.com>

	* dump.c (dequeue_and_dump): Handle RESULT_DECL.
	* ir.texi: Document RESULT_DECL and DECL_RESULT.

Index: ir.texi
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/cp/ir.texi,v
retrieving revision 1.6
diff -c -p -r1.6 ir.texi
*** ir.texi	1999/09/24 01:43:49	1.6
--- ir.texi	1999/09/25 18:14:31
*************** FIXME: Talk about @code{TYPE_NONCOPIED_P
*** 731,736 ****
--- 731,737 ----
  @tindex PARM_DECL
  @tindex FIELD_DECL
  @tindex NAMESPACE_DECL
+ @tindex RESULT_DECL
  @tindex TEMPLATE_DECL
  @tindex USING_DECL
  @findex DECL_INITIAL
*************** the constant is given by @code{DECL_INIT
*** 792,797 ****
--- 793,805 ----
  @code{INTEGER_CST} with the same type as the @code{TREE_TYPE} of the
  @code{CONST_DECL}, i.e., an @code{ENUMERAL_TYPE}.
  
+ @item RESULT_DECL
+ These nodes represent the value returned by a function.  When a value is
+ assigned to a @code{RESULT_DECL}, that indicates that the value should
+ be returned, via bitwise copy, by the function.  You can use
+ @code{DECL_SIZE} and @code{DECL_ALIGN} on a @code{RESULT_DECL}, just as
+ with a @code{VAR_DECL}.
+ 
  @item TYPE_DECL
  These nodes represent @code{typedef} declarations.  The @code{TREE_TYPE}
  is the type declared to have the name given by @code{DECL_NAME}.  In
*************** compute run-time type information, and s
*** 987,992 ****
--- 995,1003 ----
  This macro returns the @code{PARM_DECL} for the first argument to the
  function.  Subsequent @code{PARM_DECL} nodes can be obtained by
  following the @code{TREE_CHAIN} links.
+ 
+ @item DECL_RESULT
+ This macro returns the @code{RESULT_DECL} for the function.
  
  @item TREE_TYPE
  This macro returns the @code{FUNCTION_TYPE} or @code{METHOD_TYPE} for
Index: dump.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/cp/dump.c,v
retrieving revision 1.13
diff -c -p -r1.13 dump.c
*** dump.c	1999/09/21 20:32:44	1.13
--- dump.c	1999/09/25 18:14:39
*************** dequeue_and_dump (di)
*** 584,589 ****
--- 584,590 ----
      case VAR_DECL:
      case PARM_DECL:
      case FIELD_DECL:
+     case RESULT_DECL:
        if (dump_children_p)
  	{
  	  if (TREE_CODE (t) == PARM_DECL)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]