[GiNaC-devel] commit dd19b7316b6eba5c49b6a4fb3503c504ec6c866a

Alexei Sheplyakov varg at metalica.kh.ua
Mon Aug 10 20:03:41 CEST 2009


Hi Jens,

On Sun, Aug 09, 2009 at 11:36:50PM +0200, Jens Vollinga wrote:
> commit dd19b7316b6eba5c49b6a4fb3503c504ec6c866a
> Author: Jens Vollinga <jensv at nikhef.nl>
> Date:   Sun Aug 9 23:27:10 2009 +0200
> 
>     Fixed include of stdint.h (parser.cpp needs the header as well).

I'm afraid this commit is a bit wrong. 

diff --git a/ginac/parser/parse_context.h b/ginac/parser/parse_context.h
index 47b150c..37e08aa 100644
--- a/ginac/parser/parse_context.h
+++ b/ginac/parser/parse_context.h
@@ -30,6 +30,12 @@
 #include <map>
 #include <string>
 #include <utility>
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+#ifdef HAVE_STDINT_H
+#include <stdint.h> // for uintptr_t
+#endif

This is a public header, and we shouldn't avoid using any HAVE_* macros
(and config.h header) there. A software using libginac can define HAVE_*
macros in its own config.h (and in a different way), as a result either
GiNaC or that package (or both) might be very confused. Please #include
config.h (and stdint.h) in each source file which needs it (specifically,
parser.cpp and default_reader.tpl).

Best regards,
	Alexei



More information about the GiNaC-devel mailing list