This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Document in tree.h for TREE_THIS_VOLATILE on a function decl
On Apr 8, 2005, at 2:08 PM, Jeffrey A Law wrote:
On Fri, 2005-04-08 at 13:31 -0400, Andrew Pinski wrote:
When looking into fixing PR fortran/17758, I noticed that nowhere says
that
TREE_THIS_VOLATILE on a function decl tells that the function does not
return.
So I added to comment about TREE_THIS_VOLATILE, about this fact.
OK?
Thanks,
Andrew Pinski
ChangeLog:
* tree.h (TREE_THIS_VOLATILE): Document the effect on a
function decl.
err, ummm,
What I had meant to say this is the same as the attribute noreturn which
still can return abnormally via exception (and via a non local goto).
What about the following:
Index: tree.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree.h,v
retrieving revision 1.711
diff -u -p -r1.711 tree.h
--- tree.h 6 Apr 2005 17:05:04 -0000 1.711
+++ tree.h 8 Apr 2005 18:16:43 -0000
@@ -916,6 +916,9 @@ extern void tree_operand_check_failed (i
its address should be of type `volatile WHATEVER *'.
In other words, the declared item is volatile qualified.
This is used in _DECL nodes and _REF nodes.
+ On a FUNCTION_DECL node, this means the function does not
+ return normally. This is the same effect as setting
+ the attribute noreturn on the function in C.
In a ..._TYPE node, means this type is volatile-qualified.
But use TYPE_VOLATILE instead of this macro when the node is a type,
Thanks,
Andrew Pinski