Author Topic: Small patch (missing #include)  (Read 4855 times)

Offline Der Meister

  • Regular
  • ***
  • Posts: 307
Small patch (missing #include)
« on: March 01, 2006, 05:39:12 pm »
This small patch sould be applied:
Code
Index: src/sdk/editorcolorset.h
===================================================================
--- src/sdk/editorcolorset.h    (revision 2097)
+++ src/sdk/editorcolorset.h    (working copy)
@@ -4,6 +4,7 @@
 #include <wx/dynarray.h>
 #include <wx/hashmap.h>
 #include <wx/intl.h>
+#include <wx/wxscintilla.h>
 #include "settings.h"
 
 // forward decls
Since revision 2096 this header file uses some macros defined in "src/sdk/wxscintilla/include/wx/wxscintilla.h" and thus this header file should be included there. This missing include seems to be no problem for the core-parts of Code::Blocks (probably because of the precompiled headers) but it broke the Source Exporter plugin - it didn't compile without it here (gcc 3.4.5, wxWidgets 2.6.2, Linux).
Real Programmers don't comment their code. If it was hard to write, it should be hard to understand.
Real Programmers don't write in BASIC. Actually, no programmers write in BASIC, after the age of 12.

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4315
    • Code::Blocks IDE
Re: Small patch (missing #include)
« Reply #1 on: March 01, 2006, 05:57:37 pm »
class wxScintilla is forward declared in this file. It's the exporter's sources that need to #include <wx/wxscintilla.h>.
In other words, wrong file to patch ;)
Thanks though. As always, you come up with patches quickly :)
Be patient!
This bug will be fixed soon...

Offline yop

  • Regular
  • ***
  • Posts: 387
Re: Small patch (missing #include)
« Reply #2 on: March 06, 2006, 10:56:22 am »
... seems to be no problem for the core-parts of Code::Blocks (probably because of the precompiled headers) ...
Yeap that's why. I also uploaded a patch for it but I have one remark. The support for gcc < 3.4 is there mostly for linux people that have old distros with outdated compilers (this is true in many working enviroments (software companies etc.) were the official development enviroment is set) and IMHO should be maintained. I most probably will switch to a later gcc version, so I also won't be able to pinpoint compilation errors that are generated out of lack of support for PCH and these kind of errors (especially when the "When It's Ready (TM)" day comes) should be dealt with. Just something to keep in mind ;) (I wonder how long the list of reminders is :)).
Life would be so much easier if we could just look at the source code.