some fixes

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/branches/gsoc2009-sploving@11589 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Baozeng Ding 2009-08-16 15:56:32 +00:00
commit 8ee9175b6e
8 changed files with 576 additions and 214 deletions

View file

@ -9,7 +9,6 @@ srcdir = @srcdir@
top_srcdir = @top_srcdir@ top_srcdir = @top_srcdir@
top_builddir = @top_builddir@ top_builddir = @top_builddir@
include $(srcdir)/../common.mk include $(srcdir)/../common.mk
# Overridden variables here # Overridden variables here
@ -37,7 +36,7 @@ run_testcase = \
# Clean: remove the generated .sci file # Clean: remove the generated .sci file
%.clean: %.clean:
@rm -f $*.sci *_wrap.c *.i *.h @rm -f $*.sci *_wrap.c *.i *.h *_wrap.cxx
clean: clean:
$(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile scilab_clean $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile scilab_clean

View file

@ -1,13 +0,0 @@
exec loader.sce;
if signed_char_identity(-13) <> -13 then pause, end
if unsigned_char_identity(251) <> 251 then pause, end
if signed_short_identity(-31000) <> -31000 then pause, end
if unsigned_short_identity(61000) <> 61000 then pause, end
if signed_int_identity(42) <> 42 then pause, end
if unsigned_int_identity(123456) <> 123456 then pause, end
if signed_long_identity(65537) <> 65537 then pause, end
if unsigned_long_identity(654321) <> 654321 then pause, end
exit

View file

@ -1,6 +1,5 @@
%include <typemaps/swigmacros.swg> %include <typemaps/swigmacros.swg>
%include <typemaps/fragments.swg> %include <typemaps/fragments.swg>
%include <sciruntime.swg> %include <sciruntime.swg>
%include <sciprimtypes.swg>
%include <scitypemaps.swg> %include <scitypemaps.swg>

View file

@ -1 +0,0 @@

View file

@ -1,10 +1,15 @@
%insert(runtime) "swigrun.swg"; %insert(runtime) "swigrun.swg";
%insert(runtime) "swigerrors.swg"; %insert(runtime) "swigerrors.swg";
%insert(runtime) %{ %insert(runtime) %{
#ifdef __cplusplus
extern "C" {
#endif
void SWIG_Error(int code, const char *msg) { void SWIG_Error(int code, const char *msg) {
Scierror(code, _("%s\n"), msg); Scierror(code, _("%s\n"), msg);
} }
#ifdef __cplusplus
}
#endif
#define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(999, msg); } else #define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(999, msg); } else

File diff suppressed because it is too large Load diff

View file

@ -369,7 +369,7 @@ public:
//Printf(tmp, "}"); //Printf(tmp, "}");
//Wrapper_add_local(f, "argv", tmp); //Wrapper_add_local(f, "argv", tmp);
Printv(f->code, dispatch, "\n", NIL); Printv(f->code, dispatch, "\n", NIL);
Printf(f->code, "error(\"No matching function for overload\");\n", iname); Printf(f->code, "Scierror(999, _(\"No matching function for overload\"));\n");
Printf(f->code, "return 0;\n"); Printf(f->code, "return 0;\n");
Printv(f->code, "}\n", NIL); Printv(f->code, "}\n", NIL);