Version: (using KDE KDE 3.3.92) Installed from: Compiled From Sources Compiler: gcc 3.4.3 OS: Solaris I get this compile error: if g++ -DHAVE_CONFIG_H -I. -I. -I../.. -Idialogs -Irefactoring -I/opt/kde/include -I/opt/qt/include -I/gorbag/exta/cad/externals/SOLARIS/include -DQT_THREAD_SUPPORT -I/opt/kde/include -I/gorbag/exta/cad/externals/SOLARIS/include -I/opt/qt/include -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -DUSE_SOLARIS -DSVR4 -Wnon-virtual-dtor -Wno-long-long -Wundef -Wall -W -Wpointer-arith -Wwrite-strings -DNDEBUG -DNO_DEBUG -O2 -I/opt/kde/include -I/gorbag/exta/cad/externals/SOLARIS/include -I/opt/qt/include -O2 -fomit-frame-pointer -DNeedVarargsPrototypes=1 -DNeedFunctionPrototypes=1 -pipe -fno-exceptions -mcpu=ultrasparc -fno-exceptions -fno-check-new -fno-common -DQT_CLEAN_NAMESPACE -DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION -MT codegenerator.o -MD -MP -MF ".deps/codegenerator.Tpo" -c -o codegenerator.o codegenerator.cpp; \ then mv -f ".deps/codegenerator.Tpo" ".deps/codegenerator.Po"; else rm -f ".deps/codegenerator.Tpo"; exit 1; fi codegenerator.cpp: In member function `QString CodeGenerator::formatDoc(const QString&, const QString&, int)': codegenerator.cpp:685: error: `index' undeclared (first use this function) codegenerator.cpp:685: error: (Each undeclared identifier is reported only once for each functionit appears in.)
Adding #include <strings.h> fixes it
Whoa! This one's on me. Thanks for noticing.
CVS commit by okellogg: BUG:99697 - formatDoc(): Fix declaration of index. M +1 -1 ChangeLog 1.66 M +2 -1 umbrello/codegenerator.cpp 1.65 --- kdesdk/umbrello/ChangeLog #1.65:1.66 @@ -28,5 +28,5 @@ 92781 92995 93122 93219 93297 93298 93501 93535 93696 94173 94728 94795 94883 95082 95247 95252 95722 95924 95951 95954 -96216 96221 96964 97155 97182 97697 97887 97984 +96216 96221 96964 97155 97182 97697 97887 97984 98899 99697 Version 1.3 --- kdesdk/umbrello/umbrello/codegenerator.cpp #1.64:1.65 @@ -678,6 +678,7 @@ QString CodeGenerator::formatDoc(const Q continue; } + int index; do { - const int index = comment.findRev(" ", lineWidth + 1); + index = comment.findRev(" ", lineWidth + 1); output += linePrefix + input.left(index) + endLine; // add line input.remove(0, index + 1); //and remove processed string, including