X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0a1bce698f68b0fe06178128895c54275dd3e5bb..c5453c7956e115a1e7290f01cbbd730a5d8f3448:/utils/ifacecheck/src/ifacecheck.cpp diff --git a/utils/ifacecheck/src/ifacecheck.cpp b/utils/ifacecheck/src/ifacecheck.cpp index 78abbe78ec..13aca6a97e 100644 --- a/utils/ifacecheck/src/ifacecheck.cpp +++ b/utils/ifacecheck/src/ifacecheck.cpp @@ -75,12 +75,11 @@ class IfaceCheckLog : public wxLog public: IfaceCheckLog() {} - void DoLog(wxLogLevel, const wxString& msg, time_t) + virtual void DoLogText(const wxString& msg) { // send all messages to stdout (normal behaviour is to sent them to stderr) - wxPrintf(msg); - wxPrintf("\n"); - Flush(); + wxPuts(msg); + fflush(stdout); } }; @@ -154,16 +153,12 @@ int IfaceCheckApp::OnRun() // in any case set basic std preprocessor #defines: m_doxyInterface.AddPreprocessorValue("NULL", "0"); - //g_bLogEnabled = false; - // parse the two XML files which contain the real and the doxygen interfaces // for wxWidgets API: if (!m_gccInterface.Parse(parser.GetParam(0)) || !m_doxyInterface.Parse(parser.GetParam(1))) return 1; -// g_bLogEnabled = true; - if (parser.Found(DUMP_SWITCH)) { wxLogMessage("Dumping real API to '%s'...", API_DUMP_FILE); @@ -219,7 +214,9 @@ bool IfaceCheckApp::Compare() interfaces.GetCount()); if (!m_strToMatch.IsEmpty()) + { wxLogMessage("Processing only header files matching '%s' expression.", m_strToMatch); + } for (unsigned int i=0; iGetHeader(), &m, &tmp)) + { wxLogMessage("Adjusted attributes of '%s' method", m.GetAsString()); + } proceed = false; break; @@ -394,7 +397,7 @@ int IfaceCheckApp::CompareClasses(const wxClass* iface, const wxClass* api) for (unsigned int j=0; jGetAsString(true, true, true, true); - wxLogWarning(warning); + wxLogWarning("%s", warning); count++; if (overloads.GetCount()>1) @@ -402,7 +405,9 @@ int IfaceCheckApp::CompareClasses(const wxClass* iface, const wxClass* api) // TODO: decide which of these overloads is the most "similar" to m // and eventually modify it if (m_modify) + { wxLogWarning("\tmanual fix is required"); + } } else { @@ -494,7 +499,7 @@ bool IfaceCheckApp::FixMethod(const wxString& header, const wxMethod* iface, con } // remove the old prototype - for (int i=start; i<=end; i++) + for (int k=start; k<=end; k++) file.RemoveLine(start); // remove (end-start)-nth times the start-th line #define INDENTATION_STR wxString(" ") @@ -579,7 +584,9 @@ bool IfaceCheckApp::FixMethod(const wxString& header, const wxMethod* iface, con return false; if (g_verbose) + { wxLogMessage("\tthe final row offset for following methods is %d lines.", nOffset); + } // update the other method's locations for those methods which belong to the modified header // and are placed _below_ the modified method