From 6eff5b03dda6ad256ac77fc8dce46831f84cfc19 Mon Sep 17 00:00:00 2001 From: Marcelo Matus Date: Sun, 8 Jan 2006 19:37:34 +0000 Subject: [PATCH] add extra replace that the UTL requires git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8299 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- SWIG/Source/Modules/perl5.cxx | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/SWIG/Source/Modules/perl5.cxx b/SWIG/Source/Modules/perl5.cxx index 56bdbed1a..4d1542763 100644 --- a/SWIG/Source/Modules/perl5.cxx +++ b/SWIG/Source/Modules/perl5.cxx @@ -726,7 +726,7 @@ public: "XSRETURN(argvi);\n", "fail:\n", cleanup, - "croak(Nullch);\n" + "croak(\"\");\n" "XSRETURN(0);\n" "}\n", "}\n", @@ -954,11 +954,21 @@ public: Replaceall(tm,"$source",value); Replaceall(tm,"$target",name); Replaceall(tm,"$value",value); + if (is_shadow(type)) { + Replaceall(tm, "$shadow", "SWIG_SHADOW"); + } else { + Replaceall(tm, "$shadow", "0"); + } Printf(constant_tab,"%s,\n", tm); } else if ((tm = Swig_typemap_lookup_new("constcode", n, name, 0))) { Replaceall(tm,"$source", value); Replaceall(tm,"$target", name); Replaceall(tm,"$value",value); + if (is_shadow(type)) { + Replaceall(tm, "$shadow", "SWIG_SHADOW"); + } else { + Replaceall(tm, "$shadow", "0"); + } Printf(f_init, "%s\n", tm); } else { Swig_warning(WARN_TYPEMAP_CONST_UNDEF, input_file, line_number,