Hello ROOTers,
I think the following two expressions are same:
static const double d1(0);
static const double d1 = 0;
But when I generate a dictionary of my classes, rootcint outputs syntax errors,
$ make
(..........)
rootcint -f src/APGAnalysisDict.cxx -c -p include/APGEvent.h include/
APGEventDisplay.h include/APGEventHeader.h include/APGRawDataFile.h
include/APGRunHeader.h include/LinkDef.h
Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:310: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:311: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:315: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:316: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:317: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:318: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:319: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:320: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:321: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:322: Syntax error /ashra/home/oxon/include/CCfits/FITSUtil.h:323:Warning: Error occurred during reading source files Warning: Error occurred during dictionary source generation !!!Removing src/APGAnalysisDict.cxx src/APGAnalysisDict.h !!! Error: rootcint: error loading headers...
CCfits is external package which was coded by others. And APG*. {h,cxx} are my own codes.
Only APGRawDataFile.h includes <CCfits/FITSUtil.h>. This header has 14 lines which cause this syntax errors.
static const double d1(0);
static const float f1(0);
static const std::complex<float> c1(0.);
static const std::complex<double> d2(0.);
static const string s1("");
static const int i1(0);
static const unsigned int u1(0);
static const long l1(0);
static const unsigned long ul1(0);
static const LONGLONG ll1(0);
static const short s2(0);
static const unsigned short us1(0);
static const bool b1(false);
static const unsigned char b2(0);
I added a line as a test before #include in APGRawDataFile.h.
static const double a(0);
#include <CCfits/FITSUtil.h>
However this additional line was not detected as a syntax error.
If CCfits is my own package, of course I will modify the above 14 lines like as "d1(0)" -> "d1 = 0". But it is a package which was coded by other developers. Therefore I would not like to change the code.
Is there any solution from ROOT side?
RH7.3, gcc 3.4.5, ROOT 5.08
Sincerely,
OKUMURA, Akira oxon_at_icrr.u-tokyo.ac.jp
Institute for Cosmic Ray Research, University of Tokyo
5-1-5 Kashiwanoha Kashiwa Chiba 277-8582 Japan
Phone/Fax : +81 4-7136-3153
Skype : okumura.akira
Received on Sat Nov 25 2006 - 08:18:27 MET
This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:32:02 MET