This is the mail archive of the gcc@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]
Other format: [Raw text]

Re: question about if_marked construct


Tom de Vries <tjvries@xs4all.nl> writes:

> static int prop(const_tree type)
> {
>   return type == A;
> }
>
> static int type_hash_marked_p (const void *p) {
>  const_tree const type = ((const struct type_hash *) p)->type;
>  return ggc_marked_p (type) || prop (type);
> }

I would like to question your premise.  The gcc garbage collector is
not some general purpose library.  It's specifically for the use of
gcc.  Why, in gcc, would you want to write such an if_marked property?
Is there some simpler and clearer way to express what you actually
want to have happen?

Ian


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