On 09/28/2011 03:15 PM, Dodji Seketeli wrote:
+set_arg_token (macro_arg *arg, const cpp_token *token,
+ source_location location, size_t index,
+ enum macro_arg_token_kind kind,
+ bool track_macro_exp_p)
+{
+ const cpp_token **token_ptr;
+ source_location
On 09/27/2011 08:03 PM, Dodji Seketeli wrote:
Jason Merrill writes:
Yes, I was suggesting that you change that, since it's only used by
_get_location, which can get the location from the pointer instead.
Done.
And then you should be able to drop the track_macro_exp_p field from
macro_arg_
On 09/26/2011 10:21 AM, Dodji Seketeli wrote:
> > + /* The cpp_reader the macro comes from. */
> > + cpp_reader *pfile;
>
> This seems to only be used to decide whether or not to increment
> location_ptr. Rather than base that decision on going all the way
> back to the CPP_OPTION, le
On 09/21/2011 09:34 AM, Dodji Seketeli wrote:
Jason Merrill writes:
clobbering the last token when the buffer is full sounds like it's
unlikely to be what the caller wants; should we abort instead?
abort () added in that case.
Please update the comment as well.
+/* An iterator over toke
On 09/18/2011 06:47 AM, Dodji Seketeli wrote:
+cpp_hashnode *macro;
+
+ }c;
Extra blank line, missing space.
+/* Appends a token to the end of the token buffer BUFFER. Note that
+ this function doesn't enlarge BUFFER; it overwrite the last memory
+ location of BUFFER that holds a to
On 09/14/2011 04:50 AM, Dodji Seketeli wrote:
To comply with this invariant, the initial patch of Tom was cloning T
into T', and was using T'->src_loc to track the virtual location of T.
Which is close to what you are proposing, while respecting the
invariant.
Yes, that's what I had in mind. I
On 08/09/2011 10:54 AM, Dodji Seketeli wrote:
+ goto ftrack_macro_expansion_with_arg;
+
+case OPT_ftrack_macro_expansion_:
+ftrack_macro_expansion_with_arg:
Instead of the goto, just write /* Fall through. */
+consumption if necessary. Value @samp{0} of @var{level} de-activates