For example:
- Code: Select all
Page::Ptr ptr = new Page("test");
will fail with following error:
- Code: Select all
"src/ExtJSTest.cpp", line 105: Error: Overloading ambiguity between "Poco::WebWidgets::Page::Page(const std::type_info&)" and "Poco::WebWidgets::Page::Page(const std::string &)".
The solution can be provided in two ways and neither pleases me entirely:
- 1) add Page(const char*) constructor - not good if we are aiming to get rid of plain pointers in the interface (although only the letter of the law is violated, not the spirit - pointer is only temporary means to an end and std::string copy is made immediately at construction time)
2) force users to do new Page(std::string("test")) - this is kindof pain and likely not to be done on compilers that do not require it, causing code to become non-portable
I am inclined to go with 1), but wanted to bounce the dilemma first. I'll do the coding and submit modifications.





