http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53525

--- Comment #12 from jimis <jimis at gmx dot net> 2012-05-30 15:55:19 UTC ---
I should probably explain where the problem is and why I've left a memory leak.
In tokens_buff_new() I can't use XOBNEWVEC() instead of XNEWVEC() because it is
not guarded from the obstack_mark/release() calls in enter_macro_context() and
it messes up previously allocated objects when going back in the recursion. 

The thing I don't get and so I can't figure out a solution, is where the
virt_locs vector allocated inside tokens_buff_new() is freed. For example when
it is called from the path
cpp_get_token_1->paste_all_tokens->tokens_buff_new(), then when is the virt
locs vector actually freed?

Reply via email to