carydb
asked on
converting program from Rogue Wave tools.h++ to STL (UNIX platform)
I have begun to convert a program from using Rogue Wave tools to STL. My first step
is to change RWCString to string. I included the STL string header file (#include <string>) in my file. Without making any other changes I immediately got compiler errors.
"/opt/local/rogue/rw/rwtim e.h", line 396: Error: operator<=(const RWTime&, const RWTime&) already had a body defined.
"/opt/local/rogue/rw/rwtim e.h", line 396: Error: t1 is not defined.
"/opt/local/rogue/rw/rwtim e.h", line 396: Error: t2 is not defined.
"/opt/local/rogue/rw/rwtim e.h", line 396: Error: Badly formed expression.
"/opt/local/rogue/rw/rwtim e.h", line 396: Error: Badly formed expression.
"/opt/local/rogue/rw/rwtim e.h", line 400: Error: operator>=(const RWTime&, const RWTime&) already had a body defined.
"/opt/local/rogue/rw/rwtim e.h", line 400: Error: t1 is not defined.
"/opt/local/rogue/rw/rwtim e.h", line 400: Error: t2 is not defined.
"/opt/local/rogue/rw/rwtim e.h", line 400: Error: Badly formed expression.
"/opt/local/rogue/rw/rwtim e.h", line 400: Error: Badly formed expression.
My question is, How do I go about tracking down this problem? All I did was add the preprocessor command #include <string>
is to change RWCString to string. I included the STL string header file (#include <string>) in my file. Without making any other changes I immediately got compiler errors.
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
"/opt/local/rogue/rw/rwtim
My question is, How do I go about tracking down this problem? All I did was add the preprocessor command #include <string>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
try the same in that file.
if it worked then it is "only" a question
of the order of include files.
if it worked then it is "only" a question
of the order of include files.
ASKER
I did that in each of the files (listed the stl include at the end of the include sections.) It still fails. The include files that I have include each other here and there. Could that be part of the problem? The heaader files did not seem to care that #include </rw/cstring.h> is included in each of the header files.
ASKER
I had to work in several files, but it finally worked. Of coarse, there are new problems now. Your answer did solve my problem in this question, so I will accept it as the answer. Thanks much.
ASKER