long long typemap mods for use with %apply

Untested... I don't have chicken


git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@4440 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
William S Fulton 2003-03-06 23:20:50 +00:00
commit ffc19a9300
2 changed files with 5 additions and 5 deletions

View file

@ -46,7 +46,7 @@
/* Const primitive references. Passed by value */
%typemap(in) const type_ & (type_ temp)
%typemap(in) const type_ & ($*1_ltype temp)
%{ if (!checker ($input)) {
swig_barf (SWIG_BARF1_BAD_ARGUMENT_TYPE, "Argument #$argnum is not of type 'type_'");
}
@ -118,10 +118,10 @@
#if ("type_" == "char") || ("type_" == "unsigned char") || ("type_" == "signed char")
%typemap(constcode) type_
"static const type_ $result = '$value';"
"static const $1_type $result = '$value';"
#else
%typemap(constcode) type_
"static const type_ $result = $value;"
"static const $1_type $result = $value;"
#endif
%enddef

View file

@ -125,7 +125,7 @@ output values, in reverse order.
%define INOUT_TYPEMAP(type_, from_scheme, to_scheme, checker, convtype, storage_)
%typemap(in) type_ *INPUT(type_ temp), type_ &INPUT(type_ temp)
%typemap(in) type_ *INPUT($*1_ltype temp), type_ &INPUT($*1_ltype temp)
%{ if (!checker ($input)) {
swig_barf (SWIG_BARF1_BAD_ARGUMENT_TYPE, "Argument #$argnum is not of type 'type_'");
}
@ -135,7 +135,7 @@ output values, in reverse order.
%typemap(typecheck) type_ *INPUT = type_;
%typemap(typecheck) type_ &INPUT = type_;
%typemap(in, numinputs=0) type_ *OUTPUT(type_ temp), type_ &OUTPUT(type_ temp)
%typemap(in, numinputs=0) type_ *OUTPUT($*1_ltype temp), type_ &OUTPUT($*1_ltype temp)
" $1 = &temp;"
#if "storage_" == "0"