On 09/29/2015 12:29 PM, Richard Biener wrote:
I agree that obstacks are better here. Efficiency shouldn't matter here. But we're in C++ now so can't we statically construct the array with sth likeconst char *new_argv[] = { "objcopy", ... }; ? Thus have the compiler figure out the number of args. That would work for me as well.
The issue is that the code is about to be changed to conditionally pass certain arguments ("-v"), so you no longer have a fixed arglist.
Bernd