Fix using declarations and templates. %template was putting the
instantiated template into the global namespace instead of the namespace of the template definition. This fixes regression in swig-2.0.5 copying the std::pair typemaps which occurs with a 'using std::pair' declaration. This also fixes lots of other using declarations of template problems (template forward declarations. combinations using directives). git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@13504 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
3e33774c8c
commit
54726b9d09
9 changed files with 339 additions and 7 deletions
|
|
@ -0,0 +1,26 @@
|
|||
|
||||
import template_namespace_forward_declaration.*;
|
||||
|
||||
public class template_namespace_forward_declaration_runme {
|
||||
|
||||
static {
|
||||
try {
|
||||
System.loadLibrary("template_namespace_forward_declaration");
|
||||
} catch (UnsatisfiedLinkError e) {
|
||||
System.err.println("Native code library failed to load. See the chapter on Dynamic Linking Problems in the SWIG Java documentation for help.\n" + e);
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String argv[]) {
|
||||
XXXInt xxx = new XXXInt();
|
||||
template_namespace_forward_declaration.testXXX1(xxx);
|
||||
template_namespace_forward_declaration.testXXX2(xxx);
|
||||
template_namespace_forward_declaration.testXXX3(xxx);
|
||||
YYYInt yyy = new YYYInt();
|
||||
template_namespace_forward_declaration.testYYY1(yyy);
|
||||
template_namespace_forward_declaration.testYYY2(yyy);
|
||||
template_namespace_forward_declaration.testYYY3(yyy);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue