On Jul 28, 2014, at 5:14 PM, H.J. Lu <hongjiu...@intel.com> wrote: > wide-int change introduced C++ templates in header file, like > > generic_wide_int<fixed_wide_int_storage<int_traits<T1>::precision>> > > create_user_defined_type in gengtype.c calls
Hum… In the original wide-int, the templates where less beefy; the code worked because the types were simple enough. gengtype isn’t meant to do all of C++, and certainly this is the type of code that shows why parsing C++ on the fly when you heart isn’t into it can lead to problems. Then someone wanted to make more use of the power of C++, not realizing the existing landmine present. Ah… one for the books. google("strtok considered harmful”) So, I never use strtok (usually), and now I know exactly why; it just isn’t composable. So the replacement looks fine, though, if a strspn style person wants to comment on it further, that’d be nice. It was new supposedly in BSD 4.3… kinda new, but, likely that’s reasonably old enough now to not matter now. I use newlib to test my cross with a native build of gcc under simulation and newlib has it, so I’m happy. Ok.