id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 9329,Compilation fixes for Sun CC and its ancient standard library,vz-boost@…,Vladimir Prus,"This patch avoids the following errors when compiling the library using Sun CC (Sun C++ 5.10 SunOS_i386 2009/06/03): {{{ ""libs/program_options/src/options_description.cpp"", line 422: Error, nomatchoverin: Could not find a match for std::count(char*, char*, char) needed in::format_paragraph(std::ostream &, std::string, unsigned, unsigned). ""libs/program_options/src/options_description.cpp"", line ""libs/program_options/src/options_description.cpp"", line 483: Error, toofewtargs: Too few arguments for template std::reverse_iterator. ""/opt/sunstudio12.1/prod/include/CC/Cstd/rw/iterator"", line 426: Error, nofunctmpl: ""friend"" declaration is incompatible with function template. ""libs/program_options/src/options_description.cpp"", line 483: Where, temwhilespec: While specializing ""std::reverse_iterator"". ""libs/program_options/src/options_description.cpp"", line 483: Where, temspecend: Specialized in non-template code. ""libs/program_options/src/options_description.cpp"", line 484: Error, toofewtargs: Too few arguments for template std::reverse_iterator. 472: Error, nomatchoverin: Could not find a match for std::distance(const char*, const char*const) needed in::format_paragraph(std::ostream &, std::string, unsigned, unsigned). ""libs/program_options/src/value_semantic.cpp"", line 371: Error, nomatchoverin: Could not find a match for std::vector::vector(__rwstd::__rb_tree, std::less, std::allocator>::const_iterator, __rwstd::__rb_tree, std::less, std::allocator>::const_iterator) needed in boost::program_options::ambiguous_option::substitute_placeholders(const std::string &) const. }}} I don't really understand neither of them, unfortunately: looking at the standard library headers both the calls to `count()` and `distance()` should compile. OTOH neither of them is really necessary so I hope this patch can be applied nevertheless. With `reverse_iterator` it's more mysterious but, again, IMHO its use in the original code is not really needed, so I've just replaced it with `rfind()`. The last error is clear: this compiler standard library doesn't provide template ctor of `std::vector` from an iterator pair, so an alternative method of constructing it must be used. This does make the code less concise and elegant, but unfortunately I don't see any other way to make it work in this case. TIA!",Bugs,new,To Be Determined,program_options,Boost 1.54.0,Problem,,,