[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread mwarshofsk at aol dot com
--- Comment #7 from mwarshofsk at aol dot com 2009-09-29 20:34 --- Comment 6 is perfect! That makes total sense. Thanks so much! Actually, I bet the Solaris compiler is implicitly treating this same code as a const & String behind the scenes. We'll just explicitly make that promise/fix f

[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread jakub at gcc dot gnu dot org
--- Comment #6 from jakub at gcc dot gnu dot org 2009-09-29 20:08 --- If the ctor isn't going to change it, you could as well change the argument type to const String & instead. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41508

[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread pinskia at gcc dot gnu dot org
--- Comment #5 from pinskia at gcc dot gnu dot org 2009-09-29 19:41 --- Yes GCC is correct as in C++ rvalues don't bind to references as only lvalues bind to references. -- pinskia at gcc dot gnu dot org changed: What|Removed |Added ---

[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread mwarshofsk at aol dot com
--- Comment #4 from mwarshofsk at aol dot com 2009-09-29 19:32 --- Here's the definition for that call ... I think you're on to something String get_job_title_mgmt_ind() const { return _jobTitleMgmtInd; }; When I change the constructor to "non reference" paramters it seems to compile f

[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread pinskia at gcc dot gnu dot org
--- Comment #3 from pinskia at gcc dot gnu dot org 2009-09-29 19:25 --- What type does get_job_title_mgmt_ind return? -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41508

[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread mwarshofsk at aol dot com
--- Comment #2 from mwarshofsk at aol dot com 2009-09-29 19:24 --- This is the method where I am receiving the compiler error: enum err_stat EJPeriod::rollup( List &src, List &dst, Date &startDt, Date &endDt ) { // then theres a bunch of code // and the

[Bug c++/41508] error: no matching function for call to ...

2009-09-29 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2009-09-29 19:15 --- Can you show the line where the call to EJPeriod::EJPeriod is done? It might be because String that you are passing is a rvalue which cannot be bound to String& as that would mean it needs to be bound to a lvalue.