
El 17/02/2011 0:07, Howard Hinnant escribió:
On Feb 16, 2011, at 5:51 PM, Christopher Jefferson wrote:
No, with templates you only get to declare the default parameters once, so you must not put them on. if you do, including the real std header later doesn't compile.
Right.
Sorry for the mistake, it's a real pity that we can't use container predeclarations to declare something like: void func(const std::vector<int> &inputs);
The best way to address this issue is to bring it to the LWG. Bring performance impact measurements.
Yes. I think there is need for this, having to include a lot of std headers to declare a function with a std::string const reference as input parameter is a bit too much. In the meantime Boost could offer compiler-ABI-dependent predeclarations, but for standard predeclaration headers I think they should also offer default parameters. Best, Ion