I'm trying to add some ADTs to corresponding vectors and test my toString() function. When I build the project, I get the compiler message --
That is just the first message for room.addShower(one);Code:1>c:\users\sterling\documents\visual studio 2008\projects\building\building\building.cpp(54) : error C2664: 'void Bathroom::addShower(Shower)' : cannot convert parameter 1 from 'Shower (__cdecl *)(void)' to 'Shower' 1> No constructor could take the source type, or constructor overload resolution was ambiguous
I get a message for each attempt to add.
My main code is just
I'm pretty lost when I read the compiler message, what is it trying to tell me?Code:Bathroom room; Shower one(); Shower two(); Stall three(); Stall four(); Stall five(); Mirror six(); Sink seven(); room.addShower(one); room.addShower(two); room.addStall(three); room.addStall(four); room.addStall(five); room.addMirror(six); room.addSink(seven); cout<<room.toString();




Reply With Quote