From 7305685ae264635b2fcb10bd12f10727061cf6cb Mon Sep 17 00:00:00 2001 From: jjgarcia Date: Thu, 13 Jan 2005 11:03:18 +0000 Subject: [PATCH] Fix conflicts with external declarations when using the C++ compiler --- src/c/Makefile.in | 2 +- src/cmp/cmpcall.lsp | 4 +++- src/cmp/cmptop.lsp | 2 ++ src/h/external.h | 7 +++++-- 4 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/c/Makefile.in b/src/c/Makefile.in index 0ab46b27e..f83daa261 100644 --- a/src/c/Makefile.in +++ b/src/c/Makefile.in @@ -87,7 +87,7 @@ flatinstall: $(HFILES) ranlib $@ clean: - $(RM) dpp *.c $(OBJS) ../libecl.a cinit.o core a.out + $(RM) dpp *.c *.h $(OBJS) ../libecl.a cinit.o core a.out # Build rules diff --git a/src/cmp/cmpcall.lsp b/src/cmp/cmpcall.lsp index b903ff0d6..cb54ca4de 100644 --- a/src/cmp/cmpcall.lsp +++ b/src/cmp/cmpcall.lsp @@ -194,7 +194,9 @@ ;; to the runtime. ((and (setf fd (get-sysprop fname 'Lfun)) (multiple-value-setq (minarg maxarg) (get-proclaimed-narg fname))) - (call-exported-function fname narg args fd minarg maxarg nil)) + (call-exported-function fname narg args fd minarg maxarg + #-ecl-min nil + #+ecl-min (member fname *in-all-symbols-functions*))) ((multiple-value-setq (found fd minarg maxarg) (si::mangle-name fname t)) (call-exported-function fname narg args fd minarg maxarg t)) diff --git a/src/cmp/cmptop.lsp b/src/cmp/cmptop.lsp index 1d7da6261..1de067959 100644 --- a/src/cmp/cmptop.lsp +++ b/src/cmp/cmptop.lsp @@ -97,6 +97,8 @@ (wt-h "#ifdef __cplusplus") (wt-h "extern \"C\" {") (wt-h "#endif") + (when si::*compiler-constants* + (wt-h "#include ")) ;;; Initialization function. (let* ((*lcl* 0) (*lex* 0) (*max-lex* 0) (*max-env* 0) (*max-temp* 0) (*reservation-cmacro* (next-cmacro)) diff --git a/src/h/external.h b/src/h/external.h index 5a28d824d..b5cf0d348 100644 --- a/src/h/external.h +++ b/src/h/external.h @@ -1645,13 +1645,15 @@ extern cl_object cl_pprint_dispatch _ARGS((cl_narg narg, cl_object V1, ...)); extern cl_object cl_set_pprint_dispatch _ARGS((cl_narg narg, cl_object V1, cl_object V2, ...)); #ifdef CLOS -/* defclass.lsp */ -extern cl_object clos_ensure_class _ARGS((cl_narg narg, cl_object V1, ...)); /* combin.lsp */ extern cl_object cl_method_combination_error _ARGS((cl_narg narg, cl_object format, ...)); extern cl_object cl_invalid_method_error _ARGS((cl_narg narg, cl_object method, cl_object format, ...)); +#if 0 +/* defclass.lsp */ +extern cl_object clos_ensure_class _ARGS((cl_narg narg, cl_object V1, ...)); + /* kernel.lsp */ extern cl_object clos_class_id _ARGS((cl_narg narg, cl_object V1, ...)); extern cl_object clos_class_direct_superclasses _ARGS((cl_narg narg, cl_object V1, ...)); @@ -1677,6 +1679,7 @@ extern cl_object clos_install_method _ARGS((cl_narg narg, cl_object V1, cl_objec /* standard.lsp */ extern cl_object clos_standard_instance_set _ARGS((cl_narg narg, cl_object V1, cl_object V2, cl_object V3, ...)); #endif +#endif #ifdef __cplusplus }