Fix typos (class K, class T vs. class T, class u)
and include exception.i git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5251 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
d248d471a8
commit
52638ec3e4
1 changed files with 8 additions and 8 deletions
|
|
@ -6,7 +6,7 @@
|
||||||
// Guile implementation
|
// Guile implementation
|
||||||
|
|
||||||
%include std_common.i
|
%include std_common.i
|
||||||
|
%include exception.i
|
||||||
|
|
||||||
// ------------------------------------------------------------------------
|
// ------------------------------------------------------------------------
|
||||||
// std::pair
|
// std::pair
|
||||||
|
|
@ -22,7 +22,7 @@
|
||||||
|
|
||||||
namespace std {
|
namespace std {
|
||||||
|
|
||||||
template<class K, class T> struct pair {
|
template<class T, class U> struct pair {
|
||||||
%typemap(in) pair<T,U> (std::pair<T,U>* m) {
|
%typemap(in) pair<T,U> (std::pair<T,U>* m) {
|
||||||
if (gh_pair_p($input)) {
|
if (gh_pair_p($input)) {
|
||||||
T* x;
|
T* x;
|
||||||
|
|
@ -132,7 +132,7 @@ namespace std {
|
||||||
second = gh_cdr($input);
|
second = gh_cdr($input);
|
||||||
if (!CHECK(first))
|
if (!CHECK(first))
|
||||||
SWIG_exception(SWIG_TypeError,
|
SWIG_exception(SWIG_TypeError,
|
||||||
"map<" #K "," #T "> expected");
|
"map<" #T "," #U "> expected");
|
||||||
y = (U*) SWIG_MustGetPtr(second,$descriptor(U *),$argnum, 0);
|
y = (U*) SWIG_MustGetPtr(second,$descriptor(U *),$argnum, 0);
|
||||||
$1 = std::make_pair(CONVERT_FROM(first),y);
|
$1 = std::make_pair(CONVERT_FROM(first),y);
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -151,7 +151,7 @@ namespace std {
|
||||||
second = gh_cdr($input);
|
second = gh_cdr($input);
|
||||||
if (!CHECK(first))
|
if (!CHECK(first))
|
||||||
SWIG_exception(SWIG_TypeError,
|
SWIG_exception(SWIG_TypeError,
|
||||||
"map<" #K "," #T "> expected");
|
"map<" #T "," #U "> expected");
|
||||||
y = (U*) SWIG_MustGetPtr(second,$descriptor(U *),$argnum, 0);
|
y = (U*) SWIG_MustGetPtr(second,$descriptor(U *),$argnum, 0);
|
||||||
temp = std::make_pair(CONVERT_FROM(first),y);
|
temp = std::make_pair(CONVERT_FROM(first),y);
|
||||||
$1 = &temp;
|
$1 = &temp;
|
||||||
|
|
@ -228,7 +228,7 @@ namespace std {
|
||||||
x = (T*) SWIG_MustGetPtr(first,$descriptor(T *),$argnum, 0);
|
x = (T*) SWIG_MustGetPtr(first,$descriptor(T *),$argnum, 0);
|
||||||
if (!CHECK(second))
|
if (!CHECK(second))
|
||||||
SWIG_exception(SWIG_TypeError,
|
SWIG_exception(SWIG_TypeError,
|
||||||
"map<" #K "," #T "> expected");
|
"map<" #T "," #U "> expected");
|
||||||
$1 = std::make_pair(x,CONVERT_FROM(second));
|
$1 = std::make_pair(x,CONVERT_FROM(second));
|
||||||
} else {
|
} else {
|
||||||
$1 = *(($&1_type)
|
$1 = *(($&1_type)
|
||||||
|
|
@ -247,7 +247,7 @@ namespace std {
|
||||||
x = (T*) SWIG_MustGetPtr(first,$descriptor(T *),$argnum, 0);
|
x = (T*) SWIG_MustGetPtr(first,$descriptor(T *),$argnum, 0);
|
||||||
if (!CHECK(second))
|
if (!CHECK(second))
|
||||||
SWIG_exception(SWIG_TypeError,
|
SWIG_exception(SWIG_TypeError,
|
||||||
"map<" #K "," #T "> expected");
|
"map<" #T "," #U "> expected");
|
||||||
temp = std::make_pair(x,CONVERT_FROM(second));
|
temp = std::make_pair(x,CONVERT_FROM(second));
|
||||||
$1 = &temp;
|
$1 = &temp;
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -322,7 +322,7 @@ namespace std {
|
||||||
second = gh_cdr($input);
|
second = gh_cdr($input);
|
||||||
if (!CHECK_T(first) || !CHECK_U(second))
|
if (!CHECK_T(first) || !CHECK_U(second))
|
||||||
SWIG_exception(SWIG_TypeError,
|
SWIG_exception(SWIG_TypeError,
|
||||||
"map<" #K "," #T "> expected");
|
"map<" #T "," #U "> expected");
|
||||||
$1 = std::make_pair(CONVERT_T_FROM(first),
|
$1 = std::make_pair(CONVERT_T_FROM(first),
|
||||||
CONVERT_U_FROM(second));
|
CONVERT_U_FROM(second));
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -340,7 +340,7 @@ namespace std {
|
||||||
second = gh_cdr($input);
|
second = gh_cdr($input);
|
||||||
if (!CHECK_T(first) || !CHECK_U(second))
|
if (!CHECK_T(first) || !CHECK_U(second))
|
||||||
SWIG_exception(SWIG_TypeError,
|
SWIG_exception(SWIG_TypeError,
|
||||||
"map<" #K "," #T "> expected");
|
"map<" #T "," #U "> expected");
|
||||||
temp = std::make_pair(CONVERT_T_FROM(first),
|
temp = std::make_pair(CONVERT_T_FROM(first),
|
||||||
CONVERT_U_FROM(second));
|
CONVERT_U_FROM(second));
|
||||||
$1 = &temp;
|
$1 = &temp;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue