fix bug #1263457
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8887 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
6b2f534ff0
commit
c41f10fd9c
5 changed files with 28 additions and 5 deletions
|
|
@ -5,6 +5,7 @@ Version 1.3.29 (In progress)
|
||||||
|
|
||||||
Fix all the errors reported for 1.3.28.
|
Fix all the errors reported for 1.3.28.
|
||||||
|
|
||||||
|
- fix bug #1263457
|
||||||
- fix 'const char*&' typemap in the UTL, reported by Geoff Hutchison
|
- fix 'const char*&' typemap in the UTL, reported by Geoff Hutchison
|
||||||
- fixes for python 2.1 and the runtime library
|
- fixes for python 2.1 and the runtime library
|
||||||
- fix copyctor + template bug #1432125
|
- fix copyctor + template bug #1432125
|
||||||
|
|
|
||||||
|
|
@ -57,3 +57,20 @@ namespace hello
|
||||||
}
|
}
|
||||||
|
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
%inline {
|
||||||
|
namespace foo {
|
||||||
|
typedef double mytype;
|
||||||
|
};
|
||||||
|
|
||||||
|
// global namespace
|
||||||
|
typedef float mytype;
|
||||||
|
|
||||||
|
using namespace foo;
|
||||||
|
|
||||||
|
struct X {
|
||||||
|
::mytype d;
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -130,10 +130,10 @@ nocppval
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(__cplusplus) && defined(SWIG_CPLUSPLUS_CAST)
|
#if defined(__cplusplus) && defined(SWIG_CPLUSPLUS_CAST)
|
||||||
# define %const_cast(a,Type...) const_cast<Type >(a)
|
# define %const_cast(a,Type...) const_cast< Type >(a)
|
||||||
# define %static_cast(a,Type...) static_cast<Type >(a)
|
# define %static_cast(a,Type...) static_cast< Type >(a)
|
||||||
# define %reinterpret_cast(a,Type...) reinterpret_cast<Type >(a)
|
# define %reinterpret_cast(a,Type...) reinterpret_cast< Type >(a)
|
||||||
# define %numeric_cast(a,Type...) static_cast<Type >(a)
|
# define %numeric_cast(a,Type...) static_cast< Type >(a)
|
||||||
#else /* C case */
|
#else /* C case */
|
||||||
# define %const_cast(a,Type...) (Type)(a)
|
# define %const_cast(a,Type...) (Type)(a)
|
||||||
# define %static_cast(a,Type...) (Type)(a)
|
# define %static_cast(a,Type...) (Type)(a)
|
||||||
|
|
|
||||||
|
|
@ -582,7 +582,7 @@ class TypePass : private Dispatcher {
|
||||||
SwigType *t = Copy(ty);
|
SwigType *t = Copy(ty);
|
||||||
{
|
{
|
||||||
/* If the typename is qualified, make sure the scopename is fully qualified when making a typedef */
|
/* If the typename is qualified, make sure the scopename is fully qualified when making a typedef */
|
||||||
if (Swig_scopename_check(t)) {
|
if (Swig_scopename_check(t) && strncmp(Char(t),"::",2)) {
|
||||||
String *base, *prefix, *qprefix;
|
String *base, *prefix, *qprefix;
|
||||||
base = Swig_scopename_last(t);
|
base = Swig_scopename_last(t);
|
||||||
prefix = Swig_scopename_prefix(t);
|
prefix = Swig_scopename_prefix(t);
|
||||||
|
|
|
||||||
|
|
@ -846,6 +846,11 @@ SwigType *SwigType_typedef_qualified(SwigType *t)
|
||||||
List *elements;
|
List *elements;
|
||||||
String *result;
|
String *result;
|
||||||
int i,len;
|
int i,len;
|
||||||
|
|
||||||
|
if (t && strncmp(Char(t),"::",2) == 0) {
|
||||||
|
return Copy(t);
|
||||||
|
}
|
||||||
|
|
||||||
if (!typedef_qualified_cache) typedef_qualified_cache = NewHash();
|
if (!typedef_qualified_cache) typedef_qualified_cache = NewHash();
|
||||||
result = HashGetAttr(typedef_qualified_cache,t);
|
result = HashGetAttr(typedef_qualified_cache,t);
|
||||||
if (result) {
|
if (result) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue