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]
Other format: [Raw text]

Re: [PATCH v3 of 03/14] C++: add location_t wrapper nodes during parsing (minimal impl)


On Tue, Jan 09, 2018 at 09:36:58AM -0500, Jason Merrill wrote:
> On 01/09/2018 06:53 AM, David Malcolm wrote:
> > +    case NON_LVALUE_EXPR:
> > +    case VIEW_CONVERT_EXPR:
> > +	{
> > +	  /* Handle location wrappers by substituting the wrapped node
> > +	     first,*then*  reusing the resulting type.  Doing the type
> > +	     first ensures that we handle template parameters and
> > +	     parameter pack expansions.  */
> > +	  gcc_assert (location_wrapper_p (t));
> > +	  tree op0 = tsubst_copy (TREE_OPERAND (t, 0), args, complain, in_decl);
> > +	  return build1 (code, TREE_TYPE (op0), op0);
> > +	}
> 
> Doesn't this lose the location information?

And the public_flag...

	Jakub


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